/* TODO: revisit all copy functions override public bool Copy(Provider untyped) { //Never copy over the id, otherwise we would be creating //a pseudo-reference copy, which we don't want. //Do not copy over the system times and only the business logic //times since the system times are specific to a given instance. ProviderPhotoScore aPhotoScore = (ProviderPhotoScore)untyped; _entityPhotoScore.Score = aPhotoScore._entityPhotoScore.Score; _entityPhotoScore.PhotoId = aPhotoScore._entityPhotoScore.PhotoId; _entityObject = _entityPhotoScore; return true; } */ //========================================================= // PRIVATE FUNCTIONS //========================================================= protected ProviderPhotoScore(PhotoScore aPhotoScore) : base(aPhotoScore) { }
protected override void EntityClear() { _entityPhotoScore = new PhotoScore(); _entityPhotoScore.Id = -1; _entityPhotoScore.SystemCreateDate = new DateTime(); _entityPhotoScore.SystemEditDate = new DateTime(); _entityPhotoScore.PhotoId = -1; _entityPhotoScore.Score = 0; }
/// <summary> /// Create a new PhotoScore object. /// </summary> /// <param name="id">Initial value of the Id property.</param> /// <param name="systemEditDate">Initial value of the SystemEditDate property.</param> /// <param name="systemCreateDate">Initial value of the SystemCreateDate property.</param> /// <param name="photoId">Initial value of the PhotoId property.</param> /// <param name="score">Initial value of the Score property.</param> public static PhotoScore CreatePhotoScore(global::System.Int64 id, global::System.DateTime systemEditDate, global::System.DateTime systemCreateDate, global::System.Int64 photoId, global::System.Double score) { PhotoScore photoScore = new PhotoScore(); photoScore.Id = id; photoScore.SystemEditDate = systemEditDate; photoScore.SystemCreateDate = systemCreateDate; photoScore.PhotoId = photoId; photoScore.Score = score; return photoScore; }
protected static ProviderPhotoScore _EntityToProvider(PhotoScore PhotoScoreEntity) { return new ProviderPhotoScore(PhotoScoreEntity); }
/// <summary> /// Deprecated Method for adding a new object to the PhotoScores EntitySet. Consider using the .Add method of the associated ObjectSet<T> property instead. /// </summary> public void AddToPhotoScores(PhotoScore photoScore) { base.AddObject("PhotoScores", photoScore); }