org.apache.jackrabbit.spi.commons.batch
Class AbstractChangeLog<T extends Operation>
java.lang.Object
org.apache.jackrabbit.spi.commons.batch.AbstractChangeLog<T>
- Type Parameters:
T
-
- All Implemented Interfaces:
- Batch, ChangeLog
- Direct Known Subclasses:
- ChangeLogImpl, ConsolidatingChangeLog
public abstract class AbstractChangeLog<T extends Operation>
- extends Object
- implements ChangeLog
This base class for ChangeLog
implementations maintains a list of operations
of type type T
.
operations
protected final List<T extends Operation> operations
Operation
s kept in this change log.
AbstractChangeLog
public AbstractChangeLog()
addOperation
public void addOperation(T op)
throws RepositoryException
- Added an operation to the list of
operations
.
- Parameters:
op
- Operation
to add
- Throws:
RepositoryException
apply
public Batch apply(Batch batch)
throws RepositoryException
- This implementation applies each of the operation maintained by
this change log to the passed
batch
.
Applies the Operation
s contained in this change log to
the passed batch
.
- Specified by:
apply
in interface ChangeLog
- Returns:
- The
batch
passed in as argument with the
operations from this change log applied.
- Throws:
RepositoryException
toString
public String toString()
- Overrides:
toString
in class Object
equals
public boolean equals(Object other)
- Overrides:
equals
in class Object
equals
public boolean equals(AbstractChangeLog<?> other)
hashCode
public int hashCode()
- Overrides:
hashCode
in class Object
Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.