it.eng.spago.cms.operations
Class DeleteOperation

java.lang.Object
  extended by it.eng.spago.cms.operations.DeleteOperation

public class DeleteOperation
extends java.lang.Object

Models a repository delete operation. The operation has two attributes:

To delete an entire node it's necessary to set only the path attribute. To delete only a version of a node it's necessary to set the path and the version name of the node. The configuration of the operation is stored into a Spago SourceBean structured like below:
 <OPERATION name="">
                <DELETEOPERATION path="?" version="?" />
 </OPERATION>
 


Constructor Summary
DeleteOperation()
          Constructor of the class useful to build an empty delete operation.
DeleteOperation(java.lang.String path)
          Constructor of the class useful to build a delete operation setting the path attribute.
DeleteOperation(java.lang.String path, java.lang.String version)
          Constructor of the class useful to build a delete operation setting the path and version attributes.
 
Method Summary
 SourceBean getOperationDescriptor()
          Gets the Internal SourceBean which defines the internal structure of the operation
 void setPath(java.lang.String path)
          Set the path of the cms node
 void setVersion(java.lang.String version)
          Set the version of the cms node
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DeleteOperation

public DeleteOperation()
                throws BuildOperationException
Constructor of the class useful to build an empty delete operation.

Throws:
BuildOperationException - Thrown if an error occurs during the creation

DeleteOperation

public DeleteOperation(java.lang.String path)
                throws BuildOperationException
Constructor of the class useful to build a delete operation setting the path attribute.

Parameters:
path - The Path of the cms node to delete
Throws:
BuildOperationException - Thrown if an error occurs during the creation

DeleteOperation

public DeleteOperation(java.lang.String path,
                       java.lang.String version)
                throws BuildOperationException
Constructor of the class useful to build a delete operation setting the path and version attributes.

Parameters:
path - The Path of the cms node
version - The name of the node version to delete
Throws:
BuildOperationException - Thrown if an error occurs during the creation
Method Detail

getOperationDescriptor

public SourceBean getOperationDescriptor()
Gets the Internal SourceBean which defines the internal structure of the operation

Returns:
The Internal SourceBean of the operation which defines the internal structure of the operation

setPath

public void setPath(java.lang.String path)
             throws BuildOperationException
Set the path of the cms node

Parameters:
path - Path of the cms node
Throws:
BuildOperationException - Thrown if an error occurs during the setting

setVersion

public void setVersion(java.lang.String version)
                throws BuildOperationException
Set the version of the cms node

Parameters:
version - Version of the cms node
Throws:
BuildOperationException - Thrown if an error occurs during the setting