Package | Description |
---|---|
javax.jcr |
Provides interfaces and classes for the Content Repository for Java Technology.
|
javax.jcr.lock |
Provides interfaces and classes for content repository locking functionality.
|
javax.jcr.nodetype |
Provides interfaces and classes for content repository node type functionality.
|
javax.jcr.observation |
Provides interfaces and classes for content repository event observation functionality.
|
javax.jcr.query |
Provides interfaces and classes for content repository searching functionality.
|
javax.jcr.util |
Provides utility classes for the content repository API.
|
javax.jcr.version |
Provides interfaces and classes for content repository versioning functionality.
|
Modifier and Type | Class and Description |
---|---|
class |
AccessDeniedException
Exception thrown by access-related methods.
|
class |
InvalidItemStateException
Exception thrown by the write methods of
Node and Property
and by save and refresh if an attempted change would conflict with a
change to the persistent workspace made through another
Session . |
class |
InvalidSerializedDataException
Exception thrown by the deserialization methods of
Session
if the serialized data being input has an invalid format. |
class |
ItemExistsException
An exception thrown when an attempt is made to place an item in a position
where another item already exists.
|
class |
ItemNotFoundException
|
class |
LoginException
Exception thrown by
and if the specified
credentials are invalid. |
class |
MergeException
Exception thrown by
Node.merge(String srcWorkspace, boolean isDeep) . |
class |
NamespaceException
Exception thrown by
if the specified uri is not registered in the NamespaceRegistry |
class |
NoSuchWorkspaceException
Exception thrown by
when a specific workspace is not found. |
class |
PathNotFoundException
Exception thrown when no
Item exists at the specified path
or when the specified path implies intermediary Node s that do
not exist. |
class |
ReferentialIntegrityException
Exception thrown on referential integrity violation.
|
class |
UnsupportedRepositoryOperationException
Thrown by methods that are not supported by a particluar implementation
|
class |
ValueFormatException
Exception thrown when an attempt is made to assign a
value to a property that has an invalid format, given the type of the
property.
|
Modifier and Type | Method and Description |
---|---|
void |
Item.accept(ItemVisitor visitor)
Accepts an
ItemVistor . |
void |
Node.addMixin(String mixinName)
Adds the specified mixin node type to this node.
|
Node |
Node.addNode(String relPath)
Creates a new node at
relPath . |
Node |
Node.addNode(String relPath,
String primaryNodeTypeName)
Creates a new node at
relPath of the specified node type. |
boolean |
Node.canAddMixin(String mixinName)
Returns
true if the specified mixin node type, mixinName ,
can be added to this node. |
void |
Node.cancelMerge(Version version)
Cancels the merge process with respect to this node and specified
version . |
Version |
Node.checkin()
Creates a new version with a system generated version name and returns that version
(which will be the new base version of this node).
|
void |
Node.checkout()
Sets this versionable node to checked-out status by setting its
jcr:isCheckedOut property to true and adds to the
jcr:predecessors (multi-value) property a reference to the current
base version (the same value as held in jcr:baseVersion ). |
void |
Session.checkPermission(String absPath,
String actions)
Determines whether this
Session has permission to perform the specified actions
at the specified absPath . |
void |
Workspace.clone(String srcWorkspace,
String srcAbsPath,
String destAbsPath,
boolean removeExisting)
Clones the subtree at the node
srcAbsPath in srcWorkspace to the new location at
destAbsPath in this workspace. |
void |
Workspace.copy(String srcAbsPath,
String destAbsPath)
This method copies the node at
srcAbsPath to the new location at
destAbsPath . |
void |
Workspace.copy(String srcWorkspace,
String srcAbsPath,
String destAbsPath)
This method copies the subtree at
srcAbsPath in srcWorkspace
to destAbsPath in this workspace. |
Value |
ValueFactory.createValue(Node value)
|
void |
Node.doneMerge(Version version)
Completes the merge process with respect to this node and the specified
version . |
void |
Session.exportDocumentView(String absPath,
ContentHandler contentHandler,
boolean skipBinary,
boolean noRecurse)
Serializes the node (and if
noRecurse is false ,
the whole subtree) at absPath into a series of SAX events by
calling the methods of the supplied org.xml.sax.ContentHandler . |
void |
Session.exportDocumentView(String absPath,
OutputStream out,
boolean skipBinary,
boolean noRecurse)
Serializes the node (and if
noRecurse is false ,
the whole subtree) at absPath as an XML stream and outputs it to
the supplied OutputStream . |
void |
Session.exportSystemView(String absPath,
ContentHandler contentHandler,
boolean skipBinary,
boolean noRecurse)
Serializes the node (and if
noRecurse is false ,
the whole subtree) at absPath into a series of SAX events by
calling the methods of the supplied org.xml.sax.ContentHandler . |
void |
Session.exportSystemView(String absPath,
OutputStream out,
boolean skipBinary,
boolean noRecurse)
Serializes the node (and if
noRecurse is false ,
the whole subtree) at absPath as an XML stream and outputs it to
the supplied OutputStream . |
String[] |
Workspace.getAccessibleWorkspaceNames()
Returns an string array containing the names of all workspaces
in this repository that are accessible to this user, given the
Credentials that were used to get the Session
tied to this Workspace . |
Item |
Item.getAncestor(int depth)
Returns the ancestor of the specified depth.
|
Version |
Node.getBaseVersion()
Returns the current base version of this versionable node.
|
boolean |
Value.getBoolean()
Returns a
Boolean representation of this value. |
boolean |
Property.getBoolean()
Returns a
boolean representation of the value of this
property. |
String |
Node.getCorrespondingNodePath(String workspaceName)
Returns the absolute path of the node in the specified workspace that
corresponds to
this node. |
Calendar |
Value.getDate()
Returns a
Calendar representation of this value. |
Calendar |
Property.getDate()
Returns a
Calendar representation of the value of this
property. |
PropertyDefinition |
Property.getDefinition()
Returns the property definition that applies to this property.
|
NodeDefinition |
Node.getDefinition()
Returns the node definition that applies to this node.
|
int |
Item.getDepth()
Returns the depth of this
Item in the workspace tree. |
double |
Value.getDouble()
Returns a
double representation of this value. |
double |
Property.getDouble()
Returns a
double representation of the value of this
property. |
ContentHandler |
Session.getImportContentHandler(String parentAbsPath,
int uuidBehavior)
Returns an
org.xml.sax.ContentHandler which can be used to
push SAX events into the repository. |
ContentHandler |
Workspace.getImportContentHandler(String parentAbsPath,
int uuidBehavior)
Returns an
org.xml.sax.ContentHandler which can be used to push SAX events into the repository. |
int |
Node.getIndex()
This method returns the index of this node within the ordered set of its same-name
sibling nodes.
|
Item |
Session.getItem(String absPath)
Returns the item at the specified absolute path in the workspace.
|
long |
Property.getLength()
Returns the length of the value of this property.
|
long[] |
Property.getLengths()
Returns an array holding the lengths of the values of this (multi-value) property in bytes
if the values are
PropertyType.BINARY , otherwise it returns the number of
characters needed to display the value in its string form. |
Lock |
Node.getLock()
Returns the
Lock object that applies to this node. |
long |
Value.getLong()
Returns a
long representation of this value. |
long |
Property.getLong()
Returns a
long representation of the value of this
property. |
NodeType[] |
Node.getMixinNodeTypes()
Returns an array of NodeType objects representing the mixin node types
assigned to this node.
|
String |
Item.getName()
Returns the name of this
Item . |
String |
Session.getNamespacePrefix(String uri)
Returns the prefix to which the given URI is mapped
|
String[] |
Session.getNamespacePrefixes()
Returns all prefixes currently set for this session.
|
NamespaceRegistry |
Workspace.getNamespaceRegistry()
Returns the
NamespaceRegistry object, which is used to access information
and (in level 2) set the mapping between namespace prefixes and URIs. |
String |
Session.getNamespaceURI(String prefix)
For a given prefix, returns the URI to which it is mapped as currently
set in this
Session . |
Node |
Property.getNode()
If this property is of type
REFERENCE
this method returns the node to which this property refers. |
Node |
Node.getNode(String relPath)
Returns the node at
relPath relative to this node. |
Node |
Session.getNodeByUUID(String uuid)
Returns the node specifed by the given UUID.
|
NodeIterator |
Node.getNodes()
Returns a
NodeIterator over all child Node s of
this Node . |
NodeIterator |
Node.getNodes(String namePattern)
Gets all child nodes of this node that match
namePattern . |
NodeTypeManager |
Workspace.getNodeTypeManager()
Returns the
NodeTypeManager through which node type
information can be queried. |
ObservationManager |
Workspace.getObservationManager()
If the the implementation supports observation
this method returns the
ObservationManager object;
otherwise it throws an UnsupportedRepositoryOperationException . |
Node |
Item.getParent()
Returns the parent of this
Item . |
String |
Item.getPath()
Returns the absolute path to this item.
|
String |
NamespaceRegistry.getPrefix(String uri)
Returns the prefix to which the given URI is mapped
|
String[] |
NamespaceRegistry.getPrefixes()
Returns an array holding all currently registered prefixes.
|
Item |
Node.getPrimaryItem()
Returns the primary child item of this node.
|
NodeType |
Node.getPrimaryNodeType()
Returns the primary node type of this node.
|
PropertyIterator |
Node.getProperties()
Returns all properties of this node.
|
PropertyIterator |
Node.getProperties(String namePattern)
Gets all properties of this node that match
namePattern . |
Property |
Node.getProperty(String relPath)
Returns the property at
relPath relative to this
node. |
QueryManager |
Workspace.getQueryManager()
Gets the
QueryManager . |
PropertyIterator |
Node.getReferences()
Returns all
REFERENCE properties that refer to this node. |
Node |
Session.getRootNode()
Returns the root node of the workspace.
|
Session |
Item.getSession()
Returns the
Session through which this Item
was acquired. |
InputStream |
Value.getStream()
Returns an
InputStream representation of this value. |
InputStream |
Property.getStream()
Returns an
InputStream representation of the value of this
property. |
String |
Value.getString()
Returns a
String representation of this value. |
String |
Property.getString()
Returns a
String representation of the value of this
property. |
int |
Property.getType()
Returns the type of this
Property . |
String |
NamespaceRegistry.getURI(String prefix)
Returns the URI to which the given prefix is mapped.
|
String[] |
NamespaceRegistry.getURIs()
Returns an array holding all currently registered URIs.
|
String |
Node.getUUID()
Returns the UUID of this node as recorded in this node's
jcr:uuid
property. |
Value |
Property.getValue()
Returns the value of this property as a generic
Value object. |
ValueFactory |
Session.getValueFactory()
This method returns a
ValueFactory that is used to create Value objects
for use when setting repository properties. |
Value[] |
Property.getValues()
Returns an array of all the values of this property.
|
VersionHistory |
Node.getVersionHistory()
Returns the
VersionHistory object of this node. |
boolean |
Node.hasNode(String relPath)
Indicates whether a node exists at
relPath
Returns true if a node exists at relPath and
false otherwise. |
boolean |
Node.hasNodes()
Indicates whether this node has child nodes.
|
boolean |
Session.hasPendingChanges()
Returns
true if this session holds pending (that is, unsaved) changes;
otherwise returns false . |
boolean |
Node.hasProperties()
Indicates whether this node has properties.
|
boolean |
Node.hasProperty(String relPath)
Indicates whether a property exists at
relPath
Returns true if a property exists at relPath and
false otherwise. |
boolean |
Node.holdsLock()
Returns
true if this node holds a lock; otherwise returns false . |
Session |
Session.impersonate(Credentials credentials)
Returns a new session in accordance with the specified (new) Credentials.
|
void |
Session.importXML(String parentAbsPath,
InputStream in,
int uuidBehavior)
Deserializes an XML document and adds the resulting item subtree as a
child of the node at parentAbsPath.
|
void |
Workspace.importXML(String parentAbsPath,
InputStream in,
int uuidBehavior)
Deserializes an XML document and adds the resulting item subtree as a child of the node at
parentAbsPath . |
boolean |
Node.isCheckedOut()
Returns true if this node is either
versionable and currently checked-out,
non-versionable and its nearest versionable ancestor is checked-out or
non-versionable and it has no versionable ancestor.
|
boolean |
Node.isLocked()
Returns
true if this node is locked either as a result of a lock held by this node or by a deep
lock on a node above this node; otherwise returns false . |
boolean |
Node.isNodeType(String nodeTypeName)
Indicates whether this node is of the specified node type.
|
boolean |
Item.isSame(Item otherItem)
Returns
true if this Item object
(the Java object instance) represents the same actual repository item as the
object otherItem . |
boolean |
Session.itemExists(String absPath)
Returns
true if an item exists at absPath ; otherwise returns false . |
Lock |
Node.lock(boolean isDeep,
boolean isSessionScoped)
Places a lock on this node.
|
Session |
Repository.login()
Equivalent to
login(null, null) . |
Session |
Repository.login(Credentials credentials)
Equivalent to
login(credentials, null) . |
Session |
Repository.login(Credentials credentials,
String workspaceName)
Authenticates the user using the supplied
credentials . |
Session |
Repository.login(String workspaceName)
Equivalent to
login(null, workspaceName) . |
NodeIterator |
Node.merge(String srcWorkspace,
boolean bestEffort)
This method can be thought of as a version-sensitive update (see 7.1.7
Updating and Cloning Nodes across Workspaces in the specification).
|
void |
Session.move(String srcAbsPath,
String destAbsPath)
Moves the node at
srcAbsPath (and its entire subtree) to the new location
at destAbsPath . |
void |
Workspace.move(String srcAbsPath,
String destAbsPath)
Moves the node at
srcAbsPath (and its entire subtree) to the
new location at destAbsPath . |
void |
Node.orderBefore(String srcChildRelPath,
String destChildRelPath)
If this node supports child node ordering, this method inserts the child node at
srcChildRelPath before its sibling, the child node at destChildRelPath ,
in the child node list. |
void |
Session.refresh(boolean keepChanges)
If
keepChanges is false , this method discards all pending changes
currently recorded in this Session and returns all items to reflect the current
saved state. |
void |
Item.refresh(boolean keepChanges)
If
keepChanges is false , this method discards all pending changes
currently recorded in this Session that apply to this Item or any of its descendants
(that is, the subtree rooted at this Item)and returns all items to reflect the current
saved state. |
void |
NamespaceRegistry.registerNamespace(String prefix,
String uri)
Sets a one-to-one mapping between prefix and URI in the global namespace registry of this repository.
|
void |
Item.remove()
Removes
this item (and its subtree). |
void |
Node.removeMixin(String mixinName)
Removes the specified mixin node type from this node.
|
void |
Node.restore(String versionName,
boolean removeExisting)
Restores
this node to the state defined by the
version with the specified versionName . |
void |
Workspace.restore(Version[] versions,
boolean removeExisting)
Restores a set of versions at once.
|
void |
Node.restore(Version version,
boolean removeExisting)
Restores
this node to the state defined by the specified
version . |
void |
Node.restore(Version version,
String relPath,
boolean removeExisting)
Restores the specified version to
relPath , relative to this node. |
void |
Node.restoreByLabel(String versionLabel,
boolean removeExisting)
Restores the version of this node with the specified version label.
|
void |
Session.save()
Validates all pending changes currently recorded in this
Session . |
void |
Item.save()
Validates all pending changes currently recorded in this
Session that apply to this Item
or any of its descendants (that is, the subtree rooted at this Item). |
void |
Session.setNamespacePrefix(String prefix,
String uri)
Within the scope of this session, rename a persistently registered
namespace URI to the new prefix.
|
Property |
Node.setProperty(String name,
boolean value)
Sets the specified property to the specified value.
|
Property |
Node.setProperty(String name,
Calendar value)
Sets the specified property to the specified value.
|
Property |
Node.setProperty(String name,
double value)
Sets the specified property to the specified value.
|
Property |
Node.setProperty(String name,
InputStream value)
Sets the specified property to the specified value.
|
Property |
Node.setProperty(String name,
long value)
Sets the specified property to the specified value.
|
Property |
Node.setProperty(String name,
Node value)
Sets the specified (
REFERENCE )property
to refer to the specified Node . |
Property |
Node.setProperty(String name,
String value)
Sets the specified property to the specified value.
|
Property |
Node.setProperty(String name,
String[] values)
Sets the specified property to the specified array of values.
|
Property |
Node.setProperty(String name,
String[] values,
int type)
Sets the specified property to the specified array of values and to the specified type.
|
Property |
Node.setProperty(String name,
String value,
int type)
Sets the specified (single-value) property to the specified value.
|
Property |
Node.setProperty(String name,
Value value)
Sets the specified (single-value) property of this node to the specified
value . |
Property |
Node.setProperty(String name,
Value[] values)
Sets the specified (multi-value) property to the specified array of values.
|
Property |
Node.setProperty(String name,
Value[] values,
int type)
Sets the specified (multi-value) property to the specified array of values.
|
Property |
Node.setProperty(String name,
Value value,
int type)
Sets the specified (single-value) property to the specified value.
|
void |
Property.setValue(boolean value)
Sets the value of this property to
value . |
void |
Property.setValue(Calendar value)
Sets the value of this property to
value . |
void |
Property.setValue(double value)
Sets the value of this property to
value . |
void |
Property.setValue(InputStream value)
Sets the value of this property to
value . |
void |
Property.setValue(long value)
Sets the value of this property to
value . |
void |
Property.setValue(Node value)
Sets this REFERENCE property to refer to the specified node.
|
void |
Property.setValue(String value)
Sets the value of this property to
value . |
void |
Property.setValue(String[] values)
Sets the value of this property to the
values array. |
void |
Property.setValue(Value value)
Sets the value of this property to
value . |
void |
Property.setValue(Value[] values)
Sets the value of this property to the
values array. |
void |
Node.unlock()
Removes the lock on this node.
|
void |
NamespaceRegistry.unregisterNamespace(String prefix)
Removes a namespace mapping from the registry.
|
void |
Node.update(String srcWorkspaceName)
If this node does have a corresponding node in the workspace
srcWorkspaceName ,
then this replaces this node and its subtree with a clone of the corresponding node and its
subtree. |
void |
ItemVisitor.visit(Node node)
This method is called when the
ItemVisitor is
passed to the accept method of a Node . |
void |
ItemVisitor.visit(Property property)
This method is called when the
ItemVisitor is
passed to the accept method of a Property . |
Modifier and Type | Class and Description |
---|---|
class |
LockException
Exception thrown by
Item.save() and Session.save() when
persisting a change would conflict with a lock. |
Modifier and Type | Method and Description |
---|---|
boolean |
Lock.isLive()
Returns true if this
Lock object represents a lock that is currently in effect. |
void |
Lock.refresh()
If this lock's time-to-live is governed by a timer, this method resets that timer so that the
lock does not timeout and expire.
|
Modifier and Type | Class and Description |
---|---|
class |
ConstraintViolationException
Exception thrown when an action would violate
a constraint on repository structure.
|
class |
NoSuchNodeTypeException
Exception thrown by node type-related methods.
|
Modifier and Type | Method and Description |
---|---|
NodeTypeIterator |
NodeTypeManager.getAllNodeTypes()
Returns an iterator over all available node types (primary and mixin).
|
NodeTypeIterator |
NodeTypeManager.getMixinNodeTypes()
Returns an iterator over all available mixin node types.
|
NodeType |
NodeTypeManager.getNodeType(String nodeTypeName)
Returns the named node type.
|
NodeTypeIterator |
NodeTypeManager.getPrimaryNodeTypes()
Returns an iterator over all available primary node types.
|
Modifier and Type | Method and Description |
---|---|
void |
ObservationManager.addEventListener(EventListener listener,
int eventTypes,
String absPath,
boolean isDeep,
String[] uuid,
String[] nodeTypeName,
boolean noLocal)
Adds an event listener that listens for the specified
eventTypes (a combination of one or more
event types encoded as a bit mask value). |
String |
Event.getPath()
Returns the absolute path of the parent node connected with this event.
|
EventListenerIterator |
ObservationManager.getRegisteredEventListeners()
Returns all event listeners that have been registered through this session.
|
void |
ObservationManager.removeEventListener(EventListener listener)
Deregisters an event listener.
|
Modifier and Type | Class and Description |
---|---|
class |
InvalidQueryException
Thrown by methods of
Query . |
Modifier and Type | Method and Description |
---|---|
Query |
QueryManager.createQuery(String statement,
String language)
Creates a new query by specifying the query
statement itself and the
language in which the query is stated. |
QueryResult |
Query.execute()
Executes this query and returns a
. |
String[] |
QueryResult.getColumnNames()
Returns an array of all the property names (column names) in this result set.
|
NodeIterator |
QueryResult.getNodes()
Returns an iterator over all nodes that match the query.
|
Query |
QueryManager.getQuery(Node node)
Retrieves an existing persistent query.
|
RowIterator |
QueryResult.getRows()
Returns an iterator over the
Row s of the query result table. |
String |
Query.getStoredQueryPath()
If this is a
Query object that has been stored using
Query.storeAsNode(java.lang.String) (regardless of whether it has been save d yet)
or retrieved using QueryManager.getQuery(javax.jcr.Node) ), then this method
returns the path of the nt:query node that stores the query. |
String[] |
QueryManager.getSupportedQueryLanguages()
Returns an array of strings representing all query languages supported by this repository.
|
Value |
Row.getValue(String propertyName)
Returns the value of the indicated property in this
Row . |
Value[] |
Row.getValues()
Returns an array of all the values in the same order as the
column names returned by
QueryResult.getColumnNames() . |
Node |
Query.storeAsNode(String absPath)
Creates a node representing this
Query in content. |
Modifier and Type | Method and Description |
---|---|
protected abstract void |
TraversingItemVisitor.entering(Node node,
int level)
Implement this method to add behaviour performed before a
Node is visited. |
protected void |
TraversingItemVisitor.Default.entering(Node node,
int level) |
protected abstract void |
TraversingItemVisitor.entering(Property property,
int level)
Implement this method to add behaviour performed before a
Property is visited. |
protected void |
TraversingItemVisitor.Default.entering(Property property,
int level) |
protected abstract void |
TraversingItemVisitor.leaving(Node node,
int level)
Implement this method to add behaviour performed after a
Node is visited. |
protected void |
TraversingItemVisitor.Default.leaving(Node node,
int level) |
protected abstract void |
TraversingItemVisitor.leaving(Property property,
int level)
Implement this method to add behaviour performed after a
Property is visited. |
protected void |
TraversingItemVisitor.Default.leaving(Property property,
int level) |
void |
TraversingItemVisitor.visit(Node node)
Called when the Visitor is passed to a
Node . |
void |
TraversingItemVisitor.visit(Property property)
Called when the Visitor is passed to a
Property . |
Modifier and Type | Class and Description |
---|---|
class |
VersionException
Exception thrown by Version.addSuccessor if an invalid
version graph operation is attempted.
|
Modifier and Type | Method and Description |
---|---|
void |
VersionHistory.addVersionLabel(String versionName,
String label,
boolean moveLabel)
Adds the specified label to the specified version.
|
VersionIterator |
VersionHistory.getAllVersions()
Returns an iterator over all the versions within this version history
The order of the returned objects will not necessarily correspond to the
order of versions in terms of the successor relation.
|
VersionHistory |
Version.getContainingHistory()
Returns the
VersionHistory that contains this Version . |
Calendar |
Version.getCreated()
Returns the date this version was created.
|
Version[] |
Version.getPredecessors()
Returns the predecessor versions of this version.
|
Version |
VersionHistory.getRootVersion()
Returns the root version of this version history.
|
Version[] |
Version.getSuccessors()
Returns the successor versions of this version.
|
Version |
VersionHistory.getVersion(String versionName)
Retrieves a particular version from this version history by version name.
|
String |
VersionHistory.getVersionableUUID()
Returns the UUID of the versionable node for which this is the version history.
|
Version |
VersionHistory.getVersionByLabel(String label)
Retrieves a particular version from this version history by version label.
|
String[] |
VersionHistory.getVersionLabels()
Returns all version labels of the history or an empty array if there are none.
|
String[] |
VersionHistory.getVersionLabels(Version version)
Returns all version labels of the given
version - empty array if none. |
boolean |
VersionHistory.hasVersionLabel(String label)
Returns
true if any version in the history has the given label . |
boolean |
VersionHistory.hasVersionLabel(Version version,
String label)
Returns true if the given version has the given
label . |
void |
VersionHistory.removeVersion(String versionName)
Removes the named version from this version history and automatically
repairs the version graph.
|
void |
VersionHistory.removeVersionLabel(String label)
Removes the specified label from among the labels of this version history.
|
Copyright © 2004–2013 Day Management AG. All rights reserved.