WebSphere WebSphere Enterprise Service Bus, Version 6.0.1 Operating Systems: AIX, HP-UX, Linux, Solaris, Windows

Creating a new event factory

An event factory is used to create new events.

Why and when to perform this task

To create a new event factory, use the event factory factory, implemented as the class EventFactoryFactory. This class has no instances; instead, it provides two static methods used to create event factories. The choice of which method to use depends upon whether you want to use a content handler to implement automatic content completion. For more information, see Completing event content automatically.

To create a generic event factory with no content handler, use the createEventFactory() static method of EventFactoryFactory:
EventFactory eventFactory = 
     (EventFactory) EventFactoryFactory.createEventFactory();
To create an event factory with a content handler, use the createEventFactory(ContentHandler) method, specifying the content handler you want to use:
EventFactory eventFactory = 
     (EventFactory) EventFactoryFactory.createEventFactory(contentHandler);

In either case, the returned object is an event factory you can use to create new events.


Task topic

Terms of Use | Rate this page

Timestamp iconLast updated: 13 Dec 2005
http://publib.boulder.ibm.com/infocenter/dmndhelp/v6rxmx/index.jsp?topic=/com.ibm.websphere.wesb.doc\doc\tcei_admin_createEventFactory.html

(C) Copyright IBM Corporation 2005. All Rights Reserved.
This information center is powered by Eclipse technology. (http://www.eclipse.org)