Click here to Skip to main content
15,867,594 members
Articles / Web Development / ASP.NET

Developing Next Generation Smart Clients using .NET 2.0 working with Existing .NET 1.1 SOA-based XML Web Services

Rate me:
Please Sign up or sign in to vote.
4.96/5 (134 votes)
16 Aug 200540 min read 1.2M   3.9K   462  
Comprehensive guide to development of .NET 2.0 Smart Clients working with existing Service Oriented Architecture based XML web services, fully utilizing the Enterprise Library
// =====================================================================================
// Copyright © 2005 by . All rights are reserved.
// 
// If you like this code then feel free to go ahead and use it.
// The only thing I ask is that you don't remove or alter my copyright notice.
//
// Your use of this software is entirely at your own risk. I make no claims or
// warrantees about the reliability or fitness of this code for any particular purpose.
// If you make changes or additions to this code please mark your code as being yours.
// 
// website , email OmarALZabir@gmail.com, msn oazabir@hotmail.com
// =====================================================================================


	
/*
	Code Generated by a tool.
	Wednesday, July 27, 2005
	Do not modify, edit the file Assessment.cs instead.
*/
using System;
using System.ComponentModel;
using System.Collections;
using System.Xml.Serialization;

namespace SmartInstitute
{
	#region AssessmentEventArgs class
	///<summary>
	/// Provides data for the BeforeChanged and AfterChanged events.
	///</summary>
	///<remarks>The BeforeChanged and AfterChanged events occur when a change is made to the value of a property of a <see cref="Assessment"/> object.</remarks>
	public class AssessmentEventArgs : System.EventArgs
	{
		private AssessmentColumns column;
		
		
		///<summary>
		/// Initalizes a new Instance of the AssessmentEventArgs class.
		///</summary>
		public AssessmentEventArgs(AssessmentColumns column)
		{
			this.column = column;
		}
		
		
		///<summary>
		/// The AssessmentColumns that was modified, which has raised the event.
		///</summary>
		///<value cref="AssessmentColumns" />
		public AssessmentColumns Column
		{
			get {return this.column;}
		}
	}
	#endregion
	
	
	///<summary>
	/// Define a delegate for all Assessment related events.
	///</summary>
	public delegate void AssessmentEventHandler(object sender, AssessmentEventArgs e);
		
	
	///<summary>
	/// An object representation of the 'Assessment' table.
	///</summary>
	/// <remarks>
	/// This class is generated by a tool and should never be modified.
    /// All custom implementations should be done in the <see cref="Assessment"/> class.
    /// </remarks>
	[Serializable]
	public class AssessmentBase : System.IComparable, System.ICloneable, IEntity
	{
		
		#region "Variable Declarations"
		
		/// <summary>
		/// ID : 
		/// </summary>
		protected System.Int32		  _ID = (int)0;
		
		/// <summary>
		/// Serial : 
		/// </summary>
		protected System.Int32		  _Serial = (int)0;
		
		/// <summary>
		/// StudentID : 
		/// </summary>
		protected System.Int32		  _StudentID = (int)0;
		
		/// <summary>
		/// ExamPermitNumber : 
		/// </summary>
		protected System.String		  _ExamPermitNumber = string.Empty;
		
		/// <summary>
		/// AdmissionFee : 
		/// </summary>
		protected System.Decimal		  _AdmissionFee = 0;
		
		/// <summary>
		/// TuitionFee : 
		/// </summary>
		protected System.Decimal		  _TuitionFee = 0;
		
		/// <summary>
		/// ComputerLabFee : 
		/// </summary>
		protected System.Decimal		  _ComputerLabFee = 0;
		
		/// <summary>
		/// ScienceLabFee : 
		/// </summary>
		protected System.Decimal		  _ScienceLabFee = 0;
		
		/// <summary>
		/// ActivityFee : 
		/// </summary>
		protected System.Decimal		  _ActivityFee = 0;
		
		/// <summary>
		/// DevelopmentFee : 
		/// </summary>
		protected System.Decimal		  _DevelopmentFee = 0;
		
		/// <summary>
		/// MiscFee : 
		/// </summary>
		protected System.Decimal		  _MiscFee = 0;
		
		/// <summary>
		/// MedicalFee : 
		/// </summary>
		protected System.Decimal		  _MedicalFee = 0;
		
		/// <summary>
		/// LibraryFee : 
		/// </summary>
		protected System.Decimal		  _LibraryFee = 0;
		
		/// <summary>
		/// IDCardFee : 
		/// </summary>
		protected System.Decimal		  _IDCardFee = 0;
		
		/// <summary>
		/// OtherFee1 : 
		/// </summary>
		protected System.Decimal		  _OtherFee1 = 0;
		
		/// <summary>
		/// OtherFee1Desc : 
		/// </summary>
		protected System.String		  _OtherFee1Desc = string.Empty;
		
		/// <summary>
		/// OtherFee2 : 
		/// </summary>
		protected System.Decimal		  _OtherFee2 = 0;
		
		/// <summary>
		/// OtherFee2Desc : 
		/// </summary>
		protected System.String		  _OtherFee2Desc = string.Empty;
		
		/// <summary>
		/// Discount : 
		/// </summary>
		protected System.Decimal		  _Discount = 0;
		
		/// <summary>
		/// Scholarship : 
		/// </summary>
		protected System.Decimal		  _Scholarship = 0;
		
		/// <summary>
		/// OtherDiscount : 
		/// </summary>
		protected System.Decimal		  _OtherDiscount = 0;
		
		/// <summary>
		/// OtherDiscountDesc : 
		/// </summary>
		protected System.String		  _OtherDiscountDesc = string.Empty;
		
		/// <summary>
		/// RegistrationDate : 
		/// </summary>
		protected System.DateTime		  _RegistrationDate = DateTime.MinValue;
		
		/// <summary>
		/// IsAdmissionFeePaid : 
		/// </summary>
		protected System.Boolean		  _IsAdmissionFeePaid = false;
		
		/// <summary>
		/// IsAnnualFeePaid : 
		/// </summary>
		protected System.Boolean		  _IsAnnualFeePaid = false;
		
		/// <summary>
		/// PaymentType : 
		/// </summary>
		protected System.Int32		  _PaymentType = (int)0;
		
		/// <summary>
		/// ScholarshipInPercent : 
		/// </summary>
		protected System.Int32		  _ScholarshipInPercent = (int)0;
		
		/// <summary>
		/// DiscountInPercent : 
		/// </summary>
		protected System.Int32		  _DiscountInPercent = (int)0;
		
		/// <summary>
		/// Currency : 
		/// </summary>
		protected System.Int32		  _Currency = (int)0;
		
		/// <summary>
		/// SemesterOrder : 
		/// </summary>
		protected System.Int32		  _SemesterOrder = (int)0;
		
		/// <summary>
		/// PreviousBalance : 
		/// </summary>
		protected System.Decimal		  _PreviousBalance = 0;
		
		/// <summary>
		/// ChangeStamp : 
		/// </summary>
		protected System.DateTime		  _ChangeStamp = DateTime.MinValue;
		
		
		/// <summary>
		/// Occurs before the object is changed.
		/// </summary>	
		public event AssessmentEventHandler BeforeChanged;
		
		
		/// <summary>
		/// Occurs after the object is changed.
		/// </summary>
		public event AssessmentEventHandler AfterChanged;		
		#endregion "Variable Declarations"
		
		
		#region "Constructors"
		///<summary>
		/// Creates a new <see cref="AssessmentBase"/> instance.
		///</summary>
		public AssessmentBase()
		{
		}		
		
		///<summary>
		/// Creates a new <see cref="AssessmentBase"/> instance.
		///</summary>
		///<param name="ID"></param>
		///<param name="Serial"></param>
		///<param name="StudentID"></param>
		///<param name="ExamPermitNumber"></param>
		///<param name="AdmissionFee"></param>
		///<param name="TuitionFee"></param>
		///<param name="ComputerLabFee"></param>
		///<param name="ScienceLabFee"></param>
		///<param name="ActivityFee"></param>
		///<param name="DevelopmentFee"></param>
		///<param name="MiscFee"></param>
		///<param name="MedicalFee"></param>
		///<param name="LibraryFee"></param>
		///<param name="IDCardFee"></param>
		///<param name="OtherFee1"></param>
		///<param name="OtherFee1Desc"></param>
		///<param name="OtherFee2"></param>
		///<param name="OtherFee2Desc"></param>
		///<param name="Discount"></param>
		///<param name="Scholarship"></param>
		///<param name="OtherDiscount"></param>
		///<param name="OtherDiscountDesc"></param>
		///<param name="RegistrationDate"></param>
		///<param name="IsAdmissionFeePaid"></param>
		///<param name="IsAnnualFeePaid"></param>
		///<param name="PaymentType"></param>
		///<param name="ScholarshipInPercent"></param>
		///<param name="DiscountInPercent"></param>
		///<param name="Currency"></param>
		///<param name="SemesterOrder"></param>
		///<param name="PreviousBalance"></param>
		///<param name="ChangeStamp"></param>
		public AssessmentBase(System.Int32 ID, System.Int32 Serial, System.Int32 StudentID, System.String ExamPermitNumber, System.Decimal AdmissionFee, System.Decimal TuitionFee, System.Decimal ComputerLabFee, System.Decimal ScienceLabFee, System.Decimal ActivityFee, System.Decimal DevelopmentFee, System.Decimal MiscFee, System.Decimal MedicalFee, System.Decimal LibraryFee, System.Decimal IDCardFee, System.Decimal OtherFee1, System.String OtherFee1Desc, System.Decimal OtherFee2, System.String OtherFee2Desc, System.Decimal Discount, System.Decimal Scholarship, System.Decimal OtherDiscount, System.String OtherDiscountDesc, System.DateTime RegistrationDate, System.Boolean IsAdmissionFeePaid, System.Boolean IsAnnualFeePaid, System.Int32 PaymentType, System.Int32 ScholarshipInPercent, System.Int32 DiscountInPercent, System.Int32 Currency, System.Int32 SemesterOrder, System.Decimal PreviousBalance, System.DateTime ChangeStamp)
		{
			_ID = ID;
			_Serial = Serial;
			_StudentID = StudentID;
			_ExamPermitNumber = ExamPermitNumber;
			_AdmissionFee = AdmissionFee;
			_TuitionFee = TuitionFee;
			_ComputerLabFee = ComputerLabFee;
			_ScienceLabFee = ScienceLabFee;
			_ActivityFee = ActivityFee;
			_DevelopmentFee = DevelopmentFee;
			_MiscFee = MiscFee;
			_MedicalFee = MedicalFee;
			_LibraryFee = LibraryFee;
			_IDCardFee = IDCardFee;
			_OtherFee1 = OtherFee1;
			_OtherFee1Desc = OtherFee1Desc;
			_OtherFee2 = OtherFee2;
			_OtherFee2Desc = OtherFee2Desc;
			_Discount = Discount;
			_Scholarship = Scholarship;
			_OtherDiscount = OtherDiscount;
			_OtherDiscountDesc = OtherDiscountDesc;
			_RegistrationDate = RegistrationDate;
			_IsAdmissionFeePaid = IsAdmissionFeePaid;
			_IsAnnualFeePaid = IsAnnualFeePaid;
			_PaymentType = PaymentType;
			_ScholarshipInPercent = ScholarshipInPercent;
			_DiscountInPercent = DiscountInPercent;
			_Currency = Currency;
			_SemesterOrder = SemesterOrder;
			_PreviousBalance = PreviousBalance;
			_ChangeStamp = ChangeStamp;
		}
				
		#endregion "Constructors"
		
		
		#region Events trigger
		/// <summary>
		/// Raises the <see cref="BeforeChanged" /> event.
		/// </summary>
		/// <param name="column">The <see cref="AssessmentColumns"/> which has fired the event.</param>
		public void OnBeforeChanged(AssessmentColumns column)
		{
			if(BeforeChanged != null)
			{
				BeforeChanged(this, new AssessmentEventArgs(column));
			}
	
		}
		
		
		/// <summary>
		/// Raises the <see cref="AfterChanged" /> event.
		/// </summary>
		/// <param name="column">The <see cref="AssessmentColumns"/> which has fired the event.</param>
		public void OnAfterChanged(AssessmentColumns column)
		{
			if(AfterChanged != null)
			{
				AfterChanged(this, new AssessmentEventArgs(column));
			}
	
		} 
		#endregion
		
		
		#region Properties	
		/// <summary>
		/// 	Gets or Sets the ID property. 
		///		
		/// </summary>
		/// <value>This type is int</value>
		[DescriptionAttribute("")]
		public System.Int32 ID
		{
			get { return _ID; }
			set
			{
				if (_ID == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.ID);
				_ID = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.ID);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the Serial property. 
		///		
		/// </summary>
		/// <value>This type is int</value>
		[DescriptionAttribute("")]
		public System.Int32 Serial
		{
			get { return _Serial; }
			set
			{
				if (_Serial == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.Serial);
				_Serial = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.Serial);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the StudentID property. 
		///		
		/// </summary>
		/// <value>This type is int</value>
		[DescriptionAttribute("")]
		public System.Int32 StudentID
		{
			get { return _StudentID; }
			set
			{
				if (_StudentID == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.StudentID);
				_StudentID = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.StudentID);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the ExamPermitNumber property. 
		///		
		/// </summary>
		/// <value>This type is varchar</value>
		[DescriptionAttribute("")]
		public System.String ExamPermitNumber
		{
			get { return _ExamPermitNumber; }
			set
			{
				if (_ExamPermitNumber == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.ExamPermitNumber);
				_ExamPermitNumber = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.ExamPermitNumber);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the AdmissionFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal AdmissionFee
		{
			get { return _AdmissionFee; }
			set
			{
				if (_AdmissionFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.AdmissionFee);
				_AdmissionFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.AdmissionFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the TuitionFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal TuitionFee
		{
			get { return _TuitionFee; }
			set
			{
				if (_TuitionFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.TuitionFee);
				_TuitionFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.TuitionFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the ComputerLabFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal ComputerLabFee
		{
			get { return _ComputerLabFee; }
			set
			{
				if (_ComputerLabFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.ComputerLabFee);
				_ComputerLabFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.ComputerLabFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the ScienceLabFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal ScienceLabFee
		{
			get { return _ScienceLabFee; }
			set
			{
				if (_ScienceLabFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.ScienceLabFee);
				_ScienceLabFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.ScienceLabFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the ActivityFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal ActivityFee
		{
			get { return _ActivityFee; }
			set
			{
				if (_ActivityFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.ActivityFee);
				_ActivityFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.ActivityFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the DevelopmentFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal DevelopmentFee
		{
			get { return _DevelopmentFee; }
			set
			{
				if (_DevelopmentFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.DevelopmentFee);
				_DevelopmentFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.DevelopmentFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the MiscFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal MiscFee
		{
			get { return _MiscFee; }
			set
			{
				if (_MiscFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.MiscFee);
				_MiscFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.MiscFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the MedicalFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal MedicalFee
		{
			get { return _MedicalFee; }
			set
			{
				if (_MedicalFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.MedicalFee);
				_MedicalFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.MedicalFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the LibraryFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal LibraryFee
		{
			get { return _LibraryFee; }
			set
			{
				if (_LibraryFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.LibraryFee);
				_LibraryFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.LibraryFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the IDCardFee property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal IDCardFee
		{
			get { return _IDCardFee; }
			set
			{
				if (_IDCardFee == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.IDCardFee);
				_IDCardFee = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.IDCardFee);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the OtherFee1 property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal OtherFee1
		{
			get { return _OtherFee1; }
			set
			{
				if (_OtherFee1 == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.OtherFee1);
				_OtherFee1 = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.OtherFee1);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the OtherFee1Desc property. 
		///		
		/// </summary>
		/// <value>This type is varchar</value>
		[DescriptionAttribute("")]
		public System.String OtherFee1Desc
		{
			get { return _OtherFee1Desc; }
			set
			{
				if (_OtherFee1Desc == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.OtherFee1Desc);
				_OtherFee1Desc = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.OtherFee1Desc);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the OtherFee2 property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal OtherFee2
		{
			get { return _OtherFee2; }
			set
			{
				if (_OtherFee2 == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.OtherFee2);
				_OtherFee2 = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.OtherFee2);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the OtherFee2Desc property. 
		///		
		/// </summary>
		/// <value>This type is varchar</value>
		[DescriptionAttribute("")]
		public System.String OtherFee2Desc
		{
			get { return _OtherFee2Desc; }
			set
			{
				if (_OtherFee2Desc == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.OtherFee2Desc);
				_OtherFee2Desc = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.OtherFee2Desc);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the Discount property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal Discount
		{
			get { return _Discount; }
			set
			{
				if (_Discount == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.Discount);
				_Discount = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.Discount);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the Scholarship property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal Scholarship
		{
			get { return _Scholarship; }
			set
			{
				if (_Scholarship == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.Scholarship);
				_Scholarship = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.Scholarship);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the OtherDiscount property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal OtherDiscount
		{
			get { return _OtherDiscount; }
			set
			{
				if (_OtherDiscount == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.OtherDiscount);
				_OtherDiscount = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.OtherDiscount);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the OtherDiscountDesc property. 
		///		
		/// </summary>
		/// <value>This type is varchar</value>
		[DescriptionAttribute("")]
		public System.String OtherDiscountDesc
		{
			get { return _OtherDiscountDesc; }
			set
			{
				if (_OtherDiscountDesc == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.OtherDiscountDesc);
				_OtherDiscountDesc = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.OtherDiscountDesc);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the RegistrationDate property. 
		///		
		/// </summary>
		/// <value>This type is datetime</value>
		[DescriptionAttribute("")]
		public System.DateTime RegistrationDate
		{
			get { return _RegistrationDate; }
			set
			{
				if (_RegistrationDate == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.RegistrationDate);
				_RegistrationDate = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.RegistrationDate);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the IsAdmissionFeePaid property. 
		///		
		/// </summary>
		/// <value>This type is bit</value>
		[DescriptionAttribute("")]
		public System.Boolean IsAdmissionFeePaid
		{
			get { return _IsAdmissionFeePaid; }
			set
			{
				if (_IsAdmissionFeePaid == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.IsAdmissionFeePaid);
				_IsAdmissionFeePaid = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.IsAdmissionFeePaid);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the IsAnnualFeePaid property. 
		///		
		/// </summary>
		/// <value>This type is bit</value>
		[DescriptionAttribute("")]
		public System.Boolean IsAnnualFeePaid
		{
			get { return _IsAnnualFeePaid; }
			set
			{
				if (_IsAnnualFeePaid == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.IsAnnualFeePaid);
				_IsAnnualFeePaid = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.IsAnnualFeePaid);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the PaymentType property. 
		///		
		/// </summary>
		/// <value>This type is int</value>
		[DescriptionAttribute("")]
		public System.Int32 PaymentType
		{
			get { return _PaymentType; }
			set
			{
				if (_PaymentType == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.PaymentType);
				_PaymentType = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.PaymentType);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the ScholarshipInPercent property. 
		///		
		/// </summary>
		/// <value>This type is int</value>
		[DescriptionAttribute("")]
		public System.Int32 ScholarshipInPercent
		{
			get { return _ScholarshipInPercent; }
			set
			{
				if (_ScholarshipInPercent == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.ScholarshipInPercent);
				_ScholarshipInPercent = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.ScholarshipInPercent);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the DiscountInPercent property. 
		///		
		/// </summary>
		/// <value>This type is int</value>
		[DescriptionAttribute("")]
		public System.Int32 DiscountInPercent
		{
			get { return _DiscountInPercent; }
			set
			{
				if (_DiscountInPercent == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.DiscountInPercent);
				_DiscountInPercent = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.DiscountInPercent);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the Currency property. 
		///		
		/// </summary>
		/// <value>This type is int</value>
		[DescriptionAttribute("")]
		public System.Int32 Currency
		{
			get { return _Currency; }
			set
			{
				if (_Currency == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.Currency);
				_Currency = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.Currency);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the SemesterOrder property. 
		///		
		/// </summary>
		/// <value>This type is int</value>
		[DescriptionAttribute("")]
		public System.Int32 SemesterOrder
		{
			get { return _SemesterOrder; }
			set
			{
				if (_SemesterOrder == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.SemesterOrder);
				_SemesterOrder = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.SemesterOrder);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the PreviousBalance property. 
		///		
		/// </summary>
		/// <value>This type is money</value>
		[DescriptionAttribute("")]
		public System.Decimal PreviousBalance
		{
			get { return _PreviousBalance; }
			set
			{
				if (_PreviousBalance == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.PreviousBalance);
				_PreviousBalance = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.PreviousBalance);
			}
		}
	
		/// <summary>
		/// 	Gets or Sets the ChangeStamp property. 
		///		
		/// </summary>
		/// <value>This type is smalldatetime</value>
		[DescriptionAttribute("")]
		public System.DateTime ChangeStamp
		{
			get { return _ChangeStamp; }
			set
			{
				if (_ChangeStamp == value)
					return;
					
				OnBeforeChanged(AssessmentColumns.ChangeStamp);
				_ChangeStamp = value;
				_isdirty = true;
				OnAfterChanged(AssessmentColumns.ChangeStamp);
			}
		}
	
	

		private bool _isdeleted = false;
		/// <summary>
		/// 	True if object has been <see cref="MarkToDelete"/>. ReadOnly.
		/// </summary>
		[BrowsableAttribute(false)]
		public bool IsDeleted
		{
			get { return _isdeleted; }
			set { _isdeleted = value; }
		}


		private bool _isdirty = false;
		/// <summary>
		///		Indicates if the object has been modified from its original state.
		/// </summary>
		///<value>True if object has been modified from its original state; otherwise False;</value>
		[BrowsableAttribute(false)]
		public bool IsDirty
		{
			get { return _isdirty; }
			set { _isdirty = value; }
		}
		

		private bool _isnew = false;
		/// <summary>
		///		Indicates if the object is new.
		/// </summary>
		///<value>True if objectis new; otherwise False;</value>
		[BrowsableAttribute(false)]
		public bool IsNew
		{
			get { return _isnew; }
			set { _isnew = value; }
		}

		/// <summary>
		///		The name of the underlying database table.
		/// </summary>
		[BrowsableAttribute(false)]
		public string TableName
		{
			get { return "Assessment"; }
		}
		
		#endregion
		
		#region Methods	
		
		/// <summary>
		/// Accepts the changes made to this object by setting each flags to false.
		/// </summary>
		public void AcceptChanges()
		{
			_isdeleted = false;
			_isdirty = false;
			_isnew = false;
		}
		
		
		///<summary>
		///  TODO: Revert all changes and restore original values.
		///  Currently not supported.
		///</summary>
		public virtual void CancelChanges(){
			throw new NotSupportedException("Method currently not Supported.");
		}
		
		///<summary>
		///   Marks entity to be deleted.
		///</summary>
		public void MarkToDelete()
		{
			_isdeleted = true;
		}
		
		#region ICloneable Members
		///<summary>
		///  Returns a Typed AssessmentBase Entity 
		///</summary>
		public virtual AssessmentBase Copy()
		{
			//shallow copy entity
			Assessment copy = new Assessment();
			copy.ID = this._ID;
			copy.Serial = this._Serial;
			copy.StudentID = this._StudentID;
			copy.ExamPermitNumber = this._ExamPermitNumber;
			copy.AdmissionFee = this._AdmissionFee;
			copy.TuitionFee = this._TuitionFee;
			copy.ComputerLabFee = this._ComputerLabFee;
			copy.ScienceLabFee = this._ScienceLabFee;
			copy.ActivityFee = this._ActivityFee;
			copy.DevelopmentFee = this._DevelopmentFee;
			copy.MiscFee = this._MiscFee;
			copy.MedicalFee = this._MedicalFee;
			copy.LibraryFee = this._LibraryFee;
			copy.IDCardFee = this._IDCardFee;
			copy.OtherFee1 = this._OtherFee1;
			copy.OtherFee1Desc = this._OtherFee1Desc;
			copy.OtherFee2 = this._OtherFee2;
			copy.OtherFee2Desc = this._OtherFee2Desc;
			copy.Discount = this._Discount;
			copy.Scholarship = this._Scholarship;
			copy.OtherDiscount = this._OtherDiscount;
			copy.OtherDiscountDesc = this._OtherDiscountDesc;
			copy.RegistrationDate = this._RegistrationDate;
			copy.IsAdmissionFeePaid = this._IsAdmissionFeePaid;
			copy.IsAnnualFeePaid = this._IsAnnualFeePaid;
			copy.PaymentType = this._PaymentType;
			copy.ScholarshipInPercent = this._ScholarshipInPercent;
			copy.DiscountInPercent = this._DiscountInPercent;
			copy.Currency = this._Currency;
			copy.SemesterOrder = this._SemesterOrder;
			copy.PreviousBalance = this._PreviousBalance;
			copy.ChangeStamp = this._ChangeStamp;
					
			copy.AcceptChanges();
			return (Assessment)copy;
		}
		
		///<summary>
		/// ICloneable.Clone() Member, returns the Deep Copy of this entity.
		///</summary>
		public object Clone(){
			return this.Copy();
		}
		
		///<summary>
		/// Returns a deep copy of the child collection object passed in.
		///</summary>
		public static object MakeCopyOf(object x)
		{
			if (x is ICloneable)
			{
				// Return a deep copy of the object
				return ((ICloneable)x).Clone();
			}
			else
				throw new System.NotSupportedException("Object Does Not Implement the ICloneable Interface.");
		}
		#endregion
		
		
		///<summary>
		/// Returns a value indicating whether this instance is equal to a specified object.
		///</summary>
		///<param name="toObject">An object to compare to this instance.</param>
		///<returns>true if toObject is a <see cref="AssessmentBase"/> and has the same value as this instance; otherwise, false.</returns>
		public bool Equals(AssessmentBase toObject)
		{
			return Equals(this, toObject);
		}
		
		
		///<summary>
		/// Determines whether the specified <see cref="AssessmentBase"/> instances are considered equal.
		///</summary>
		///<param name="Object1">The first <see cref="AssessmentBase"/> to compare.</param>
		///<param name="Object2">The second <see cref="AssessmentBase"/> to compare. </param>
		///<returns>true if Object1 is the same instance as Object2 or if both are null references or if objA.Equals(objB) returns true; otherwise, false.</returns>
		public static bool Equals(AssessmentBase Object1, AssessmentBase Object2)
		{
			bool equal = true;
			if (Object1.ID != Object2.ID)
				equal = false;
			if (Object1.Serial != Object2.Serial)
				equal = false;
			if (Object1.StudentID != Object2.StudentID)
				equal = false;
			if (Object1.ExamPermitNumber != Object2.ExamPermitNumber)
				equal = false;
			if (Object1.AdmissionFee != Object2.AdmissionFee)
				equal = false;
			if (Object1.TuitionFee != Object2.TuitionFee)
				equal = false;
			if (Object1.ComputerLabFee != Object2.ComputerLabFee)
				equal = false;
			if (Object1.ScienceLabFee != Object2.ScienceLabFee)
				equal = false;
			if (Object1.ActivityFee != Object2.ActivityFee)
				equal = false;
			if (Object1.DevelopmentFee != Object2.DevelopmentFee)
				equal = false;
			if (Object1.MiscFee != Object2.MiscFee)
				equal = false;
			if (Object1.MedicalFee != Object2.MedicalFee)
				equal = false;
			if (Object1.LibraryFee != Object2.LibraryFee)
				equal = false;
			if (Object1.IDCardFee != Object2.IDCardFee)
				equal = false;
			if (Object1.OtherFee1 != Object2.OtherFee1)
				equal = false;
			if (Object1.OtherFee1Desc != Object2.OtherFee1Desc)
				equal = false;
			if (Object1.OtherFee2 != Object2.OtherFee2)
				equal = false;
			if (Object1.OtherFee2Desc != Object2.OtherFee2Desc)
				equal = false;
			if (Object1.Discount != Object2.Discount)
				equal = false;
			if (Object1.Scholarship != Object2.Scholarship)
				equal = false;
			if (Object1.OtherDiscount != Object2.OtherDiscount)
				equal = false;
			if (Object1.OtherDiscountDesc != Object2.OtherDiscountDesc)
				equal = false;
			if (Object1.RegistrationDate != Object2.RegistrationDate)
				equal = false;
			if (Object1.IsAdmissionFeePaid != Object2.IsAdmissionFeePaid)
				equal = false;
			if (Object1.IsAnnualFeePaid != Object2.IsAnnualFeePaid)
				equal = false;
			if (Object1.PaymentType != Object2.PaymentType)
				equal = false;
			if (Object1.ScholarshipInPercent != Object2.ScholarshipInPercent)
				equal = false;
			if (Object1.DiscountInPercent != Object2.DiscountInPercent)
				equal = false;
			if (Object1.Currency != Object2.Currency)
				equal = false;
			if (Object1.SemesterOrder != Object2.SemesterOrder)
				equal = false;
			if (Object1.PreviousBalance != Object2.PreviousBalance)
				equal = false;
			if (Object1.ChangeStamp != Object2.ChangeStamp)
				equal = false;
			return equal;
		}
		
		#endregion
		
		#region IComparable Members
		///<summary>
		/// Compares this instance to a specified object and returns an indication of their relative values.
		///<param name="obj">An object to compare to this instance, or a null reference (Nothing in Visual Basic).</param>
		///</summary>
		///<returns>A signed integer that indicates the relative order of this instance and obj.</returns>
		public int CompareTo(object obj)
		{
			return this.ID.CompareTo(((AssessmentBase)obj).ID);
		}
	
		#endregion
		
			
		#region "IsColumnNull"
		#endregion "IsColumnNull"
		
		///<summary>
		/// Returns a String that represents the current object.
		///</summary>
		public override string ToString()
		{
			return string.Format("{33}{32}- ID: {0}{32}- Serial: {1}{32}- StudentID: {2}{32}- ExamPermitNumber: {3}{32}- AdmissionFee: {4}{32}- TuitionFee: {5}{32}- ComputerLabFee: {6}{32}- ScienceLabFee: {7}{32}- ActivityFee: {8}{32}- DevelopmentFee: {9}{32}- MiscFee: {10}{32}- MedicalFee: {11}{32}- LibraryFee: {12}{32}- IDCardFee: {13}{32}- OtherFee1: {14}{32}- OtherFee1Desc: {15}{32}- OtherFee2: {16}{32}- OtherFee2Desc: {17}{32}- Discount: {18}{32}- Scholarship: {19}{32}- OtherDiscount: {20}{32}- OtherDiscountDesc: {21}{32}- RegistrationDate: {22}{32}- IsAdmissionFeePaid: {23}{32}- IsAnnualFeePaid: {24}{32}- PaymentType: {25}{32}- ScholarshipInPercent: {26}{32}- DiscountInPercent: {27}{32}- Currency: {28}{32}- SemesterOrder: {29}{32}- PreviousBalance: {30}{32}- ChangeStamp: {31}{32}", ID, Serial, StudentID, ExamPermitNumber, AdmissionFee, TuitionFee, ComputerLabFee, ScienceLabFee, ActivityFee, DevelopmentFee, MiscFee, MedicalFee, LibraryFee, IDCardFee, OtherFee1, OtherFee1Desc, OtherFee2, OtherFee2Desc, Discount, Scholarship, OtherDiscount, OtherDiscountDesc, RegistrationDate, IsAdmissionFeePaid, IsAnnualFeePaid, PaymentType, ScholarshipInPercent, DiscountInPercent, Currency, SemesterOrder, PreviousBalance, ChangeStamp, Environment.NewLine, this.GetType());
		}
	
	}//End Class
	
	
	/// <summary>
	/// Enumerate the Assessment columns.
	/// </summary>
	public enum AssessmentColumns
	{
		/// <summary>
		/// ID : 
		/// </summary>
		ID,
		/// <summary>
		/// Serial : 
		/// </summary>
		Serial,
		/// <summary>
		/// StudentID : 
		/// </summary>
		StudentID,
		/// <summary>
		/// ExamPermitNumber : 
		/// </summary>
		ExamPermitNumber,
		/// <summary>
		/// AdmissionFee : 
		/// </summary>
		AdmissionFee,
		/// <summary>
		/// TuitionFee : 
		/// </summary>
		TuitionFee,
		/// <summary>
		/// ComputerLabFee : 
		/// </summary>
		ComputerLabFee,
		/// <summary>
		/// ScienceLabFee : 
		/// </summary>
		ScienceLabFee,
		/// <summary>
		/// ActivityFee : 
		/// </summary>
		ActivityFee,
		/// <summary>
		/// DevelopmentFee : 
		/// </summary>
		DevelopmentFee,
		/// <summary>
		/// MiscFee : 
		/// </summary>
		MiscFee,
		/// <summary>
		/// MedicalFee : 
		/// </summary>
		MedicalFee,
		/// <summary>
		/// LibraryFee : 
		/// </summary>
		LibraryFee,
		/// <summary>
		/// IDCardFee : 
		/// </summary>
		IDCardFee,
		/// <summary>
		/// OtherFee1 : 
		/// </summary>
		OtherFee1,
		/// <summary>
		/// OtherFee1Desc : 
		/// </summary>
		OtherFee1Desc,
		/// <summary>
		/// OtherFee2 : 
		/// </summary>
		OtherFee2,
		/// <summary>
		/// OtherFee2Desc : 
		/// </summary>
		OtherFee2Desc,
		/// <summary>
		/// Discount : 
		/// </summary>
		Discount,
		/// <summary>
		/// Scholarship : 
		/// </summary>
		Scholarship,
		/// <summary>
		/// OtherDiscount : 
		/// </summary>
		OtherDiscount,
		/// <summary>
		/// OtherDiscountDesc : 
		/// </summary>
		OtherDiscountDesc,
		/// <summary>
		/// RegistrationDate : 
		/// </summary>
		RegistrationDate,
		/// <summary>
		/// IsAdmissionFeePaid : 
		/// </summary>
		IsAdmissionFeePaid,
		/// <summary>
		/// IsAnnualFeePaid : 
		/// </summary>
		IsAnnualFeePaid,
		/// <summary>
		/// PaymentType : 
		/// </summary>
		PaymentType,
		/// <summary>
		/// ScholarshipInPercent : 
		/// </summary>
		ScholarshipInPercent,
		/// <summary>
		/// DiscountInPercent : 
		/// </summary>
		DiscountInPercent,
		/// <summary>
		/// Currency : 
		/// </summary>
		Currency,
		/// <summary>
		/// SemesterOrder : 
		/// </summary>
		SemesterOrder,
		/// <summary>
		/// PreviousBalance : 
		/// </summary>
		PreviousBalance,
		/// <summary>
		/// ChangeStamp : 
		/// </summary>
		ChangeStamp
	}//End enum

} // end namespace

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Architect BT, UK (ex British Telecom)
United Kingdom United Kingdom

Comments and Discussions