@Test( expected = HandlerRegistrationException.class ) public void testMsgHandlerNull() throws KettleException { messageEventService.addHandler( operationMessageEvent, null ); }
public final void addHandler( final Message eventType, final MessageEventHandler handler ) throws HandlerRegistrationException { if ( handler != null && eventType != null ) { addHandlerFor( eventType, handler ); } else { throw new HandlerRegistrationException( "One of the parameters is null : " + " eventType: " + eventType + " handler:" + handler ); } }
MessageEventService { public final void addHandler( final Message eventType, final MessageEventHandler handler ) throws HandlerRegistrationException { if ( handler != null && eventType != null ) { addHandlerFor( eventType, handler ); } else { throw new HandlerRegistrationException( "One of the parameters is null : " + " eventType: " + eventType + " handler:" + handler ); } } }
MessageEventService { public final void addHandler( final Message eventType, final MessageEventHandler handler ) throws HandlerRegistrationException { if ( handler != null && eventType != null ) { addHandlerFor( eventType, handler ); } else { throw new HandlerRegistrationException( "One of the parameters is null : " + " eventType: " + eventType + " handler:" + handler ); } } MessageEventService(); }
MessageEventService { public final void addHandler( final Message eventType, final MessageEventHandler handler ) throws HandlerRegistrationException { if ( handler != null && eventType != null ) { addHandlerFor( eventType, handler ); } else { throw new HandlerRegistrationException( "One of the parameters is null : " + " eventType: " + eventType + " handler:" + handler ); } } MessageEventService(); void fireEvent( final Message event ); final void addHandler( final Message eventType, final MessageEventHandler handler ); final boolean hasHandlers( final Message eventType ); List<MessageEventHandler> getHandlersFor( final Message eventType ); }
MessageEventService { public final void addHandler( final Message eventType, final MessageEventHandler handler ) throws HandlerRegistrationException { if ( handler != null && eventType != null ) { addHandlerFor( eventType, handler ); } else { throw new HandlerRegistrationException( "One of the parameters is null : " + " eventType: " + eventType + " handler:" + handler ); } } MessageEventService(); void fireEvent( final Message event ); final void addHandler( final Message eventType, final MessageEventHandler handler ); final boolean hasHandlers( final Message eventType ); List<MessageEventHandler> getHandlersFor( final Message eventType );  }