TFormatter classes

When you derive classes from TFormatter, in addition to providing the standard constructor, destructor, and operator functions, override the following member functions:

CanFormat checks whether this formatter can manipulate a certain type of formattable data. This function calls the TFormattable::DescendsFrom function of the TFormattable derived class at the same level as this TFormatter derived class. For example, if this is a TDateTimeFormatter, it calls the TDateTimeFormattable::DescendsFrom member function.

CreateFormattable creates an instance of the type of formattable data that this formatter handles.

CreateFormatResult returns information about the results of a formatting operation.

CreateScanResult returns information about the results of a scanning operation.

Format converts a formattable data type to a text string.

Scan converts text to a formattable data type.


[Contents] [Previous] [Next]
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.

Generated with WebMaker