org.cip4.jdflib.node
Class NodeIdentifier

java.lang.Object
  extended by org.cip4.jdflib.node.NodeIdentifier
All Implemented Interfaces:
IMatches, INodeIdentifiable

public final class NodeIdentifier
extends Object
implements IMatches, INodeIdentifiable

class to identify nodes even after parsing, e.g in hashmaps
uses JobID, JobPartID and the partMapVector as identifier


Constructor Summary
NodeIdentifier()
           
NodeIdentifier(INodeIdentifiable ni)
          creates a NodeIdentifier from a given QueueEntry
NodeIdentifier(String jobID, String jobPartID, VJDFAttributeMap partMapVector)
           
 
Method Summary
 boolean equals(Object inObject)
           
 NodeIdentifier getIdentifier()
          formalism so zhat we can use this as a INodeIdentifiable
 String getJobID()
           
 String getJobPartID()
           
 VJDFAttributeMap getPartMapVector()
           
 int hashCode()
           
 boolean matches(Object o)
          return true if the nodeIdentifier matches this, i.e. if all parameters match or o has matching wildcards, or o==null
 void setIdentifier(NodeIdentifier n)
          sets a NodeIdentifier to a given JDF node identifier uses the AncestorPool or NodeInfo or output resource in that sequence to determine the partmap
 void setTo(INodeIdentifiable qe)
          sets a NodeIdentifier to a given JDF node
 void setTo(String jobID, String jobPartID, VJDFAttributeMap partMapVector)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

NodeIdentifier

public NodeIdentifier(String jobID,
                      String jobPartID,
                      VJDFAttributeMap partMapVector)
Parameters:
jobID -
jobPartID -
partMapVector -

NodeIdentifier

public NodeIdentifier()

NodeIdentifier

public NodeIdentifier(INodeIdentifiable ni)
creates a NodeIdentifier from a given QueueEntry

Parameters:
ni - the INodeIdentifiable to set this to
Method Detail

setTo

public void setTo(String jobID,
                  String jobPartID,
                  VJDFAttributeMap partMapVector)
Parameters:
jobID -
jobPartID -
partMapVector -

setIdentifier

public void setIdentifier(NodeIdentifier n)
sets a NodeIdentifier to a given JDF node identifier uses the AncestorPool or NodeInfo or output resource in that sequence to determine the partmap

Specified by:
setIdentifier in interface INodeIdentifiable
Parameters:
n -

setTo

public void setTo(INodeIdentifiable qe)
sets a NodeIdentifier to a given JDF node

Parameters:
qe -

equals

public boolean equals(Object inObject)
Overrides:
equals in class Object
See Also:
Object.equals(java.lang.Object)

matches

public boolean matches(Object o)
return true if the nodeIdentifier matches this, i.e. if all parameters match or o has matching wildcards, or o==null

Specified by:
matches in interface IMatches
Parameters:
o - the nodeidentifier that this should match
if o is a String, check for match with jobID
Returns:
true, if this matches o
See Also:
IMatches

hashCode

public int hashCode()
Overrides:
hashCode in class Object
See Also:
Object.hashCode()

toString

public String toString()
Overrides:
toString in class Object
See Also:
Object.toString()

getJobID

public String getJobID()
Returns:

getJobPartID

public String getJobPartID()
Returns:

getPartMapVector

public VJDFAttributeMap getPartMapVector()
Returns:

getIdentifier

public NodeIdentifier getIdentifier()
formalism so zhat we can use this as a INodeIdentifiable

Specified by:
getIdentifier in interface INodeIdentifiable
Returns:
NodeIdentifier the nodeidentifier that matches this
See Also:
INodeIdentifiable.getIdentifier()


Copyright © 2013. All Rights Reserved.