In Bank Transformation Toolkit Version 6.1.1, new formatters are provided. But you can continue to use the formatters in previous versions. For documents about the formatters in pervious versions, refer to the documentation in previous releases of BTT. For more information about the differences between the two formatters, see Differences between formatters in BTT V6.1.1 and previous releases.
Formatters are what the toolkit uses to exchange data between toolkit entities such as operations, contexts, and services. Each formatter converts a specific data item into a string representation of the data item and parses a string into a specific data item. In this way, the toolkit uses formatters to build messages to do things such as sending a transaction to the host, writing a journal record, printing a form. Formatters enable applications to interact with many various entities without requiring changes to the application. For example, an application may use different formatters to send the same data to the electronic journal or to a financial printer.
Formatters are used to format (translate) structured data into a Host Message (usually a String to an Array of bytes), and unformat (translate) a Host Message into structured data. The Host Message complies with the format of the Host Application, while the structured data can be various kinds of data in Java™ World (such as Java Bean, Context in BTT and Service Data Object).
In a word, formatter is the message translator between Java Application and Host Application as shown in the following figure:
Besides formatting (translating) structured data into a Host Message, the Formmaters can also format (translate) the structured data into XML or JSON, and unformat (translate) XML and JSON message into structured data.