Beispiel #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Triangle" /> class.
 /// </summary>
 /// <param name="equilateralTriangle">equilateralTriangle</param>
 /// <param name="shapeType">shapeType (required)</param>
 /// <param name="triangleType">triangleType (required)</param>
 public Triangle(EquilateralTriangle equilateralTriangle, string shapeType, string triangleType)
 {
     if (shapeType == null)
     {
         throw new ArgumentNullException("shapeType is a required property for Triangle and cannot be null.");
     }
     if (triangleType == null)
     {
         throw new ArgumentNullException("triangleType is a required property for Triangle and cannot be null.");
     }
     EquilateralTriangle = equilateralTriangle;
     ShapeType           = shapeType;
     TriangleType        = triangleType;
 }
Beispiel #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Triangle" /> class
 /// with the <see cref="EquilateralTriangle" /> class
 /// </summary>
 /// <param name="actualInstance">An instance of EquilateralTriangle.</param>
 public Triangle(EquilateralTriangle actualInstance)
 {
     this.IsNullable     = false;
     this.SchemaType     = "oneOf";
     this.ActualInstance = actualInstance ?? throw new ArgumentException("Invalid instance found. Must not be null.");
 }