コード例 #1
0
ファイル: SlideModel.cs プロジェクト: artalgame/CP
 public static SlideModel GetSlideModelFromDBSlide(Slide slide)
 {
     var slideModel = new SlideModel();
     slideModel.ContentOfSlide = ContentModel.CreateFromContent(slide.Content);
     slideModel.TitleOfSlide = TitleModel.CreateFromTitle(slide.Title);
     slideModel.FonColor = slide.FonColor;
     slideModel.SlideNumber = slide.SlideNumber;
     slideModel.PresentationId = slide.PresentationId;
     slideModel.SlideId = slide.SlideId;
     return slideModel;
 }
コード例 #2
0
ファイル: Slide.cs プロジェクト: artalgame/CP
 public static Slide CreateFromSlideModel(SlideModel slideModel)
 {
     var slide = new Slide()
     {
         Content = Content.GetFromContentModel(slideModel.ContentOfSlide),
         ContentId = slideModel.ContentOfSlide.ContentId,
         FonColor = slideModel.FonColor,
         PresentationId = slideModel.PresentationId,
         SlideId = slideModel.SlideId,
         SlideNumber = slideModel.SlideNumber,
         Title = Title.CreateFromTitleModel(slideModel.TitleOfSlide),
         TitleId = slideModel.TitleOfSlide.TitleId
     };
     return slide;
 }
コード例 #3
0
 /// <summary>
 /// Create a new Slide object.
 /// </summary>
 /// <param name="slideId">Initial value of the SlideId property.</param>
 /// <param name="presentationId">Initial value of the PresentationId property.</param>
 /// <param name="fonColor">Initial value of the FonColor property.</param>
 /// <param name="titleId">Initial value of the TitleId property.</param>
 /// <param name="contentId">Initial value of the ContentId property.</param>
 /// <param name="slideNumber">Initial value of the SlideNumber property.</param>
 public static Slide CreateSlide(global::System.Guid slideId, global::System.Guid presentationId, global::System.String fonColor, global::System.Guid titleId, global::System.Guid contentId, global::System.Int32 slideNumber)
 {
     Slide slide = new Slide();
     slide.SlideId = slideId;
     slide.PresentationId = presentationId;
     slide.FonColor = fonColor;
     slide.TitleId = titleId;
     slide.ContentId = contentId;
     slide.SlideNumber = slideNumber;
     return slide;
 }
コード例 #4
0
 /// <summary>
 /// Deprecated Method for adding a new object to the Slides EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToSlides(Slide slide)
 {
     base.AddObject("Slides", slide);
 }