Class NodeTypeRecord
- java.lang.Object
-
- org.apache.jackrabbit.core.cluster.ClusterRecord
-
- org.apache.jackrabbit.core.cluster.NodeTypeRecord
-
public class NodeTypeRecord extends ClusterRecord
Cluster record representing a node type registration, re-registration or unregistration.
-
-
Field Summary
Fields Modifier and Type Field Description static intREGISTEROperation type: registration.static intREREGISTEROperation type: re-registration.static intUNREGISTEROperation type: unregistration.-
Fields inherited from class org.apache.jackrabbit.core.cluster.ClusterRecord
END_MARKER, record, workspace
-
-
Constructor Summary
Constructors Constructor Description NodeTypeRecord(Collection collection, boolean isRegister, Record record)Create a new instance of this class.NodeTypeRecord(QNodeTypeDefinition ntDef, Record record)Create a new instance of this class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddoRead()Deserialize this record.protected voiddoWrite()Serialize this record.CollectiongetCollection()Return the collection of node type definitions or node type names.intgetOperation()Return the operation type.voidprocess(ClusterRecordProcessor processor)Process this record, calling the appropriateprocessmethod.-
Methods inherited from class org.apache.jackrabbit.core.cluster.ClusterRecord
cancelUpdate, getRevision, getWorkspace, read, readEndMarker, update, write
-
-
-
-
Field Detail
-
REGISTER
public static final int REGISTER
Operation type: registration.- See Also:
- Constant Field Values
-
REREGISTER
public static final int REREGISTER
Operation type: re-registration.- See Also:
- Constant Field Values
-
UNREGISTER
public static final int UNREGISTER
Operation type: unregistration.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
NodeTypeRecord
public NodeTypeRecord(Collection collection, boolean isRegister, Record record)
Create a new instance of this class. Used when serializing a node type registration or unregistration.- Parameters:
collection- collection of node types definitions or node type namesisRegister-trueif this is a registration;falseif this is a unregistrationrecord- journal record
-
NodeTypeRecord
public NodeTypeRecord(QNodeTypeDefinition ntDef, Record record)
Create a new instance of this class. Used when serializing a node type re-registration.- Parameters:
ntDef- node type definitionrecord- journal record
-
-
Method Detail
-
doRead
protected void doRead() throws JournalExceptionDeserialize this record. Subclass responsibility.- Specified by:
doReadin classClusterRecord- Throws:
JournalException- if an error occurs
-
doWrite
protected void doWrite() throws JournalExceptionSerialize this record. Subclass responsibility.- Specified by:
doWritein classClusterRecord- Throws:
JournalException- if an error occurs
-
process
public void process(ClusterRecordProcessor processor)
Process this record, calling the appropriateprocessmethod.- Specified by:
processin classClusterRecord- Parameters:
processor- processor
-
getOperation
public int getOperation()
Return the operation type.- Returns:
REGISTER,REREGISTERorUNREGISTER
-
getCollection
public Collection getCollection()
Return the collection of node type definitions or node type names.- Returns:
- unmodifiable collection
-
-