EventInfo

This class stores event information that will be logged by the logEvent method. The event will be associated with a business document and will be visible in the console. It can be initialized in five ways. It includes the following methods:

The class also defines four constants:

Constructors

The object can be initialized in five distinct ways:

With a business document

This method can be used by workflow handlers, action steps, senders, and their handlers.

public EventInfo(java.lang.String eventCode,
                 BusinessDocumentInterface document,
                 java.lang.String[] params)

With a business document and an exception or error

This method can be used by workflow handlers, action steps, senders, and their handlers when an exception or error occurs.

public EventInfo(java.lang.String eventCode,
                 BusinessDocumentInterface document,
                 java.lang.String[] params,
                 java.lang.Throwable t)

With a document UUID

This method can be used by a receiver and its handlers.

public EventInfo(java.lang.String eventCode,
                 java.lang.String documentUUID,
                 java.lang.String[] params)

With a document UUID and an error or exception

This method can be used by the receiver and its handlers when an exception or error occurs.

public EventInfo(String eventCode, String documentUUID, String[] params,
                  Throwable t)

With a document UUID and document parent UUID

public EventInfo(java.lang.String eventCode,
                 java.lang.String documentUUID,
                 java.lang.String documentParentUUID,
                 java.lang.String[] params)

Method

getEventCode

Method description

Retrieves the event code

Syntax

public String getEventCode()

Parameters

None

Method

getBusinessDocument

Method description

Retrieves the business document

Syntax

public BusinessDocument getBusinessDocument()

Parameters

None

Method

getDocumentParentUUID

Method description

Retrieves the document parent UUID.

Syntax

public java.lang.String getDocumentParentUUID()

Parameters

None

Method

getDocumentUUID

Method description

Retrieves the document UUID

Syntax

public String getDocumentUUID

Parameters

None

Method

getParams

Method description

Retrieves the parameter array

Syntax

public String[] getParams()

Parameters

None

Method

getStackTrace

Method description

Retrieves the stack trace

Syntax

public Throwable getStackTrace()

Parameters

None

Method

getSourceClass

Method description

Retrieves the source class

Syntax

public String getSourceClass()

Parameters

None

Method

setSourceClass

Method description

Sets the source class

Syntax

public void setSourceClass(String sourceClass)

Parameters

sourceClass
The source class

Method

setFaultType

Method description

Sets the fault type. See Constants.

Syntax

public void setFaultType(String faultType)

Parameters

faultType
The fault type

Method

getFaultType

Method description

Retrieves the fault type. See Constants.

Syntax

public String getFaultType()

Parameters

None

Constants

These constants are used to define fault types:

   public static final String FAULTTYPE_UNKNOWN = "0"
    public static final String FAULTTYPE_SOURCE = "1"
    public static final String FAULTTYPE_TARGET = "2"
    public static final String FAULTTYPE_SYSTEM = "3"

Copyright IBM Corp. 2003, 2005