protected static class ItemSequence.PropertySequenceImpl extends ItemSequence implements PropertySequence
ItemSequence.NodeSequenceImpl, ItemSequence.PropertySequenceImplautoSave, errorHandler, order, root, treeManager| Constructor and Description |
|---|
PropertySequenceImpl(TreeManager treeManager,
TreeTraverser.ErrorHandler errorHandler) |
| Modifier and Type | Method and Description |
|---|---|
Property |
addProperty(String key,
Value value)
Add a property with the given
key and value. |
Property |
getItem(String key)
Retrieve an
Item from this sequence by its key. |
Node |
getParent(String key)
Returns the parent node for the given key.
|
boolean |
hasItem(String key)
Determine whether this sequence contains a specific
key. |
Iterator<Property> |
iterator()
Iterator for the
Items in this sequence. |
void |
removeProperty(String key)
Remove the property with the given key.
|
createNodeSequence, createNodeSequence, createPropertySequence, createPropertySequence, getMinimal, getMinimal, getNodeSequence, getPredecessor, getPredecessor, getPropertySequence, getSuccessor, renamePathclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorpublic PropertySequenceImpl(TreeManager treeManager, TreeTraverser.ErrorHandler errorHandler)
public Iterator<Property> iterator()
SequenceItems in this sequence. The order of the items
is implementation specific.public Property getItem(String key) throws RepositoryException
SequenceItem from this sequence by its key. If
the sequence does not contain the key this method throws an
ItemNotFoundException.getItem in interface Sequence<Property>key - The key of the item to retrieve. Must not be
null.key.ItemNotFoundExceptionRepositoryExceptionpublic boolean hasItem(String key) throws RepositoryException
Sequencekey.hasItem in interface Sequence<Property>key - The key to look up.true if this sequence contains key.
False otherwise.RepositoryExceptionpublic Property addProperty(String key, Value value) throws RepositoryException
PropertySequencekey and value.addProperty in interface PropertySequencekey - key of the property to addvalue - value of the property to addRepositoryExceptionpublic void removeProperty(String key) throws RepositoryException
PropertySequenceremoveProperty in interface PropertySequencekey - The key of the property to removeRepositoryException - If there is no property with such a key or
another error occurs.public Node getParent(String key) throws RepositoryException
ItemSequencegetParent in class ItemSequenceRepositoryExceptionCopyright © 2004–2024 The Apache Software Foundation. All rights reserved.