org.ow2.bonita.pvm.internal.model
Class ObservableElementImpl

java.lang.Object
  extended by org.ow2.bonita.pvm.internal.model.ProcessElementImpl
      extended by org.ow2.bonita.pvm.internal.model.ObservableElementImpl
All Implemented Interfaces:
java.io.Serializable, ObservableElement
Direct Known Subclasses:
CompositeElementImpl, TransitionImpl

public class ObservableElementImpl
extends ProcessElementImpl
implements ObservableElement

observable and visible process elements.

Author:
Tom Baeyens
See Also:
Serialized Form

Field Summary
protected  java.lang.String description
           
protected  java.util.Map<java.lang.String,EventImpl> events
           
protected  java.lang.String name
           
 
Fields inherited from class org.ow2.bonita.pvm.internal.model.ProcessElementImpl
dbid, dbversion, exceptionHandlers, processDefinition, properties
 
Constructor Summary
ObservableElementImpl()
           
 
Method Summary
 EventImpl addEvent(EventImpl event)
          add an event to this processDefinition element.
 EventImpl createEvent(java.lang.String eventName)
          event factory method that also establishes the bidirectional relation.
 java.lang.String getDescription()
           
 EventImpl getEvent(java.lang.String eventName)
           
 java.util.Map<java.lang.String,Event> getEvents()
           
 java.lang.String getName()
          the short display name given to this element.
 ObservableElementImpl getParent()
          the enclosing node or the process definition
 boolean hasEvent(java.lang.String eventName)
          indicates if the given event is defined no this element.
 void setDescription(java.lang.String description)
           
 void setEvents(java.util.Map<java.lang.String,EventImpl> events)
           
 void setName(java.lang.String name)
           
 
Methods inherited from class org.ow2.bonita.pvm.internal.model.ProcessElementImpl
addExceptionHandler, addProperty, createExceptionHandler, getDbid, getExceptionHandlers, getProcessDefinition, getProperties, getProperty, getPropertyKeys, setExceptionHandlers, setProcessDefinition, setProperties
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.ow2.bonita.pvm.model.ObservableElement
getDbid, getProcessDefinition, getProperty, getPropertyKeys
 

Field Detail

name

protected java.lang.String name

description

protected java.lang.String description

events

protected java.util.Map<java.lang.String,EventImpl> events
Constructor Detail

ObservableElementImpl

public ObservableElementImpl()
Method Detail

getParent

public ObservableElementImpl getParent()
Description copied from interface: ObservableElement
the enclosing node or the process definition

Specified by:
getParent in interface ObservableElement

getEvent

public EventImpl getEvent(java.lang.String eventName)

hasEvent

public boolean hasEvent(java.lang.String eventName)
Description copied from interface: ObservableElement
indicates if the given event is defined no this element. This method only looks in this observable element and it will not search the parent hierarchy for the given event.

Specified by:
hasEvent in interface ObservableElement

createEvent

public EventImpl createEvent(java.lang.String eventName)
event factory method that also establishes the bidirectional relation.


addEvent

public EventImpl addEvent(EventImpl event)
add an event to this processDefinition element.

Throws:
java.lang.NullPointerException - if event is null.

getName

public java.lang.String getName()
Description copied from interface: ObservableElement
the short display name given to this element.

Specified by:
getName in interface ObservableElement

setName

public void setName(java.lang.String name)

getDescription

public java.lang.String getDescription()

setDescription

public void setDescription(java.lang.String description)

getEvents

public java.util.Map<java.lang.String,Event> getEvents()

setEvents

public void setEvents(java.util.Map<java.lang.String,EventImpl> events)


Copyright © 2009 OW2 Consortium. All Rights Reserved.