borland Packages Class Hierarchy dx.text Package
java.lang.Object +----com.borland.dx.text.ItemFormatter +----com.borland.dx.text.VariantFormatter +----com.borland.dx.text.BinaryFormatter
Constructors Properties Methods
Implements Serializable
The BinaryFormatter component is the default formatter and parser of Variant.INPUTSTREAM type data. This is a placeholder class that ensures that formatting requests of binary values do not generate an Exception.
public BinaryFormatter()Constructs a BinaryFormatter object.
public Format getFormatObj()This property is used internally by other com.borland classes. You should never use this property directly.
public Locale getLocale()This property is used internally by other com.borland classes. You should never use this property directly.
public String getPattern()This property is used internally by other com.borland classes. You should never use this property directly.
public int getVariantType()This property is used internally by other com.borland classes. You should never use this property directly.
public String format(Variant value)Returns a String representing the given value stored in the supplied object. All reasonable attempts are made to "cast" the type found in the object into the appropriate type specified in the constructor of the implementing classes. A returned empty string indicates a null or empty input value. null means the formatting failed.
public Object getSpecialObject(int objType)Returns the value of the specified special object.
Some formatter classes define special objects for their own use. You must know the internal details of the Format subclass being used to use getSpecialObject().
public void parse(String stringValue, Variant value)Analyzes the given String and produces as output an Object containing the appropriate value. A null return value results when stringValue is null or empty.
public void parse(String stringValue, Variant value, int variantType)An alternative form of parse() that allows the type of Variant returned to be specified.
public String setPattern(String pattern)Sets the pattern used for parsing and formatting to a new pattern, returning the old pattern. The new pattern must be of the same basic type associated with this type of formatter. For example, if you used a Date/Time pattern in the constructor, you can't switch to a numeric pattern as each basic pattern type has its own data-dependent format() and parse() methods.
If the new pattern is null (or empty), setPattern() chooses a default pattern for the current locale.
public Object setSpecialObject(int objType, Object obj)Some formatter classes define special objects for their own use. This method allows them to be set. You must know the internal details of the Format subclass being used to use setSpecialObject().
The returned value is the prior value of the object.