コード例 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="View" /> class.
 /// </summary>
 /// <param name="links">links.</param>
 /// <param name="name">name (required).</param>
 /// <param name="properties">properties (required).</param>
 public View(ViewLinks links = default(ViewLinks), string name = default(string), ViewProperties properties = default(ViewProperties))
 {
     // to ensure "name" is required (not null)
     if (name == null)
     {
         throw new InvalidDataException("name is a required property for View and cannot be null");
     }
     else
     {
         this.Name = name;
     }
     // to ensure "properties" is required (not null)
     if (properties == null)
     {
         throw new InvalidDataException("properties is a required property for View and cannot be null");
     }
     else
     {
         this.Properties = properties;
     }
     this.Links = links;
 }
コード例 #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Views" /> class.
 /// </summary>
 /// <param name="links">links.</param>
 /// <param name="views">views.</param>
 public Views(ViewLinks links = default(ViewLinks), List <View> views = default(List <View>))
 {
     this.Links  = links;
     this._Views = views;
 }