@Test public void testAddAppender() throws Exception { TestEvent event = new TestEvent(); NOPAppender<TestEvent> ta = new NOPAppender<TestEvent>(); ta.start(); aai.addAppender(ta); ta = new NOPAppender<TestEvent>(); ta.setName("test"); ta.start(); aai.addAppender(ta); int size = aai.appendLoopOnAppenders(event); assertTrue("Incorrect number of appenders", size == 2); }
public void addAppender(Appender<E> newAppender) { if (newAppender == null) { throw new IllegalArgumentException("Null argument disallowed"); } appenderList.addIfAbsent(newAppender); }
AppenderAttachableImpl implements AppenderAttachable<E> { public void addAppender(Appender<E> newAppender) { if (newAppender == null) { throw new IllegalArgumentException("Null argument disallowed"); } appenderList.addIfAbsent(newAppender); } }
AppenderAttachableImpl implements AppenderAttachable<E> { public void addAppender(Appender<E> newAppender) { if (newAppender == null) { throw new IllegalArgumentException("Null argument disallowed"); } appenderList.addIfAbsent(newAppender); }  }
AppenderAttachableImpl implements AppenderAttachable<E> { public void addAppender(Appender<E> newAppender) { if (newAppender == null) { throw new IllegalArgumentException("Null argument disallowed"); } appenderList.addIfAbsent(newAppender); }  void addAppender(Appender<E> newAppender); int appendLoopOnAppenders(E e); Iterator<Appender<E>> iteratorForAppenders(); Appender<E> getAppender(String name); boolean isAttached(Appender<E> appender); void detachAndStopAllAppenders(); boolean detachAppender(Appender<E> appender); boolean detachAppender(String name); }
AppenderAttachableImpl implements AppenderAttachable<E> { public void addAppender(Appender<E> newAppender) { if (newAppender == null) { throw new IllegalArgumentException("Null argument disallowed"); } appenderList.addIfAbsent(newAppender); }  void addAppender(Appender<E> newAppender); int appendLoopOnAppenders(E e); Iterator<Appender<E>> iteratorForAppenders(); Appender<E> getAppender(String name); boolean isAttached(Appender<E> appender); void detachAndStopAllAppenders(); boolean detachAppender(Appender<E> appender); boolean detachAppender(String name);  }