예제 #1
0
        // Init	- initialize the student object
        public void     Init(string sName, int nID)
        {
            this.sName = sName;
            this.nID   = nID;

            courseInstance = null;
        }
예제 #2
0
        CourseInstance _courseInstance; // Convention is optional.

        // Init - Initialize the student object.
        public void Init(string name, int id)
        {
            this._name = name; // With the naming convention, _name,
            this._id   = id;   // 'this' is no longer needed.

            _courseInstance = null;
        }
예제 #3
0
    CourseInstance _courseInstance;  // Convention is optional.

    // Init - Initialize the student object.
    public void Init(string name, int id)
    {
      this._name = name; // With the naming convention, _name,
      this._id = id;     // 'this' is no longer needed.

      _courseInstance = null;
    }
예제 #4
0
 // Enroll - Enroll the current student in a course.
 public void Enroll(string courseID)
 {
     _courseInstance = new CourseInstance();
     _courseInstance.Init(this, courseID);
 }
예제 #5
0
 // Enroll - Enroll the current student in a course.
 public void Enroll(string courseID)
 {
   _courseInstance = new CourseInstance();
   _courseInstance.Init(this, courseID);
 }
예제 #6
0
 // Enroll	- enroll the current student in a course
 public void     Enroll(string sCourseID)
 {
     courseInstance = new CourseInstance();
     courseInstance.Init(this, sCourseID);
 }
예제 #7
0
 // Enroll -- Enroll the current student in a course.
 public void Enroll(string courseID)
 {
     _courseInstance = new CourseInstance();
     _courseInstance.Init(this, courseID); // The explicit reference.
 }
예제 #8
0
 // Init -- Initialize the student object.
 public void Init(string name, int id)
 {
     this._name      = name;
     this._id        = id;
     _courseInstance = null;
 }
예제 #9
0
파일: Program.cs 프로젝트: sempf/CSharp2012
 // Init -- Initialize the student object.
 public void Init(string name, int id)
 {
     this._name = name;
     this._id = id;
     _courseInstance = null;
 }
예제 #10
0
파일: Program.cs 프로젝트: sempf/CSharp2012
 // Enroll -- Enroll the current student in a course.
 public void Enroll(string courseID)
 {
     _courseInstance = new CourseInstance();
     _courseInstance.Init(this, courseID);    // Here’s the explicit reference.
 }