Package javax.jcr.version
Class OnParentVersionAction
- java.lang.Object
-
- javax.jcr.version.OnParentVersionAction
-
public final class OnParentVersionAction extends java.lang.ObjectThe possible actions specified by theonParentVersionattribute in a property definition within a node type definition.This interface defines the following actions:
COPYVERSIONINITIALIZECOMPUTEIGNOREABORT
Every item (node or property) in the repository has a status indicator that governs what happens to that item when its parent node is versioned. This status is defined by the
onParentVersionattribute in thePropertyDefinitionorNodeDefinitionthat applies to the item in question.
-
-
Field Summary
Fields Modifier and Type Field Description static intABORTstatic java.lang.StringACTIONNAME_ABORTstatic java.lang.StringACTIONNAME_COMPUTEstatic java.lang.StringACTIONNAME_COPYThe names of the defined on-version actions, as used in serialization.static java.lang.StringACTIONNAME_IGNOREstatic java.lang.StringACTIONNAME_INITIALIZEstatic java.lang.StringACTIONNAME_VERSIONstatic intCOMPUTEstatic intCOPYThe action constants.static intIGNOREstatic intINITIALIZEstatic intVERSION
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.StringnameFromValue(int action)Returns the name of the specifiedaction, as used in serialization.static intvalueFromName(java.lang.String name)Returns the numeric constant value of the on-version action with the specified name.
-
-
-
Field Detail
-
COPY
public static final int COPY
The action constants.- See Also:
- Constant Field Values
-
VERSION
public static final int VERSION
- See Also:
- Constant Field Values
-
INITIALIZE
public static final int INITIALIZE
- See Also:
- Constant Field Values
-
COMPUTE
public static final int COMPUTE
- See Also:
- Constant Field Values
-
IGNORE
public static final int IGNORE
- See Also:
- Constant Field Values
-
ABORT
public static final int ABORT
- See Also:
- Constant Field Values
-
ACTIONNAME_COPY
public static final java.lang.String ACTIONNAME_COPY
The names of the defined on-version actions, as used in serialization.- See Also:
- Constant Field Values
-
ACTIONNAME_VERSION
public static final java.lang.String ACTIONNAME_VERSION
- See Also:
- Constant Field Values
-
ACTIONNAME_INITIALIZE
public static final java.lang.String ACTIONNAME_INITIALIZE
- See Also:
- Constant Field Values
-
ACTIONNAME_COMPUTE
public static final java.lang.String ACTIONNAME_COMPUTE
- See Also:
- Constant Field Values
-
ACTIONNAME_IGNORE
public static final java.lang.String ACTIONNAME_IGNORE
- See Also:
- Constant Field Values
-
ACTIONNAME_ABORT
public static final java.lang.String ACTIONNAME_ABORT
- See Also:
- Constant Field Values
-
-
Method Detail
-
nameFromValue
public static java.lang.String nameFromValue(int action)
Returns the name of the specifiedaction, as used in serialization.- Parameters:
action- the on-version action- Returns:
- the name of the specified
action - Throws:
java.lang.IllegalArgumentException- ifactionis not a valid on-version action.
-
valueFromName
public static int valueFromName(java.lang.String name)
Returns the numeric constant value of the on-version action with the specified name.- Parameters:
name- the name of the on-version action- Returns:
- the numeric constant value
- Throws:
java.lang.IllegalArgumentException- ifnameis not a valid on-version action name.
-
-