code: public StringBuffer format(CurrencyAmount currAmt,
                                 StringBuffer toAppendTo,
                                 FieldPosition pos) {
          // Default implementation -- subclasses may override
          synchronized(this) {
              Currency save = getCurrency(), curr = currAmt.getCurrency();
              boolean same = curr.equals(save);
              if (!same) setCurrency(curr);
              format(currAmt.getNumber(), toAppendTo, pos);
              if (!same) setCurrency(save);
          }
          return toAppendTo;
      }
docs: <strong>[icu]</strong> Formats a CurrencyAmount. Specialization of format.
  @see java.text.Format#format(Object, StringBuffer, FieldPosition)