org.mockcentral.editor.nodes.actions
Class NodeCopier

java.lang.Object
  extended by org.mockcentral.editor.nodes.actions.NodeCopier
All Implemented Interfaces:
INodeCopier

public class NodeCopier
extends java.lang.Object
implements INodeCopier

Utility class for creating copies of MockCentralNode instances for pasting within configuration files.


Constructor Summary
NodeCopier()
           
 
Method Summary
 org.mockcentral.editor.nodes.MockCentralNode createExpectationCopy()
          Returns a new copy of the current ExpectationNode.
 org.mockcentral.editor.nodes.MockCentralNode createFixtureCopy()
          Returns a new copy of the current FixtureNode, opening a wizard to get user input for the fixture data.
 org.mockcentral.editor.nodes.MockCentralNode createMockObjectCopy()
          Returns a new copy of the current MockObjectNode, opening a wizard to get user input for the mock object data.
 void init(org.mockcentral.editor.viewers.IMockCentralNodeGroupViewer viewer, org.mockcentral.editor.nodes.MockCentralNode nodeCopy, org.mockcentral.editor.nodes.MockCentralNode parentNode)
          Initializes data for this class prior to creating a MockCentralNode copy.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NodeCopier

public NodeCopier()
Method Detail

init

public void init(org.mockcentral.editor.viewers.IMockCentralNodeGroupViewer viewer,
                 org.mockcentral.editor.nodes.MockCentralNode nodeCopy,
                 org.mockcentral.editor.nodes.MockCentralNode parentNode)
Description copied from interface: INodeCopier
Initializes data for this class prior to creating a MockCentralNode copy.

Specified by:
init in interface INodeCopier
Parameters:
viewer - the IMockCentralNodeGroupViewer from which the paste action originated.
nodeCopy - the MockCentralNode to be pasted.
parentNode - the enclosing group node.

createFixtureCopy

public org.mockcentral.editor.nodes.MockCentralNode createFixtureCopy()
Description copied from interface: INodeCopier
Returns a new copy of the current FixtureNode, opening a wizard to get user input for the fixture data.

Specified by:
createFixtureCopy in interface INodeCopier
Returns:
a new copy of the current FixtureNode.

createMockObjectCopy

public org.mockcentral.editor.nodes.MockCentralNode createMockObjectCopy()
Description copied from interface: INodeCopier
Returns a new copy of the current MockObjectNode, opening a wizard to get user input for the mock object data.

Specified by:
createMockObjectCopy in interface INodeCopier
Returns:
a new copy of the current MockObjectNode.

createExpectationCopy

public org.mockcentral.editor.nodes.MockCentralNode createExpectationCopy()
Description copied from interface: INodeCopier
Returns a new copy of the current ExpectationNode.

Specified by:
createExpectationCopy in interface INodeCopier
Returns:
a new copy of the current ExpectationNode.