System.Xml.XmlConverter.ToDecimal C# (CSharp) Méthode

ToDecimal() static public méthode

static public ToDecimal ( byte buffer, int offset, int count ) : decimal
buffer byte
offset int
count int
Résultat decimal
        static public decimal ToDecimal(byte[] buffer, int offset, int count)
        {
            return ToDecimal(ToString(buffer, offset, count));
        }

Same methods

XmlConverter::ToDecimal ( string value ) : decimal

Usage Example

Exemple #1
0
        public decimal ToDecimal()
        {
            ValueHandleType type = _type;

            if (type == ValueHandleType.Decimal)
            {
                return(GetDecimal());
            }
            if (type == ValueHandleType.Zero)
            {
                return(0);
            }
            if (type == ValueHandleType.One)
            {
                return(1);
            }
            if (type >= ValueHandleType.Int8 && type <= ValueHandleType.Int64)
            {
                return(ToLong());
            }
            if (type == ValueHandleType.UInt64)
            {
                return(GetUInt64());
            }
            if (type == ValueHandleType.UTF8)
            {
                return(XmlConverter.ToDecimal(_bufferReader.Buffer, _offset, _length));
            }
            return(XmlConverter.ToDecimal(GetString()));
        }
All Usage Examples Of System.Xml.XmlConverter::ToDecimal