Class AbstractRecord
- java.lang.Object
-
- org.apache.jackrabbit.core.journal.AbstractRecord
-
- All Implemented Interfaces:
Record
- Direct Known Subclasses:
AppendRecord,ReadRecord
public abstract class AbstractRecord extends Object implements Record
Base implementation for a record.
-
-
Field Summary
Fields Modifier and Type Field Description protected NamespaceResolvernsResolverNamespace resolver.protected NamePathResolverresolverName and Path resolver.
-
Constructor Summary
Constructors Constructor Description AbstractRecord(NamespaceResolver nsResolver, NamePathResolver resolver)Create a new instance of this class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NodeIdreadNodeId()Read aNodeIdfrom the underlying stream.QNodeTypeDefinitionreadNodeTypeDef()Read aNodeTypeDeffrom the underlying stream.PathreadPath()Read aPathfrom the underlying stream.PathreadPathElement()Read a named path element from the underlying stream.PrivilegeDefinitionreadPrivilegeDef()Read aPrivilegeDefinitionfrom the underlying stream.PropertyIdreadPropertyId()Read aPropertyIdfrom the underlying stream.NamereadQName()Read aNamefrmo the underlying stream.voidwriteNodeId(NodeId nodeId)Write aNodeIdto the underlying stream.voidwriteNodeTypeDef(QNodeTypeDefinition ntd)Write aNodeTypeDefto the underlying stream.voidwritePath(Path path)Write aPathto the underlying stream.voidwritePathElement(Path path)Write aPath.Elementto the underlying stream.voidwritePrivilegeDef(PrivilegeDefinition privilegeDefinition)Write aPrivilegeDefinitionto the underlying stream.voidwritePropertyId(PropertyId propertyId)Write aPropertyIdto the underlying stream.voidwriteQName(Name name)Write aNameto the underlying stream.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.jackrabbit.core.journal.Record
cancelUpdate, getJournalId, getProducerId, getRevision, readBoolean, readByte, readChar, readFully, readInt, readLong, readString, update, write, writeBoolean, writeByte, writeChar, writeInt, writeLong, writeString
-
-
-
-
Field Detail
-
nsResolver
protected final NamespaceResolver nsResolver
Namespace resolver.
-
resolver
protected final NamePathResolver resolver
Name and Path resolver.
-
-
Constructor Detail
-
AbstractRecord
public AbstractRecord(NamespaceResolver nsResolver, NamePathResolver resolver)
Create a new instance of this class.- Parameters:
nsResolver- the namespace resolverresolver- the name-path resolver
-
-
Method Detail
-
writeQName
public void writeQName(Name name) throws JournalException
Write aNameto the underlying stream.- Specified by:
writeQNamein interfaceRecord- Parameters:
name- name- Throws:
JournalException- if an error occurs
-
writePathElement
public void writePathElement(Path path) throws JournalException
Write aPath.Elementto the underlying stream.- Specified by:
writePathElementin interfaceRecord- Parameters:
path- path element- Throws:
JournalException- if an error occurs
-
writePath
public void writePath(Path path) throws JournalException
Write aPathto the underlying stream.- Specified by:
writePathin interfaceRecord- Parameters:
path- path- Throws:
JournalException- if an error occurs
-
writeNodeId
public void writeNodeId(NodeId nodeId) throws JournalException
Write aNodeIdto the underlying stream.- Specified by:
writeNodeIdin interfaceRecord- Parameters:
nodeId- node id- Throws:
JournalException- if an error occurs
-
writePropertyId
public void writePropertyId(PropertyId propertyId) throws JournalException
Write aPropertyIdto the underlying stream.- Specified by:
writePropertyIdin interfaceRecord- Parameters:
propertyId- property id- Throws:
JournalException- if an error occurs
-
writeNodeTypeDef
public void writeNodeTypeDef(QNodeTypeDefinition ntd) throws JournalException
Write aNodeTypeDefto the underlying stream.- Specified by:
writeNodeTypeDefin interfaceRecord- Parameters:
ntd- node type definition- Throws:
JournalException- if an error occurs
-
writePrivilegeDef
public void writePrivilegeDef(PrivilegeDefinition privilegeDefinition) throws JournalException
Write aPrivilegeDefinitionto the underlying stream.- Specified by:
writePrivilegeDefin interfaceRecord- Parameters:
privilegeDefinition- privilege definition- Throws:
JournalException- if an error occurs
-
readQName
public Name readQName() throws JournalException
Read aNamefrmo the underlying stream.- Specified by:
readQNamein interfaceRecord- Returns:
- name name
- Throws:
JournalException- if an error occurs
-
readPathElement
public Path readPathElement() throws JournalException
Read a named path element from the underlying stream.- Specified by:
readPathElementin interfaceRecord- Returns:
- path element
- Throws:
JournalException- if an error occurs
-
readPath
public Path readPath() throws JournalException
Read aPathfrom the underlying stream.- Specified by:
readPathin interfaceRecord- Returns:
- path
- Throws:
JournalException- if an error occurs
-
readNodeId
public NodeId readNodeId() throws JournalException
Read aNodeIdfrom the underlying stream.- Specified by:
readNodeIdin interfaceRecord- Returns:
- node id
- Throws:
JournalException- if an error occurs
-
readPropertyId
public PropertyId readPropertyId() throws JournalException
Read aPropertyIdfrom the underlying stream.- Specified by:
readPropertyIdin interfaceRecord- Returns:
- property id
- Throws:
JournalException- if an error occurs
-
readNodeTypeDef
public QNodeTypeDefinition readNodeTypeDef() throws JournalException
Read aNodeTypeDeffrom the underlying stream.- Specified by:
readNodeTypeDefin interfaceRecord- Returns:
- node type definition
- Throws:
JournalException- if an error occurs
-
readPrivilegeDef
public PrivilegeDefinition readPrivilegeDef() throws JournalException
Read aPrivilegeDefinitionfrom the underlying stream.- Specified by:
readPrivilegeDefin interfaceRecord- Returns:
- privilege definition
- Throws:
JournalException- if an error occurs
-
-