/// <summary>
 /// Initializes a new instance of the <see cref="EdFiCalendarReadable" /> class.
 /// </summary>
 /// <param name="Id">Id (required).</param>
 /// <param name="CalendarCode">The identifier for the Calendar. (required).</param>
 /// <param name="SchoolReference">SchoolReference (required).</param>
 /// <param name="SchoolYearTypeReference">SchoolYearTypeReference (required).</param>
 /// <param name="CalendarTypeDescriptor">Indicates the type of Calendar. (required).</param>
 /// <param name="GradeLevels">An unordered collection of calendarGradeLevels. Indicates the GradeLevel associated with the Calendar..</param>
 /// <param name="Etag">A unique system-generated value that identifies the version of the resource..</param>
 /// <param name="Ext">Ext.</param>
 public EdFiCalendarReadable(string Id = default(string), string CalendarCode = default(string), EdFiSchoolReference SchoolReference = default(EdFiSchoolReference), EdFiSchoolYearTypeReference SchoolYearTypeReference = default(EdFiSchoolYearTypeReference), string CalendarTypeDescriptor = default(string), List <EdFiCalendarGradeLevelReadable> GradeLevels = default(List <EdFiCalendarGradeLevelReadable>), string Etag = default(string), CalendarExtensionsReadable Ext = default(CalendarExtensionsReadable))
 {
     // to ensure "Id" is required (not null)
     if (Id == null)
     {
         throw new InvalidDataException("Id is a required property for EdFiCalendarReadable and cannot be null");
     }
     else
     {
         this.Id = Id;
     }
     // to ensure "CalendarCode" is required (not null)
     if (CalendarCode == null)
     {
         throw new InvalidDataException("CalendarCode is a required property for EdFiCalendarReadable and cannot be null");
     }
     else
     {
         this.CalendarCode = CalendarCode;
     }
     // to ensure "SchoolReference" is required (not null)
     if (SchoolReference == null)
     {
         throw new InvalidDataException("SchoolReference is a required property for EdFiCalendarReadable and cannot be null");
     }
     else
     {
         this.SchoolReference = SchoolReference;
     }
     // to ensure "SchoolYearTypeReference" is required (not null)
     if (SchoolYearTypeReference == null)
     {
         throw new InvalidDataException("SchoolYearTypeReference is a required property for EdFiCalendarReadable and cannot be null");
     }
     else
     {
         this.SchoolYearTypeReference = SchoolYearTypeReference;
     }
     // to ensure "CalendarTypeDescriptor" is required (not null)
     if (CalendarTypeDescriptor == null)
     {
         throw new InvalidDataException("CalendarTypeDescriptor is a required property for EdFiCalendarReadable and cannot be null");
     }
     else
     {
         this.CalendarTypeDescriptor = CalendarTypeDescriptor;
     }
     this.GradeLevels = GradeLevels;
     this.Etag        = Etag;
     this.Ext         = Ext;
 }
Esempio n. 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="EdFiCalendarReadable" /> class.
 /// </summary>
 /// <param name="id">id.</param>
 /// <param name="calendarCode">The identifier for the Calendar. (required).</param>
 /// <param name="schoolReference">schoolReference (required).</param>
 /// <param name="schoolYearTypeReference">schoolYearTypeReference (required).</param>
 /// <param name="calendarTypeDescriptor">Indicates the type of Calendar. (required).</param>
 /// <param name="gradeLevels">An unordered collection of calendarGradeLevels. Indicates the GradeLevel associated with the Calendar..</param>
 /// <param name="etag">A unique system-generated value that identifies the version of the resource..</param>
 /// <param name="ext">ext.</param>
 public EdFiCalendarReadable(string id = default(string), string calendarCode = default(string), EdFiSchoolReference schoolReference = default(EdFiSchoolReference), EdFiSchoolYearTypeReference schoolYearTypeReference = default(EdFiSchoolYearTypeReference), string calendarTypeDescriptor = default(string), List <EdFiCalendarGradeLevelReadable> gradeLevels = default(List <EdFiCalendarGradeLevelReadable>), string etag = default(string), CalendarExtensionsReadable ext = default(CalendarExtensionsReadable))
 {
     // to ensure "calendarCode" is required (not null)
     if (calendarCode == null)
     {
         throw new InvalidDataException("calendarCode is a required property for EdFiCalendarReadable and cannot be null");
     }
     else
     {
         this.CalendarCode = calendarCode;
     }
     // to ensure "schoolReference" is required (not null)
     if (schoolReference == null)
     {
         throw new InvalidDataException("schoolReference is a required property for EdFiCalendarReadable and cannot be null");
     }
     else
     {
         this.SchoolReference = schoolReference;
     }
     // to ensure "schoolYearTypeReference" is required (not null)
     if (schoolYearTypeReference == null)
     {
         throw new InvalidDataException("schoolYearTypeReference is a required property for EdFiCalendarReadable and cannot be null");
     }
     else
     {
         this.SchoolYearTypeReference = schoolYearTypeReference;
     }
     // to ensure "calendarTypeDescriptor" is required (not null)
     if (calendarTypeDescriptor == null)
     {
         throw new InvalidDataException("calendarTypeDescriptor is a required property for EdFiCalendarReadable and cannot be null");
     }
     else
     {
         this.CalendarTypeDescriptor = calendarTypeDescriptor;
     }
     this.Id          = id;
     this.GradeLevels = gradeLevels;
     this.Etag        = etag;
     this.Ext         = ext;
 }