public void UpdateAttributes(TouristSpot touristSpotWithModification) { Name = touristSpotWithModification.Name; Description = touristSpotWithModification.Description; Image = touristSpotWithModification.Image; Region = touristSpotWithModification.Region; ListOfCategories = touristSpotWithModification.ListOfCategories; }
public override bool Equals(object obj) { if (!(obj is TouristSpot)) { return(false); } TouristSpot touristSpot = obj as TouristSpot; return(this.Id == touristSpot.Id); }
public void VerifyFormat() { if (IsInvalidNameOrAddressOrDesription()) { throw new LodgingException(MessageExceptionDomain.ErrorIsEmpty); } if (IsInvalidQuantityOfStars()) { throw new LodgingException(MessageExceptionDomain.ErrorQuantity); } if (IsInvalidadPricePerNight()) { throw new LodgingException(MessageExceptionDomain.ErrorPrice); } if (IsInvalidListOfPictures()) { throw new LodgingException(MessageExceptionDomain.ErrorListPictures); } TouristSpot.VerifyFormat(); }