public class SerializableBatch extends Object implements org.apache.jackrabbit.spi.Batch, Serializable
SerializableBatch implements a serializable SPI Batch, which
simply records all calls and replays them when asked for. The client of
this batch must ensure that the passed QValue instances are
serializable, otherwise the serializing the Batch will fail!| Modifier and Type | Class and Description |
|---|---|
static interface |
SerializableBatch.Operation |
| Constructor and Description |
|---|
SerializableBatch(org.apache.jackrabbit.spi.ItemId itemId)
Creates a new
SerializableBatch. |
| Modifier and Type | Method and Description |
|---|---|
void |
addNode(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.Name nodeName,
org.apache.jackrabbit.spi.Name nodetypeName,
String uuid) |
void |
addProperty(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.Name propertyName,
org.apache.jackrabbit.spi.QValue value) |
void |
addProperty(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.Name propertyName,
org.apache.jackrabbit.spi.QValue[] values) |
org.apache.jackrabbit.spi.ItemId |
getSaveTarget() |
void |
move(org.apache.jackrabbit.spi.NodeId srcNodeId,
org.apache.jackrabbit.spi.NodeId destParentNodeId,
org.apache.jackrabbit.spi.Name destName) |
void |
remove(org.apache.jackrabbit.spi.ItemId itemId) |
void |
reorderNodes(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.NodeId srcNodeId,
org.apache.jackrabbit.spi.NodeId beforeNodeId) |
void |
replay(org.apache.jackrabbit.spi.Batch batch)
Replays this batch on the given
batch. |
void |
setMixins(org.apache.jackrabbit.spi.NodeId nodeId,
org.apache.jackrabbit.spi.Name[] mixinNodeTypeIds) |
void |
setPrimaryType(org.apache.jackrabbit.spi.NodeId nodeId,
org.apache.jackrabbit.spi.Name primaryNodeTypeName) |
void |
setTree(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.Tree contentTree) |
void |
setValue(org.apache.jackrabbit.spi.PropertyId propertyId,
org.apache.jackrabbit.spi.QValue value) |
void |
setValue(org.apache.jackrabbit.spi.PropertyId propertyId,
org.apache.jackrabbit.spi.QValue[] values) |
public SerializableBatch(org.apache.jackrabbit.spi.ItemId itemId)
SerializableBatch.itemId - the id of the item where save was called. To indicate that
save was called on the session, the id of the root node
must be passed.public org.apache.jackrabbit.spi.ItemId getSaveTarget()
public void replay(org.apache.jackrabbit.spi.Batch batch)
throws PathNotFoundException,
ItemNotFoundException,
NoSuchNodeTypeException,
ValueFormatException,
VersionException,
LockException,
ConstraintViolationException,
AccessDeniedException,
UnsupportedRepositoryOperationException,
RepositoryException
batch. For a description of
the exception see RepositoryService.submit(Batch).public void addNode(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.Name nodeName,
org.apache.jackrabbit.spi.Name nodetypeName,
String uuid)
addNode in interface org.apache.jackrabbit.spi.Batchpublic void addProperty(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.Name propertyName,
org.apache.jackrabbit.spi.QValue value)
addProperty in interface org.apache.jackrabbit.spi.Batchpublic void addProperty(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.Name propertyName,
org.apache.jackrabbit.spi.QValue[] values)
addProperty in interface org.apache.jackrabbit.spi.Batchpublic void setValue(org.apache.jackrabbit.spi.PropertyId propertyId,
org.apache.jackrabbit.spi.QValue value)
setValue in interface org.apache.jackrabbit.spi.Batchpublic void setValue(org.apache.jackrabbit.spi.PropertyId propertyId,
org.apache.jackrabbit.spi.QValue[] values)
setValue in interface org.apache.jackrabbit.spi.Batchpublic void remove(org.apache.jackrabbit.spi.ItemId itemId)
remove in interface org.apache.jackrabbit.spi.Batchpublic void reorderNodes(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.NodeId srcNodeId,
org.apache.jackrabbit.spi.NodeId beforeNodeId)
reorderNodes in interface org.apache.jackrabbit.spi.Batchpublic void setMixins(org.apache.jackrabbit.spi.NodeId nodeId,
org.apache.jackrabbit.spi.Name[] mixinNodeTypeIds)
setMixins in interface org.apache.jackrabbit.spi.Batchpublic void setPrimaryType(org.apache.jackrabbit.spi.NodeId nodeId,
org.apache.jackrabbit.spi.Name primaryNodeTypeName)
throws RepositoryException
setPrimaryType in interface org.apache.jackrabbit.spi.BatchRepositoryExceptionpublic void move(org.apache.jackrabbit.spi.NodeId srcNodeId,
org.apache.jackrabbit.spi.NodeId destParentNodeId,
org.apache.jackrabbit.spi.Name destName)
move in interface org.apache.jackrabbit.spi.Batchpublic void setTree(org.apache.jackrabbit.spi.NodeId parentId,
org.apache.jackrabbit.spi.Tree contentTree)
throws RepositoryException
setTree in interface org.apache.jackrabbit.spi.BatchRepositoryExceptionCopyright © 2004–2017 The Apache Software Foundation. All rights reserved.