/// <summary>
		/// This method will return a list of objects representing all records in the table.
		/// </summary>
		///
		/// <returns>list of objects of class BDRefuseReason in the form of object of BDRefuseReasonCollection </returns>
		public BDRefuseReasonCollection SelectAll()
		{
			BDRefuseReasonCollection bDRefuseReasonCollection = new BDRefuseReasonCollection();
			foreach (POS.DataLayer.BDRefuseReason _bDRefuseReason in POS.DataLayer.BDRefuseReasonBase.SelectAll())
			{
				_bDRefuseReasonWCF = new BDRefuseReason();
				
				_bDRefuseReasonWCF.RefuseReasonID = _bDRefuseReason.RefuseReasonID;
				_bDRefuseReasonWCF.RefuseReasonName = _bDRefuseReason.RefuseReasonName;
				
				bDRefuseReasonCollection.Add(_bDRefuseReasonWCF);
			}
			return bDRefuseReasonCollection;
		}
        /// <summary>
        /// This method will return a list of objects representing all records in the table.
        /// </summary>
        ///
        /// <returns>list of objects of class BDRefuseReason in the form of object of BDRefuseReasonCollection </returns>
        public BDRefuseReasonCollection SelectAll()
        {
            BDRefuseReasonCollection bDRefuseReasonCollection = new BDRefuseReasonCollection();

            foreach (POS.DataLayer.BDRefuseReason _bDRefuseReason in POS.DataLayer.BDRefuseReasonBase.SelectAll())
            {
                _bDRefuseReasonWCF = new BDRefuseReason();

                _bDRefuseReasonWCF.RefuseReasonID   = _bDRefuseReason.RefuseReasonID;
                _bDRefuseReasonWCF.RefuseReasonName = _bDRefuseReason.RefuseReasonName;

                bDRefuseReasonCollection.Add(_bDRefuseReasonWCF);
            }
            return(bDRefuseReasonCollection);
        }
        /// <summary>
        /// This method will return a list of objects representing the specified number of entries from the specified record number in the table
        /// using the value of the field specified
        /// </summary>
        ///
        /// <param name="field" type="string">Field of the class BDRefuseReason</param>
        /// <param name="fieldValue" type="object">Value for the field specified.</param>
        /// <param name="fieldValue2" type="object">Value for the field specified.</param>
        /// <param name="typeOperation" type="TypeOperation">Operator that is used if fieldValue2=null or fieldValue2="".</param>
        /// <param name="orderByStatement" type="string">The field value to number.</param>
        /// <param name="pageSize" type="int">Number of records returned.</param>
        /// <param name="skipPages" type="int">The number of missing pages.</param>
        ///
        /// <returns>List of object of class BDRefuseReason in the form of an object of class BDRefuseReasonCollection</returns>
        public BDRefuseReasonCollection SelectByFieldPaged(string field, object fieldValue, object fieldValue2, TypeOperation typeOperation, int pageSize, int skipPages, string orderByStatement)
        {
            BDRefuseReasonCollection bDRefuseReasonCollection = new BDRefuseReasonCollection();

            foreach (POS.DataLayer.BDRefuseReason _bDRefuseReason in POS.DataLayer.BDRefuseReasonBase.SelectByFieldPaged(field, fieldValue, fieldValue2, typeOperation, pageSize, skipPages, orderByStatement))
            {
                _bDRefuseReasonWCF = new BDRefuseReason();

                _bDRefuseReasonWCF.RefuseReasonID   = _bDRefuseReason.RefuseReasonID;
                _bDRefuseReasonWCF.RefuseReasonName = _bDRefuseReason.RefuseReasonName;

                bDRefuseReasonCollection.Add(_bDRefuseReasonWCF);
            }
            return(bDRefuseReasonCollection);
        }
        /// <summary>
        /// This method will return a list of objects representing the specified number of entries from the specified record number in the table.
        /// </summary>
        ///
        /// <param name="pageSize" type="int">Number of records returned.</param>
        /// <param name="skipPages" type="int">The number of missing pages.</param>
        /// <param name="orderByStatement" type="string">The field value to number.</param>
        ///
        /// <returns>list of objects of class BDRefuseReason in the form of an object of class BDRefuseReasonCollection </returns>
        public BDRefuseReasonCollection SelectAllPaged(int?pageSize, int?skipPages, string orderByStatement)
        {
            BDRefuseReasonCollection bDRefuseReasonCollection = new BDRefuseReasonCollection();

            foreach (POS.DataLayer.BDRefuseReason _bDRefuseReason in POS.DataLayer.BDRefuseReasonBase.SelectAllPaged(pageSize, skipPages, orderByStatement))
            {
                _bDRefuseReasonWCF = new BDRefuseReason();

                _bDRefuseReasonWCF.RefuseReasonID   = _bDRefuseReason.RefuseReasonID;
                _bDRefuseReasonWCF.RefuseReasonName = _bDRefuseReason.RefuseReasonName;

                bDRefuseReasonCollection.Add(_bDRefuseReasonWCF);
            }
            return(bDRefuseReasonCollection);
        }
        /// <summary>
        /// This method will get row(s) from the database using the value of the field specified
        /// </summary>
        ///
        /// <param name="field" type="string">Field of the class BDRefuseReason</param>
        /// <param name="fieldValue" type="object">Value for the field specified.</param>
        /// <param name="fieldValue2" type="object">Value for the field specified.</param>
        /// <param name="typeOperation" type="TypeOperation">Operator that is used if fieldValue2=null or fieldValue2="".</param>
        ///
        /// <returns>List of object of class BDRefuseReason in the form of an object of class BDRefuseReasonCollection</returns>
        public BDRefuseReasonCollection SelectByField(string field, object fieldValue, object fieldValue2, TypeOperation typeOperation)
        {
            BDRefuseReasonCollection bDRefuseReasonCollection = new BDRefuseReasonCollection();

            foreach (POS.DataLayer.BDRefuseReason _bDRefuseReason in POS.DataLayer.BDRefuseReasonBase.SelectByField(field, fieldValue, fieldValue2, typeOperation))
            {
                _bDRefuseReasonWCF = new BDRefuseReason();

                _bDRefuseReasonWCF.RefuseReasonID   = _bDRefuseReason.RefuseReasonID;
                _bDRefuseReasonWCF.RefuseReasonName = _bDRefuseReason.RefuseReasonName;

                bDRefuseReasonCollection.Add(_bDRefuseReasonWCF);
            }
            return(bDRefuseReasonCollection);
        }
		/// <summary>
		/// This method will get row(s) from the database using the value of the field specified
		/// </summary>
		///
		/// <param name="field" type="string">Field of the class BDRefuseReason</param>
		/// <param name="fieldValue" type="object">Value for the field specified.</param>
		/// <param name="fieldValue2" type="object">Value for the field specified.</param>
		/// <param name="typeOperation" type="TypeOperation">Operator that is used if fieldValue2=null or fieldValue2="".</param>
		///
		/// <returns>List of object of class BDRefuseReason in the form of an object of class BDRefuseReasonCollection</returns>
		public BDRefuseReasonCollection SelectByField(string field, object fieldValue, object fieldValue2, TypeOperation typeOperation)
		{
			BDRefuseReasonCollection bDRefuseReasonCollection = new BDRefuseReasonCollection();
			foreach (POS.DataLayer.BDRefuseReason _bDRefuseReason in POS.DataLayer.BDRefuseReasonBase.SelectByField(field, fieldValue, fieldValue2, typeOperation))
			{
				_bDRefuseReasonWCF = new BDRefuseReason();
				
				_bDRefuseReasonWCF.RefuseReasonID = _bDRefuseReason.RefuseReasonID;
				_bDRefuseReasonWCF.RefuseReasonName = _bDRefuseReason.RefuseReasonName;
				
				bDRefuseReasonCollection.Add(_bDRefuseReasonWCF);
			}
			return bDRefuseReasonCollection;
		}
		/// <summary>
		/// This method will return a list of objects representing the specified number of entries from the specified record number in the table 
		/// using the value of the field specified
		/// </summary>
		///
		/// <param name="field" type="string">Field of the class BDRefuseReason</param>
		/// <param name="fieldValue" type="object">Value for the field specified.</param>
		/// <param name="fieldValue2" type="object">Value for the field specified.</param>
		/// <param name="typeOperation" type="TypeOperation">Operator that is used if fieldValue2=null or fieldValue2="".</param>
		/// <param name="orderByStatement" type="string">The field value to number.</param>
		/// <param name="pageSize" type="int">Number of records returned.</param>
		/// <param name="skipPages" type="int">The number of missing pages.</param>
		///
		/// <returns>List of object of class BDRefuseReason in the form of an object of class BDRefuseReasonCollection</returns>
		public BDRefuseReasonCollection SelectByFieldPaged(string field, object fieldValue, object fieldValue2, TypeOperation typeOperation, int pageSize, int skipPages, string orderByStatement)
		{
			BDRefuseReasonCollection bDRefuseReasonCollection = new BDRefuseReasonCollection();
			foreach (POS.DataLayer.BDRefuseReason _bDRefuseReason in POS.DataLayer.BDRefuseReasonBase.SelectByFieldPaged(field, fieldValue, fieldValue2, typeOperation, pageSize, skipPages, orderByStatement))
			{
				_bDRefuseReasonWCF = new BDRefuseReason();
				
				_bDRefuseReasonWCF.RefuseReasonID = _bDRefuseReason.RefuseReasonID;
				_bDRefuseReasonWCF.RefuseReasonName = _bDRefuseReason.RefuseReasonName;
				
				bDRefuseReasonCollection.Add(_bDRefuseReasonWCF);
			}
			return bDRefuseReasonCollection;
		}
		/// <summary>
		/// This method will return a list of objects representing the specified number of entries from the specified record number in the table.
		/// </summary>
		///
		/// <param name="pageSize" type="int">Number of records returned.</param>
		/// <param name="skipPages" type="int">The number of missing pages.</param>
		/// <param name="orderByStatement" type="string">The field value to number.</param>
		///
		/// <returns>list of objects of class BDRefuseReason in the form of an object of class BDRefuseReasonCollection </returns>
		public BDRefuseReasonCollection SelectAllPaged(int? pageSize, int? skipPages, string orderByStatement)
		{
			BDRefuseReasonCollection bDRefuseReasonCollection = new BDRefuseReasonCollection();
			foreach (POS.DataLayer.BDRefuseReason _bDRefuseReason in POS.DataLayer.BDRefuseReasonBase.SelectAllPaged(pageSize, skipPages, orderByStatement))
			{
				_bDRefuseReasonWCF = new BDRefuseReason();
				
				_bDRefuseReasonWCF.RefuseReasonID = _bDRefuseReason.RefuseReasonID;
				_bDRefuseReasonWCF.RefuseReasonName = _bDRefuseReason.RefuseReasonName;
				
				bDRefuseReasonCollection.Add(_bDRefuseReasonWCF);
			}
			return bDRefuseReasonCollection;
		}
Example #9
0
		/// <summary>
		/// Populates the fields for multiple objects from the columns found in an open reader.
		/// </summary>
		///
		/// <param name="rdr" type="IDataReader">An object that implements the IDataReader interface</param>
		///
		/// <returns>Object of BDRefuseReasonCollection</returns>
		///
		/// <remarks>
		///
		/// <RevisionHistory>
		/// Author				Date			Description
		/// DLGenerator			3/7/2015 2:37:05 PM		Created function
		/// 
		/// </RevisionHistory>
		///
		/// </remarks>
		///
		internal static BDRefuseReasonCollection PopulateObjectsFromReaderWithCheckingReader(IDataReader rdr, DatabaseHelper oDatabaseHelper) 
		{

			BDRefuseReasonCollection list = new BDRefuseReasonCollection();
			
            if (rdr.Read())
			{
				BDRefuseReason obj = new BDRefuseReason();
				PopulateObjectFromReader(obj, rdr);
				list.Add(obj);
				while (rdr.Read())
				{
					obj = new BDRefuseReason();
					PopulateObjectFromReader(obj, rdr);
					list.Add(obj);
				}
				oDatabaseHelper.Dispose();
				return list;
			}
			else
			{
				oDatabaseHelper.Dispose();
				return null;
			}
			
		}
Example #10
0
		/// <summary>
		/// Populates the fields for multiple objects from the columns found in an open reader.
		/// </summary>
		///
		/// <param name="rdr" type="IDataReader">An object that implements the IDataReader interface</param>
		///
		/// <returns>Object of BDRefuseReasonCollection</returns>
		///
		/// <remarks>
		///
		/// <RevisionHistory>
		/// Author				Date			Description
		/// DLGenerator			3/7/2015 2:37:05 PM		Created function
		/// 
		/// </RevisionHistory>
		///
		/// </remarks>
		///
		internal static BDRefuseReasonCollection PopulateObjectsFromReader(IDataReader rdr) 
		{
			BDRefuseReasonCollection list = new BDRefuseReasonCollection();
			
			while (rdr.Read())
			{
				BDRefuseReason obj = new BDRefuseReason();
				PopulateObjectFromReader(obj,rdr);
				list.Add(obj);
			}
			return list;
			
		}