com.cisco.provisioning.cpe.api.search
Class NodeSearchType

java.lang.Object
  extended by com.cisco.provisioning.cpe.api.search.NodeSearchType
All Implemented Interfaces:
Serializable

public final class NodeSearchType
extends Object
implements Serializable

Node search criteria for a NodeSearchFilter.

See Also:
Serialized Form

Field Summary
static int BY_NODE
          Specifies search by node
static int BY_NODE_TYPE
          Specifies search by node type
static int BY_RELATED_NODES
          Specifies search for related nodes
 
Method Summary
 boolean equals(Object obj)
          Determines if this object is equal to the specified object.
static NodeSearchType getByNodeType(NodeType nodeType)
          Create a NodeSearchType to search for nodes of a specific type.
static NodeSearchType getByRelatedNode(NodeName nodeName)
          Create a NodeSearchType to search for nodes of a specific node name.
 NodeName getNodeName()
          Returns the NodeName defined for this search type.
static NodeSearchType getNodes(NodeNamePattern pattern)
          Create a NodeSearchType to search for nodes whose name matches a specific node name pattern.
 NodeType getNodeType()
          Returns the NodeType defined for this search type.
 NodeNamePattern getPattern()
          Returns the NodeNamePattern defined for this search type.
 int getType()
          Returns the constant describing the node search type.
 int hashCode()
          The hash code of this object.
 String toString()
          Returns a String description of this search type.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

BY_RELATED_NODES

public static final int BY_RELATED_NODES
Specifies search for related nodes

See Also:
Constant Field Values

BY_NODE_TYPE

public static final int BY_NODE_TYPE
Specifies search by node type

See Also:
Constant Field Values

BY_NODE

public static final int BY_NODE
Specifies search by node

See Also:
Constant Field Values
Method Detail

getType

public int getType()
Returns the constant describing the node search type.

Returns:
the node search type constant.

getNodeType

public NodeType getNodeType()
Returns the NodeType defined for this search type.

Returns:
the NodeType defined for this search type.

getNodeName

public NodeName getNodeName()
Returns the NodeName defined for this search type.

Returns:
the NodeName defined for this search type.

getPattern

public NodeNamePattern getPattern()
Returns the NodeNamePattern defined for this search type.

Returns:
the NodeNamePatttern defined for this search type.

getByNodeType

public static NodeSearchType getByNodeType(NodeType nodeType)
Create a NodeSearchType to search for nodes of a specific type.

Parameters:
nodeType - all nodes of this type will be examined. This value cannot be set to null. If it is specified as null the runtime exception APIArgumentException will be thrown.

getByRelatedNode

public static NodeSearchType getByRelatedNode(NodeName nodeName)
Create a NodeSearchType to search for nodes of a specific node name.

Parameters:
nodeName - all related nodes will be returned. This value cannot be set to null. If it is specified as null the runtime exception APIArgumentException will be thrown.

getNodes

public static NodeSearchType getNodes(NodeNamePattern pattern)
Create a NodeSearchType to search for nodes whose name matches a specific node name pattern.

Parameters:
pattern - node names will be matched against this pattern. This value cannot be set to null. If it is specified as null or the pattern is invalid the runtime exception APIArgumentException will be thrown.

toString

public String toString()
Returns a String description of this search type.

Overrides:
toString in class Object
Returns:
a String description of this search type.

hashCode

public int hashCode()
The hash code of this object. See Object.hashCode() for more information.

Overrides:
hashCode in class Object
Returns:
The hashode of this object.

equals

public boolean equals(Object obj)
Determines if this object is equal to the specified object.

Overrides:
equals in class Object
Returns:
True if the specified object is equal to this object. False if the objects are not equal.