コード例 #1
0
        /// <summary>
        /// Parses the value type contained in the <c>source</c> argument and sets it on the <c>destination</c> VarInfo object.
        /// As a result of the execution of this method, the properties <see cref="ValueType">ValueType</see> and <see cref="Size">Size</see> are set.
        /// If source or destination are null, an <see cref="ArgumentNullException">ArgumentNullException</see> is thrown.
        /// </summary>
        /// <param name="source">source string</param>
        /// <param name="destination">destination VarInfo</param>
        public static void ParseValueType(string source, VarInfo destination)
        {
            int num;

            if ((source == null) || (destination == null))
            {
                throw new ArgumentNullException();
            }
            destination.ValueType = VarInfoValueTypes.GetVarInfoValueType(source, out num);
            destination.Size      = num;
        }