Пример #1
0
        public bool AddEmployeeBLL(Employee employee)
        {
            bool status = false;

            try
            {
                if (ValidateEmp(employee))
                {
                    status = employeeDal.AddEmployeeDAL(employee);
                }
            }
            catch (Exception ex)
            {
                throw ex;
            }
            return(status);
        }
Пример #2
0
        public bool EmployeeAddBLL(EmployeeEntity employeeEntity)
        {
            bool isAdded = false;

            try
            {
                if (ValidateEmployee(employeeEntity))
                {
                    isAdded = employeeDAL.AddEmployeeDAL(employeeEntity);
                }
            }
            catch (ALMSException e)
            {
                throw e;
            }
            return(isAdded);
        }
Пример #3
0
        public bool AddEmployeeBL(Employee newEmployee)
        {
            bool employeeAdded = false;

            try
            {
                if (ValidateEmployee(newEmployee))
                {
                    EmployeeDAL employeeDAL = new EmployeeDAL();         //calling DAL class method to add employee
                    employeeAdded = employeeDAL.AddEmployeeDAL(newEmployee);
                }
            }
            catch (PecuniaException)
            {
                throw;
            }

            return(employeeAdded);
        }
Пример #4
0
        public static bool AddEmployeeBL(Employee objEmployee)
        {
            bool employeeAdded = false;

            try
            {
                if (ValidateEmployee(objEmployee))
                {
                    employeeAdded = EmployeeDAL.AddEmployeeDAL(objEmployee);
                }
            }
            catch (EmployeeAppException)
            {
                throw;
            }
            catch (SystemException ex)
            {
                throw ex;
            }

            return(employeeAdded);
        }
Пример #5
0
        public static bool AddEmployeeBL(Employee newEmployee)
        {
            bool employeeAdded = false;

            try
            {
                if (ValidateEmployee(newEmployee))
                {
                    EmployeeDAL employeeDAL = new EmployeeDAL();
                    employeeAdded = employeeDAL.AddEmployeeDAL(newEmployee);
                }
            }
            catch (EmployeePhoneBookException)
            {
                throw;
            }
            catch (Exception ex)
            {
                throw ex;
            }

            return(employeeAdded);
        }