com.dtolabs.rundeck.core.common
Class NodeSetImpl

java.lang.Object
  extended by com.dtolabs.rundeck.core.common.NodeSetImpl
All Implemented Interfaces:
INodeSet, NodeReceiver, java.lang.Iterable<INodeEntry>

public class NodeSetImpl
extends java.lang.Object
implements INodeSet, NodeReceiver

Basic Implementation of INodeSet


Constructor Summary
NodeSetImpl()
           
NodeSetImpl(java.util.HashMap<java.lang.String,INodeEntry> nodes)
           
 
Method Summary
 INodeEntry getNode(java.lang.String name)
           
 java.util.Collection<java.lang.String> getNodeNames()
           
 java.util.Collection<INodeEntry> getNodes()
           
 java.util.Iterator<INodeEntry> iterator()
           
 void putNode(INodeEntry node)
          Put a filled node entry into the dataset
 void putNodes(java.util.Collection<INodeEntry> set)
          Add all nodes from a collection to this node set
 void putNodes(INodeSet set)
          Add all nodes from a node set to this node set
static NodeSetImpl singleNodeSet(INodeEntry node)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

NodeSetImpl

public NodeSetImpl()

NodeSetImpl

public NodeSetImpl(java.util.HashMap<java.lang.String,INodeEntry> nodes)
Method Detail

singleNodeSet

public static NodeSetImpl singleNodeSet(INodeEntry node)

putNode

public void putNode(INodeEntry node)
Description copied from interface: NodeReceiver
Put a filled node entry into the dataset

Specified by:
putNode in interface NodeReceiver

getNodes

public java.util.Collection<INodeEntry> getNodes()
Specified by:
getNodes in interface INodeSet

getNode

public INodeEntry getNode(java.lang.String name)
Specified by:
getNode in interface INodeSet

getNodeNames

public java.util.Collection<java.lang.String> getNodeNames()
Specified by:
getNodeNames in interface INodeSet

putNodes

public void putNodes(INodeSet set)
Add all nodes from a node set to this node set


putNodes

public void putNodes(java.util.Collection<INodeEntry> set)
Add all nodes from a collection to this node set


toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

iterator

public java.util.Iterator<INodeEntry> iterator()
Specified by:
iterator in interface java.lang.Iterable<INodeEntry>