Пример #1
0
 /// <summary>
 /// Enum types are equal by primary key
 /// </summary>
 public bool Equals(PermitType other)
 {
     if (other == null)
     {
         return(false);
     }
     return(other.PermitTypeID == PermitTypeID);
 }
Пример #2
0
 /// <summary>
 /// Creates a "blank" object of this type and populates primitives with defaults
 /// </summary>
 public static LandUseBlock CreateNewBlank(StormwaterJurisdiction stormwaterJurisdiction, PermitType permitType)
 {
     return(new LandUseBlock(default(DbGeometry), stormwaterJurisdiction, permitType));
 }
Пример #3
0
 /// <summary>
 /// Constructor for building a new object with MinimalConstructor required fields, using objects whenever possible
 /// </summary>
 public LandUseBlock(DbGeometry landUseBlockGeometry, StormwaterJurisdiction stormwaterJurisdiction, PermitType permitType) : this()
 {
     // Mark this as a new object by setting primary key with special value
     this.LandUseBlockID           = ModelObjectHelpers.MakeNextUnsavedPrimaryKeyValue();
     this.LandUseBlockGeometry     = landUseBlockGeometry;
     this.StormwaterJurisdictionID = stormwaterJurisdiction.StormwaterJurisdictionID;
     this.StormwaterJurisdiction   = stormwaterJurisdiction;
     stormwaterJurisdiction.LandUseBlocks.Add(this);
     this.PermitTypeID = permitType.PermitTypeID;
 }