예제 #1
0
 /// <summary>
 /// Create a new News object.
 /// </summary>
 /// <param name="newsId">Initial value of the NewsId property.</param>
 public static News CreateNews(global::System.Guid newsId)
 {
     News news = new News();
     news.NewsId = newsId;
     return news;
 }
예제 #2
0
 public void Update(News obj, out OperationResult operationResult)
 {
     lock (Lock)
     {
         if (obj == null)
         {
             operationResult = new OperationResult { Type = OperationResult.ResultType.Warning };
             return;
         }
         Common.Instance.Update
             (obj, objs => objs.NewsId == obj.NewsId && objs.LanguageId == obj.LanguageId, out operationResult);
     }
 }
예제 #3
0
 /// <summary>
 /// Deprecated Method for adding a new object to the News EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToNews(News news)
 {
     base.AddObject("News", news);
 }
예제 #4
0
 public void Insert(News obj, out OperationResult operationResult)
 {
     lock (Lock)
     {
         if (obj == null)
         {
             operationResult = new OperationResult { Type = OperationResult.ResultType.Warning };
         }
         else
         {
             Common.Instance.Insert(obj, out operationResult);
         }
     }
 }