August 2003
Intermediate to advanced
928 pages
32h 1m
English
FormatterConverter
This class is a basic implementation
of the
IFormatterConverter interface. It provides a
formatter with a means to convert values to different base types. The
generic Convert( ) method converts a value into a
specified type. The various To* methods convert
values into specific types.
public class FormatterConverter : IFormatterConverter { // Public Constructors public FormatterConverter( ); // Public Instance Methods public object Convert(objectvalue, Typetype); // implements IFormatterConverter public object Convert(objectvalue, TypeCodetypeCode); // implements IFormatterConverter public bool ToBoolean(objectvalue); // implements IFormatterConverter public byte ToByte(objectvalue); // implements IFormatterConverter public char ToChar(objectvalue); // implements IFormatterConverter public DateTime ToDateTime(objectvalue); // implements IFormatterConverter public decimal ToDecimal(objectvalue); // implements IFormatterConverter public double ToDouble(objectvalue); // implements IFormatterConverter public short ToInt16(objectvalue); // implements IFormatterConverter public int ToInt32(objectvalue); // implements IFormatterConverter public long ToInt64(objectvalue); // implements IFormatterConverter public sbyte ToSByte(objectvalue); // implements IFormatterConverter public float ToSingle(objectvalue); // implements IFormatterConverter public string ToString(objectvalue); // implements IFormatterConverter public ushort ToUInt16(object ...