/// <summary> /// Enum types are equal by primary key /// </summary> public bool Equals(OnlandVisualTrashAssessmentStatus other) { if (other == null) { return(false); } return(other.OnlandVisualTrashAssessmentStatusID == OnlandVisualTrashAssessmentStatusID); }
/// <summary> /// Creates a "blank" object of this type and populates primitives with defaults /// </summary> public static OnlandVisualTrashAssessment CreateNewBlank(Person createdByPerson, StormwaterJurisdiction stormwaterJurisdiction, OnlandVisualTrashAssessmentStatus onlandVisualTrashAssessmentStatus) { return(new OnlandVisualTrashAssessment(createdByPerson, default(DateTime), stormwaterJurisdiction, onlandVisualTrashAssessmentStatus, default(bool), default(bool))); }
/// <summary> /// Constructor for building a new object with MinimalConstructor required fields, using objects whenever possible /// </summary> public OnlandVisualTrashAssessment(Person createdByPerson, DateTime createdDate, StormwaterJurisdiction stormwaterJurisdiction, OnlandVisualTrashAssessmentStatus onlandVisualTrashAssessmentStatus, bool isTransectBackingAssessment, bool isProgressAssessment) : this() { // Mark this as a new object by setting primary key with special value this.OnlandVisualTrashAssessmentID = ModelObjectHelpers.MakeNextUnsavedPrimaryKeyValue(); this.CreatedByPersonID = createdByPerson.PersonID; this.CreatedByPerson = createdByPerson; createdByPerson.OnlandVisualTrashAssessmentsWhereYouAreTheCreatedByPerson.Add(this); this.CreatedDate = createdDate; this.StormwaterJurisdictionID = stormwaterJurisdiction.StormwaterJurisdictionID; this.StormwaterJurisdiction = stormwaterJurisdiction; stormwaterJurisdiction.OnlandVisualTrashAssessments.Add(this); this.OnlandVisualTrashAssessmentStatusID = onlandVisualTrashAssessmentStatus.OnlandVisualTrashAssessmentStatusID; this.IsTransectBackingAssessment = isTransectBackingAssessment; this.IsProgressAssessment = isProgressAssessment; }