예제 #1
0
        public static VehicleTypeObject VehicleTypeRowToObject(DataRow VehicleType)
        {
            VehicleTypeObject obj = new VehicleTypeObject();

            try
            {
                if (VehicleType != null)
                {
                    if (RowFunctions.GetValueFromRowToInt64(VehicleType, VehicleTypeObject.VEHTID, false, DataRowVersion.Current) != Constants.NullInt)
                    {
                        obj.VehtID             = RowFunctions.GetValueFromRowToInteger(VehicleType, VehicleTypeObject.VEHTID, true, DataRowVersion.Current);
                        obj.Transc_VehicleType = RowFunctions.GetValueFromRowToInteger(VehicleType, VehicleTypeObject.TRANSC_VEHICLETYPE, false, DataRowVersion.Current);
                        obj.Type = RowFunctions.GetValueFromRowToString(VehicleType, VehicleTypeObject.TYPE, false, DataRowVersion.Current);
                    }
                    return(obj);
                }
                obj = null;
            }
            catch (System.Exception exception1)
            {
                Exception innerException = exception1;
                throw new Exception(MethodBase.GetCurrentMethod().Name, innerException);
            }
            return(obj);
        }