예제 #1
0
 ///<Summary>
 ///IssuetypeCollectionCount
 ///This method returns the collection count of BOIssuetype objects
 ///</Summary>
 ///<returns>
 ///Int32
 ///</returns>
 ///<parameters>
 ///
 ///</parameters>
 public static Int32 IssuetypeCollectionCount()
 {
     try
     {
         Int32 objCount = DAOIssuetype.SelectAllCount();
         return(objCount);
     }
     catch
     {
         throw;
     }
 }
예제 #2
0
 ///<Summary>
 ///Constructor
 ///This constructor initializes the business object from its respective data object
 ///</Summary>
 ///<returns>
 ///void
 ///</returns>
 ///<parameters>
 ///DAOIssuetype
 ///</parameters>
 protected internal BOIssuetype(DAOIssuetype daoIssuetype)
 {
     try
     {
         _id   = daoIssuetype.Id;
         _name = daoIssuetype.Name;
     }
     catch
     {
         throw;
     }
 }
예제 #3
0
 ///<Summary>
 ///Constructor
 ///Constructor using primary key(s)
 ///</Summary>
 ///<returns>
 ///void
 ///</returns>
 ///<parameters>
 ///Int32 id
 ///</parameters>
 public BOIssuetype(Int32 id)
 {
     try
     {
         DAOIssuetype daoIssuetype = DAOIssuetype.SelectOne(id);
         _id   = daoIssuetype.Id;
         _name = daoIssuetype.Name;
     }
     catch
     {
         throw;
     }
 }
예제 #4
0
 ///<Summary>
 ///IssuetypeCollectionFromSearchFieldsCount
 ///This method returns the collection count of BOIssuetype objects, filtered by a search object
 ///</Summary>
 ///<returns>
 ///Int32
 ///</returns>
 ///<parameters>
 ///
 ///</parameters>
 public static Int32 IssuetypeCollectionFromSearchFieldsCount(BOIssuetype boIssuetype)
 {
     try
     {
         DAOIssuetype daoIssuetype = new DAOIssuetype();
         daoIssuetype.Id   = boIssuetype.Id;
         daoIssuetype.Name = boIssuetype.Name;
         Int32 objCount = DAOIssuetype.SelectAllBySearchFieldsCount(daoIssuetype);
         return(objCount);
     }
     catch
     {
         throw;
     }
 }
예제 #5
0
        ///<Summary>
        ///Delete
        ///This method deletes one Issuetype record from the store
        ///</Summary>
        ///<returns>
        ///void
        ///</returns>
        ///<parameters>
        ///
        ///</parameters>
        public virtual void Delete()
        {
            DAOIssuetype daoIssuetype = new DAOIssuetype();

            RegisterDataObject(daoIssuetype);
            BeginTransaction("deleteBOIssuetype");
            try
            {
                daoIssuetype.Id = _id;
                daoIssuetype.Delete();
                CommitTransaction();
            }
            catch
            {
                RollbackTransaction("deleteBOIssuetype");
                throw;
            }
        }
예제 #6
0
        ///<Summary>
        ///IssuetypeCollection
        ///This method returns the collection of BOIssuetype objects
        ///</Summary>
        ///<returns>
        ///List[BOIssuetype]
        ///</returns>
        ///<parameters>
        ///
        ///</parameters>
        public static IList <BOIssuetype> IssuetypeCollection()
        {
            try
            {
                IList <BOIssuetype>  boIssuetypeCollection  = new List <BOIssuetype>();
                IList <DAOIssuetype> daoIssuetypeCollection = DAOIssuetype.SelectAll();

                foreach (DAOIssuetype daoIssuetype in daoIssuetypeCollection)
                {
                    boIssuetypeCollection.Add(new BOIssuetype(daoIssuetype));
                }

                return(boIssuetypeCollection);
            }
            catch
            {
                throw;
            }
        }
예제 #7
0
        ///<Summary>
        ///IssuetypeCollectionFromSearchFields
        ///This method returns the collection of BOIssuetype objects, filtered by a search object
        ///</Summary>
        ///<returns>
        ///List<BOIssuetype>
        ///</returns>
        ///<parameters>
        ///
        ///</parameters>
        public static IList <BOIssuetype> IssuetypeCollectionFromSearchFields(BOIssuetype boIssuetype)
        {
            try
            {
                IList <BOIssuetype> boIssuetypeCollection = new List <BOIssuetype>();
                DAOIssuetype        daoIssuetype          = new DAOIssuetype();
                daoIssuetype.Id   = boIssuetype.Id;
                daoIssuetype.Name = boIssuetype.Name;
                IList <DAOIssuetype> daoIssuetypeCollection = DAOIssuetype.SelectAllBySearchFields(daoIssuetype);

                foreach (DAOIssuetype resdaoIssuetype in daoIssuetypeCollection)
                {
                    boIssuetypeCollection.Add(new BOIssuetype(resdaoIssuetype));
                }

                return(boIssuetypeCollection);
            }
            catch
            {
                throw;
            }
        }
예제 #8
0
        ///<Summary>
        ///SaveNew
        ///This method persists a new Issuetype record to the store
        ///</Summary>
        ///<returns>
        ///void
        ///</returns>
        ///<parameters>
        ///
        ///</parameters>
        public virtual void SaveNew()
        {
            DAOIssuetype daoIssuetype = new DAOIssuetype();

            RegisterDataObject(daoIssuetype);
            BeginTransaction("savenewBOIssuetype");
            try
            {
                daoIssuetype.Name = _name;
                daoIssuetype.Insert();
                CommitTransaction();

                _id      = daoIssuetype.Id;
                _name    = daoIssuetype.Name;
                _isDirty = false;
            }
            catch
            {
                RollbackTransaction("savenewBOIssuetype");
                throw;
            }
        }
예제 #9
0
        ///<Summary>
        ///Update
        ///This method updates one Issuetype record in the store
        ///</Summary>
        ///<returns>
        ///void
        ///</returns>
        ///<parameters>
        ///BOIssuetype
        ///</parameters>
        public virtual void Update()
        {
            DAOIssuetype daoIssuetype = new DAOIssuetype();

            RegisterDataObject(daoIssuetype);
            BeginTransaction("updateBOIssuetype");
            try
            {
                daoIssuetype.Id   = _id;
                daoIssuetype.Name = _name;
                daoIssuetype.Update();
                CommitTransaction();

                _id      = daoIssuetype.Id;
                _name    = daoIssuetype.Name;
                _isDirty = false;
            }
            catch
            {
                RollbackTransaction("updateBOIssuetype");
                throw;
            }
        }