protected Formatter format(FormatterConfiguration conf, Locale locale, Object e, Object format, int start, int end, Object... args) {
        try {
            if (conf == null) conf = this.conf;
            if (locale == null) locale = conf.locale();
            if (locale == null) locale = Locale.ROOT;
            String fString = toFormatString(format, locale);
            if (end < 0) end = fString.length() - end - 1;
            Parser p;
            if (e == null && args != null && 
                    args.length == 1 && (args[0] instanceof FormatArgs)) {
                p = new Parser(conf, locale, (FormatArgs) args[0]);
            } else {
                p = new Parser(conf, locale, e, args);
            }
            p.parse(fString, start, end);
        } catch (IOException ex) {
            lastIOException = ex;
        }
        return this;
    }
protected Formatter format ( FormatterConfiguration conf , Locale locale , Object e , Object format , int start , int end , Object ... args ) { try { if ( conf == null ) conf = this . conf ; if ( locale == null ) locale = conf . locale ( ) ; if ( locale == null ) locale = Locale . ROOT ; String fString = toFormatString ( format , locale ) ; if ( end < 0 ) end = fString . length ( ) - end - 1 ; Parser p ; if ( e == null && args != null && args . length == 1 && ( args [ 0 ] instanceof FormatArgs ) ) { p = new Parser ( conf , locale , ( FormatArgs ) args [ 0 ] ) ; } else { p = new Parser ( conf , locale , e , args ) ; } p . parse ( fString , start , end ) ; } catch ( IOException ex ) { lastIOException = ex ; } return this ; }
Writes a formatted string to this object's destination using the
specified format string and arguments.

@param  conf
The formatter configuration, provides additional formats and
the default locale. If {@code null}, the configuration specified
at the construction of this formatter is used.

@param  locale
The {@linkplain java.util.Locale locale} to apply during
formatting. If {@code null}, the configuration will be used to
obtain a locale.

@param  e
The object that is used as exception argument {@code E}.

@param  format
A format string as described in Format string syntax. If the
object does not implement {@link Localizable}, it is converted
into a string.

@param  start
The index where parsing the format string begins.

@param  end
The index where parsing the format string ends
(-1 for the entire string).

@param  args
Arguments referenced by the format specifiers in the format
string.

@throws  IllegalFormatException
If a format string contains an illegal syntax, a format
specifier that is incompatible with the given arguments,
insufficient arguments given the format string, or other
illegal conditions.

@throws  FormatterClosedException
If this formatter has been closed by invoking its {@link
#close()} method

@return  This formatter
@see java.util.Formatter#format(java.lang.String, java.lang.Object[])