com.bea.wlevs.ede.api
Interface EventBuilder


public interface EventBuilder

Builder that knows how to create events of a certain event type. Defining a custom builder for an event type is necessary when the POJO representing a event does not expose the necessary setter and getter methods for the event properties. For example, if the POJO is immutable, a builder would be necessary to invoke the constructor with all of the required property values in the createEvent method since the default system builder would not be able to set the properties through reflection.


Inner Class Summary
static interface EventBuilder.Factory
          Factory for event builder.
 
Method Summary
 java.lang.Object createEvent()
          Instantiate an event of the type associated with this event builder.
 void put(java.lang.String property, java.lang.Object value)
          Set the property of the event being created to the specified value.
 

Method Detail

put

public void put(java.lang.String property,
                java.lang.Object value)
         throws java.lang.IllegalStateException
Set the property of the event being created to the specified value. The engine first invokes a series of these methods for each property being set prior to invoking the createEvent method.

Parameters:
property - name of the property
value - value for the property
Throws:
java.lang.IllegalStateException -  

createEvent

public java.lang.Object createEvent()
Instantiate an event of the type associated with this event builder. The engine will invoke this method as the final step after all put methods have been called.

Returns:
instance of the event


Copyright © 2007 BEA Systems All Rights Reserved.