コード例 #1
0
 /*************************************************************************************************************
 *  Function : Default constructor student
 *  Use: This is used intialize the values of the class properties to null or blank
 *************************************************************************************************************/
 public Student()
 {
     firstName   = (string)null;
     lastName    = (string)null;
     major       = (string)null;
     acadYear    = 0;
     GPA         = 0;
     creditHours = null;
 }
コード例 #2
0
        /*************************************************************************************
         * Fnction : constructor student is created
         * Use : Initialzing the attributes of student using this keyword
         ***********************************************************************************/

        public Student(uint theZID, String theLastName, String theFirstName, String theMajor, academicYear theAcademicYear, float theGPA)
        {
            if (theZID > 1000000)
            {
                this.ZID = theZID;
            }
            this.firstName = theFirstName; /* this keyword refers to current instance of the class*/
            this.lastName  = theLastName;
            this.major     = theMajor;
            this.acadYear  = theAcademicYear;
            if (theGPA >= 0 && theGPA <= 4)       /*if gpa is greater than or equal to zero or less than or equal to 4 condition is checked*/
            {
                this.GPA = theGPA;
            }
            this.creditHours = 0;
        }
コード例 #3
0
 partial void DeleteacademicYear(academicYear instance);
コード例 #4
0
 partial void UpdateacademicYear(academicYear instance);
コード例 #5
0
 partial void InsertacademicYear(academicYear instance);