org.jboss.dna.graph.requests
Class DeleteBranchRequest

java.lang.Object
  extended by org.jboss.dna.graph.requests.Request
      extended by org.jboss.dna.graph.requests.DeleteBranchRequest
All Implemented Interfaces:
Serializable

public class DeleteBranchRequest
extends Request

Instruction that a branch be deleted.

Author:
Randall Hauch
See Also:
Serialized Form

Constructor Summary
DeleteBranchRequest(Location at)
          Create a request to delete a branch.
 
Method Summary
 Location at()
          Get the location defining the top of the branch to be deleted
 boolean equals(Object obj)
          
 Location getActualLocationOfNode()
          Get the actual location of the node that was deleted.
 boolean isReadOnly()
          Return whether this request only reads information.
 void setActualLocationOfNode(Location actual)
          Sets the actual and complete location of the node being deleted.
 String toString()
          
 
Methods inherited from class org.jboss.dna.graph.requests.Request
cancel, getError, hasError, isCancelled, setError
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DeleteBranchRequest

public DeleteBranchRequest(Location at)
Create a request to delete a branch.

Parameters:
at - the location of the top node in the existing branch that is to be deleted
Throws:
IllegalArgumentException - if the location is null
Method Detail

at

public Location at()
Get the location defining the top of the branch to be deleted

Returns:
the location of the branch; never null

isReadOnly

public boolean isReadOnly()
Return whether this request only reads information.

Specified by:
isReadOnly in class Request
Returns:
true if this request reads information, or false if it requests that the repository content be changed in some way
See Also:
Request.isReadOnly()

setActualLocationOfNode

public void setActualLocationOfNode(Location actual)
Sets the actual and complete location of the node being deleted. This method must be called when processing the request, and the actual location must have a path.

Parameters:
actual - the actual location of the node being deleted, or null if the current location should be used
Throws:
IllegalArgumentException - if the actual location does not represent the same location as the current location, or if the actual location does not have a path.

getActualLocationOfNode

public Location getActualLocationOfNode()
Get the actual location of the node that was deleted.

Returns:
the actual location, or null if the actual location was not set

equals

public boolean equals(Object obj)

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

toString

public String toString()

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


Copyright © 2008-Present JBoss a division of Red Hat. All Rights Reserved.