The printer may print any part, or the whole, of the input BigMoney.
Typically, a complete print is constructed from a number of smaller printers
that have been combined using MoneyFormatterBuilder.
This interface must be implemented with care to ensure other classes operate correctly. All instantiable implementations must be thread-safe, and should generally be final and immutable.
| Modifier and Type | Method and Description |
|---|---|
| public void | print(MoneyPrintContext
the context being used, not null context, Appendable the appendable to add to, not null appendable, BigMoney the money to print, not null money)Prints part of a monetary value to the output appendable. |
| back to summary | |
|---|---|
| public void print(MoneyPrintContext context, Appendable appendable, BigMoney money) throws IOException Prints part of a monetary value to the output appendable.
The implementation determines what to append, which may be some or all
of the data held in the The context is not a thread-safe object and a new instance will be created for each print. The context must not be stored in an instance variable or shared with any other threads.
| |