org.yawlfoundation.yawl.elements.state
Class YIdentifier

java.lang.Object
  extended by org.yawlfoundation.yawl.elements.state.YIdentifier

public class YIdentifier
extends Object

This class has control over data structures that allow for storing an identifer and managing a set of children.

Author:
Lachlan Aldred, Michael Adams (refactored for v2.0, 06/08 & 04/09)

Constructor Summary
YIdentifier()
           
YIdentifier(String idString)
           
 
Method Summary
 void addLocation(YPersistenceManager pmgr, YNetElement condition)
           
 void addLocation(YPersistenceManager pmgr, YTask task)
           
 void clearChildren()
           
 void clearLocation(YPersistenceManager pmgr, YNetElement condition)
           
 void clearLocations(YPersistenceManager pmgr)
           
 YIdentifier createChild(YPersistenceManager pmgr)
           
 YIdentifier createChild(YPersistenceManager pmgr, int childNum)
          Creates a child identifier.
 boolean equals(Object other)
           
 boolean equalsOrIsAncestorOf(YIdentifier another)
           
 List<YIdentifier> get_children()
           
 String get_idString()
           
 YIdentifier get_parent()
           
 List<YIdentifier> getChildren()
           
 Set<YIdentifier> getDescendants()
           
 String getId()
           
 List<String> getLocationNames()
           
 List<YNetElement> getLocations()
           
 long getLogKey()
           
 YIdentifier getParent()
           
 YIdentifier getRootAncestor()
           
 int hashCode()
          Returns a hash code value for the object.
 boolean hasParent()
           
 boolean isAncestorOf(YIdentifier identifier)
           
 boolean isImmediateChildOf(YIdentifier identifier)
           
 boolean removeChild(YIdentifier child)
           
 void removeLocation(YPersistenceManager pmgr, YNetElement condition)
           
 void removeLocation(YPersistenceManager pmgr, YTask task)
           
 void set_children(List<YIdentifier> children)
           
 void set_idString(String id)
           
 void set_parent(YIdentifier parent)
           
 void setId(String id)
           
 void setLocationNames(List<String> names)
           
 void setLogKey(long key)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

YIdentifier

public YIdentifier()

YIdentifier

public YIdentifier(String idString)
Method Detail

getId

public String getId()

setId

public void setId(String id)

getLocationNames

public List<String> getLocationNames()

setLocationNames

public void setLocationNames(List<String> names)

get_idString

public String get_idString()

set_idString

public void set_idString(String id)

set_children

public void set_children(List<YIdentifier> children)

get_children

public List<YIdentifier> get_children()

get_parent

public YIdentifier get_parent()

set_parent

public void set_parent(YIdentifier parent)

getChildren

public List<YIdentifier> getChildren()

getDescendants

public Set<YIdentifier> getDescendants()

createChild

public YIdentifier createChild(YPersistenceManager pmgr)
                        throws YPersistenceException
Throws:
YPersistenceException

clearChildren

public void clearChildren()

removeChild

public boolean removeChild(YIdentifier child)

createChild

public YIdentifier createChild(YPersistenceManager pmgr,
                               int childNum)
                        throws YPersistenceException
Creates a child identifier.

Parameters:
childNum -
Returns:
the child YIdentifier object with id == childNum
Throws:
YPersistenceException

getParent

public YIdentifier getParent()

hasParent

public boolean hasParent()

isImmediateChildOf

public boolean isImmediateChildOf(YIdentifier identifier)

isAncestorOf

public boolean isAncestorOf(YIdentifier identifier)

toString

public String toString()
Overrides:
toString in class Object

addLocation

public void addLocation(YPersistenceManager pmgr,
                        YNetElement condition)
                 throws YPersistenceException
Throws:
YPersistenceException

clearLocations

public void clearLocations(YPersistenceManager pmgr)
                    throws YPersistenceException
Throws:
YPersistenceException

clearLocation

public void clearLocation(YPersistenceManager pmgr,
                          YNetElement condition)
                   throws YPersistenceException
Throws:
YPersistenceException

removeLocation

public void removeLocation(YPersistenceManager pmgr,
                           YNetElement condition)
                    throws YPersistenceException
Throws:
YPersistenceException

addLocation

public void addLocation(YPersistenceManager pmgr,
                        YTask task)
                 throws YPersistenceException
Throws:
YPersistenceException

removeLocation

public void removeLocation(YPersistenceManager pmgr,
                           YTask task)
                    throws YPersistenceException
Throws:
YPersistenceException

getLocations

public List<YNetElement> getLocations()

getRootAncestor

public YIdentifier getRootAncestor()

getLogKey

public long getLogKey()

setLogKey

public void setLogKey(long key)

equals

public boolean equals(Object other)
Overrides:
equals in class Object

equalsOrIsAncestorOf

public boolean equalsOrIsAncestorOf(YIdentifier another)

hashCode

public int hashCode()
Returns a hash code value for the object.

Overrides:
hashCode in class Object
Returns:
a hash code value for this object.
See Also:
Object.equals(Object), Hashtable


Copyright © 2004-2012 The YAWL Foundation.