org.apache.jackrabbit.jcr2spi.operation
Interface Operation

All Known Implementing Classes:
AbstractCopy, AbstractOperation, AddLabel, AddNode, AddProperty, Checkin, Checkout, Checkpoint, Clone, Copy, CreateActivity, CreateConfiguration, LockOperation, LockRefresh, LockRelease, Merge, Move, Remove, RemoveActivity, RemoveLabel, RemoveVersion, ReorderNodes, ResolveMergeConflict, Restore, SetMixin, SetPrimaryType, SetPropertyValue, Update, WorkspaceImport

public interface Operation

Operation...


Field Summary
static int STATUS_PENDING
           
static int STATUS_PERSISTED
           
static int STATUS_UNDO
           
 
Method Summary
 void accept(OperationVisitor visitor)
          Calls the appropriate visit method on visitor based on the type of this operation.
 Collection<ItemState> getAffectedItemStates()
          A collection of ItemStates that are affected by this operation.
 String getName()
          Returns the name of this operation.
 int getStatus()
          Returns the status of this operation.
 void persisted()
          Informs this Operation that it has been successfully executed.
 void undo()
          Revert changes made by this operation.
 

Field Detail

STATUS_PENDING

static final int STATUS_PENDING
See Also:
Constant Field Values

STATUS_PERSISTED

static final int STATUS_PERSISTED
See Also:
Constant Field Values

STATUS_UNDO

static final int STATUS_UNDO
See Also:
Constant Field Values
Method Detail

getName

String getName()
Returns the name of this operation.

Returns:
the name of this operation.

accept

void accept(OperationVisitor visitor)
            throws RepositoryException,
                   ConstraintViolationException,
                   AccessDeniedException,
                   ItemExistsException,
                   NoSuchNodeTypeException,
                   UnsupportedRepositoryOperationException,
                   VersionException
Calls the appropriate visit method on visitor based on the type of this operation.

Parameters:
visitor - the visitor to call back.
Throws:
RepositoryException
ConstraintViolationException
AccessDeniedException
ItemExistsException
NoSuchNodeTypeException
UnsupportedRepositoryOperationException
VersionException

getAffectedItemStates

Collection<ItemState> getAffectedItemStates()
A collection of ItemStates that are affected by this operation.

Returns:
collection of affected ItemStates.

persisted

void persisted()
               throws RepositoryException
Informs this Operation that it has been successfully executed.

Throws:
RepositoryException

undo

void undo()
          throws RepositoryException
Revert changes made by this operation.

Throws:
RepositoryException

getStatus

int getStatus()
Returns the status of this operation.

Returns:
status of this operation.


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.