@Test(expected = NullPointerException.class) public void testFormatNull() { CollectorFormatter f = new CollectorFormatter("{1}", (Formatter) null, (Comparator<LogRecord>) null); f.format((LogRecord) null); }
@Override public String format(final LogRecord record) { if (record == null) { throw new NullPointerException(); } boolean accepted; do { final LogRecord peek = peek(); LogRecord update = apply(peek != null ? peek : record, record); if (peek != update) { update.getSourceMethodName(); accepted = acceptAndUpdate(peek, update); } else { accepted = true; accept(record); } } while (!accepted); return ""; }
CollectorFormatter extends Formatter { @Override public String format(final LogRecord record) { if (record == null) { throw new NullPointerException(); } boolean accepted; do { final LogRecord peek = peek(); LogRecord update = apply(peek != null ? peek : record, record); if (peek != update) { update.getSourceMethodName(); accepted = acceptAndUpdate(peek, update); } else { accepted = true; accept(record); } } while (!accepted); return ""; } }
CollectorFormatter extends Formatter { @Override public String format(final LogRecord record) { if (record == null) { throw new NullPointerException(); } boolean accepted; do { final LogRecord peek = peek(); LogRecord update = apply(peek != null ? peek : record, record); if (peek != update) { update.getSourceMethodName(); accepted = acceptAndUpdate(peek, update); } else { accepted = true; accept(record); } } while (!accepted); return ""; } CollectorFormatter();  CollectorFormatter(String format);  CollectorFormatter(String format, Formatter f,
            Comparator<? super LogRecord> c); }
CollectorFormatter extends Formatter { @Override public String format(final LogRecord record) { if (record == null) { throw new NullPointerException(); } boolean accepted; do { final LogRecord peek = peek(); LogRecord update = apply(peek != null ? peek : record, record); if (peek != update) { update.getSourceMethodName(); accepted = acceptAndUpdate(peek, update); } else { accepted = true; accept(record); } } while (!accepted); return ""; } CollectorFormatter();  CollectorFormatter(String format);  CollectorFormatter(String format, Formatter f,
            Comparator<? super LogRecord> c); @Override String format(final LogRecord record); @Override String getTail(final Handler h); @Override String toString(); }
CollectorFormatter extends Formatter { @Override public String format(final LogRecord record) { if (record == null) { throw new NullPointerException(); } boolean accepted; do { final LogRecord peek = peek(); LogRecord update = apply(peek != null ? peek : record, record); if (peek != update) { update.getSourceMethodName(); accepted = acceptAndUpdate(peek, update); } else { accepted = true; accept(record); } } while (!accepted); return ""; } CollectorFormatter();  CollectorFormatter(String format);  CollectorFormatter(String format, Formatter f,
            Comparator<? super LogRecord> c); @Override String format(final LogRecord record); @Override String getTail(final Handler h); @Override String toString();  }