예제 #1
0
        /// <summary>
        /// Carga los tipos definidos por el usuario
        /// </summary>
        /// <returns>Tables </returns>
        UserDefinedTypes LoadUserDefinedTypes()
        {
            DataTable        wDttTypes = null;
            UserDefinedType  wUserDefinedType;
            UserDefinedTypes wUserDefinedTypes = new UserDefinedTypes();

            try
            {
                wDttTypes           = GetUserDefinedTypesFromDataBase();
                wDttTypes.TableName = "Types";
                foreach (DataRow oDtr in wDttTypes.Rows)
                {
                    wUserDefinedType                  = new UserDefinedType();
                    wUserDefinedType.Name             = oDtr["Name"].ToString();
                    wUserDefinedType.Nullable         = Convert.ToBoolean(oDtr["Nullable"]);
                    wUserDefinedType.Length           = Convert.ToInt32(oDtr["Length"]);
                    wUserDefinedType.NumericPrecision = Convert.ToInt32(oDtr["NumericPrecision"]);
                    wUserDefinedType.Schema           = oDtr["Schema"].ToString();
                    wUserDefinedType.SystemType       = oDtr["SystemType"].ToString();

                    wUserDefinedTypes.Add(wUserDefinedType);
                }


                wDttTypes.Dispose();
                wDttTypes = null;


                return(wUserDefinedTypes);
            }
            catch (Exception ex)
            { throw ex; }
        }
예제 #2
0
        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="pCnnString"></param>
        public UserDefinedTypesBack(CnnString pCnnString)

        {
            _CnnString = pCnnString;

            _GetUserDefinedTypesQuery = GetQuery();
            _UserDefinedTypes         = LoadUserDefinedTypes();
        }