org.eclipse.hyades.logging.events.cbe
Interface AssociatedEvent

All Superinterfaces:
org.eclipse.emf.ecore.EObject, org.eclipse.emf.common.notify.Notifier, java.io.Serializable
All Known Implementing Classes:
AssociatedEventImpl

public interface AssociatedEvent
extends org.eclipse.emf.ecore.EObject, java.io.Serializable

A representation of the model object 'Associated Event'.

The AssociatedEvent type allows for associated events to be grouped. It allows for identifying associated events their association engines. The associationEngine may be the reference to the application that created the association.

Since:
1.0

The following features are supported:

Version:
1.0.1
Author:
Denilson Nastacio
See Also:
EventPackage.getAssociatedEvent()

Method Summary
 void addResolvedEvent(java.lang.String globalInstanceId)
          Adds a Common Base Event reference to the array of resolved events.
 void clearResolvedEvents()
          Removes all Common Base Event references in the array of resolved events.
 java.lang.String getAssociationEngine()
           Returns the value of the 'Association Engine' attribute.
 AssociationEngine getAssociationEngineInfo()
           Returns the value of the 'Association Engine Info' containment reference.
 java.lang.String getResolvedEvents()
           Returns the value of the 'Resolved Events' attribute.
 java.lang.String[] getResolvedEventsAsArray()
           Returns the value of the 'Resolved Events' attribute.
 void init()
          Resets the object's properties to their initial (e.g. null) state.
 void removeResolvedEvent(java.lang.String globalInstanceId)
          Removes a named Common Base Event reference in the array of resolved events.
 void setAssociationEngine(java.lang.String value)
           Sets the value of the 'Association Engine' attribute.
 void setAssociationEngineInfo(AssociationEngine value)
           Sets the value of the 'Association Engine Info' containment reference.
 void setAssociationEngineInfo(java.lang.String associationEngineName, java.lang.String associationEngineType, java.lang.String associationEngineId)
           Helper method for creating and setting the association engine information for this object.
 void setResolvedEvents(java.lang.String value)
           Sets the value of the 'Resolved Events' attribute.
 void setResolvedEventsAsArray(java.lang.String[] value)
           Sets the value of the 'Resolved Events' attribute.
 void validate()
           Checks whether the contents of this object conforms to the CBE specification.
 
Methods inherited from interface org.eclipse.emf.ecore.EObject
eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eIsProxy, eIsSet, eResource, eSet, eUnset
 
Methods inherited from interface org.eclipse.emf.common.notify.Notifier
eAdapters, eDeliver, eNotify, eSetDeliver
 

Method Detail

addResolvedEvent

public void addResolvedEvent(java.lang.String globalInstanceId)
Adds a Common Base Event reference to the array of resolved events. Array of Common Base Event globalInstanceIds corresponding to the event(s) that are associated with this event. This is a REQUIRED property.

Parameters:
globalInstanceId - The new Common Base Event globalInstanceId.
Since:
1.0
See Also:
CommonBaseEvent

clearResolvedEvents

public void clearResolvedEvents()
Removes all Common Base Event references in the array of resolved events. Array of Common Base Event globalInstanceIds corresponding to the event(s) that are associated with this event. This is a REQUIRED property.

Since:
1.0
See Also:
CommonBaseEvent

removeResolvedEvent

public void removeResolvedEvent(java.lang.String globalInstanceId)
Removes a named Common Base Event reference in the array of resolved events. Array of Common Base Event globalInstanceIds corresponding to the event(s) that are associated with this event. This is a REQUIRED property.

Parameters:
globalInstanceId - The removed Common Base Event globalInstanceId.
Since:
1.0
See Also:
CommonBaseEvent

getAssociationEngine

public java.lang.String getAssociationEngine()

Returns the value of the 'Association Engine' attribute.

Returns:
the value of the 'Association Engine' attribute.
See Also:
setAssociationEngine(String), EventPackage.getAssociatedEvent_AssociationEngine()

setAssociationEngine

public void setAssociationEngine(java.lang.String value)

Sets the value of the 'Association Engine' attribute.

Reference to the AssocationEngine that created this AssociatedEvent. The associationEngine and associationEnginInfo properties are mutually exclusive. One of these properties must be defined. If this attribute is set, the 'Association Engine Info' attribute should not be set.

Parameters:
value - the new value of the 'Association Engine' attribute.
Throws:
java.lang.IllegalStateException - if the 'Association Engine Info' attribute is currently set.
See Also:
getAssociationEngine()

getResolvedEvents

public java.lang.String getResolvedEvents()

Returns the value of the 'Resolved Events' attribute.

The returned string follows the IDREFS type as stated in the CBE and defined in the XML Schema specification, which is a space-separated list of IDREF strings.

Returns:
the value of the 'Resolved Events' attribute.
See Also:
setResolvedEvents(String), EventPackage.getAssociatedEvent_ResolvedEvents()

getResolvedEventsAsArray

public java.lang.String[] getResolvedEventsAsArray()

Returns the value of the 'Resolved Events' attribute.

The returned string follows the IDREFS type as stated in the CBE and defined in the XML Schema specification. In this case it will be an array of IDREF strings. If there are no resolved events then an empty array will be returned.

Returns:
the value of the 'Resolved Events' attribute.
See Also:
setResolvedEvents(String), setResolvedEventsAsArray(String[]), getResolvedEvents(), EventPackage.getAssociatedEvent_ResolvedEvents()

setResolvedEvents

public void setResolvedEvents(java.lang.String value)

Sets the value of the 'Resolved Events' attribute.

This is an array of globalInstanceIds corresponding to the events that are associated with this event.

This is a required property, an array with at least one element.

The parameter should follow the IDREFS type as stated in the CBE and defined in the XML Schema specification, which is a space-separated list of IDREF strings.

Parameters:
value - the new value of the 'Resolved Events' attribute.
See Also:
getResolvedEvents(), validate()

setResolvedEventsAsArray

public void setResolvedEventsAsArray(java.lang.String[] value)

Sets the value of the 'Resolved Events' attribute.

The parameter should follow the IDREFS type as stated in the CBE and defined in the XML Schema specification. In this case it will be an array of IDREF strings.

This method does not validate the parameter, which is left to separate calls to the validate method.

Parameters:
value - the new value of the 'Resolved Events' attribute.
See Also:
setResolvedEvents(String), getResolvedEvents(), getResolvedEventsAsArray(), validate()

getAssociationEngineInfo

public AssociationEngine getAssociationEngineInfo()

Returns the value of the 'Association Engine Info' containment reference.

Returns:
the value of the 'Association Engine Info' containment reference.
See Also:
setAssociationEngineInfo(AssociationEngine), EventPackage.getAssociatedEvent_AssociationEngineInfo()

setAssociationEngineInfo

public void setAssociationEngineInfo(AssociationEngine value)

Sets the value of the 'Association Engine Info' containment reference.

Identifies the application that establishes association among related or associated events. In addition, it provides properties to describe the type of the association.

The associationEngine and associationEnginInfo properties are mutually exclusive. One of these properties must be defined.

Parameters:
value - the new value of the 'Association Engine Info' containment reference.
Throws:
java.lang.IllegalStateException - if the 'Association Engine' attribute is currently set.
See Also:
getAssociationEngineInfo()

setAssociationEngineInfo

public void setAssociationEngineInfo(java.lang.String associationEngineName,
                                     java.lang.String associationEngineType,
                                     java.lang.String associationEngineId)

Helper method for creating and setting the association engine information for this object.

It creates an AssociationEngine object and sets it in the respective field of this object.

Parameters:
associationEngineName - name for the association engine.
associationEngineType - type for the association engine.
associationEngineId - identifier for the association engine.

validate

public void validate()
              throws ValidationException

Checks whether the contents of this object conforms to the CBE specification.

Throws:
ValidationException - if the object does not follow the CBE specification.

init

public void init()
Resets the object's properties to their initial (e.g. null) state. All components are initialized to either zero or null.

Since:
1.0