|
MXQuery 0.6.0 API Documentation - Copyright 2006-2009 ETH Zurich | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectch.ethz.mxquery.update.store.llImpl.TokenList
ch.ethz.mxquery.update.store.llImpl.LLStore
public class LLStore
Saves elements of one XML store in a double linked list.
Field Summary | |
---|---|
LLStoreSet |
storeSet
|
Constructor Summary | |
---|---|
LLStore(LLStoreSet storeSet,
XDMIterator initialDataIterator)
|
|
LLStore(java.lang.String uri,
LLStoreSet storeSet,
XDMIterator initialDataIterator)
|
Method Summary | |
---|---|
void |
appendForInsert(XDMIterator node)
Appends the passed not to the store. |
void |
checkNSXDM()
Check if the inserted store would create conflicting namespace binding or violate XDM constraints |
int |
compare(Source store)
|
boolean |
containsOnlyAttrs()
Does this store only contain attributes? |
boolean |
containsTopAttrs()
Returns true if the sequence that is represented by this
store contains top attributes. |
Source |
copySource(Context ctx,
java.util.Vector nestedPredCtxStack)
|
void |
delete(Identifier targetId)
Deletes the element that has the identifier targetId . |
java.lang.String |
getDoctypeRootElem()
If the store contains a document with a docdecls, return the root element definition |
Window |
getIterator(Context ctx)
Returns Iterator that points on the first token in the store. |
Window |
getIteratorForId(Identifier identifier)
Returns Iterator that points on the token with the passed identifier in the store. |
LLStore |
getNewStoreForSequence(int startPosition,
int endPosition)
|
XDMIterator |
getParentIterator(Identifier id)
Get a window/iterator of the parent |
java.lang.String |
getPublicID()
If the store contains a document with a docdecls, return the public id |
StoreSet |
getStoreSet()
Get the StoreSet that the store belongs to |
java.lang.String |
getSystemID()
If the store contains a document with a docdecls, return the system id |
java.lang.String |
getURI()
Returns the URI of the source. |
void |
insertAfter(Identifier targetId,
UpdateableStore store)
Inserts node after the element with the id
targetId into the store. |
void |
insertAttributes(Identifier targetId,
UpdateableStore store)
Inserts all attributes of node into the XML-start-tag that
has the identifier targetId . |
void |
insertBefore(Identifier targetId,
UpdateableStore store)
Inserts node before the element with the id
targetId into the store. |
void |
insertInto(Identifier targetId,
UpdateableStore store)
Inserts node into the element with the id
targetId . |
void |
insertIntoAsFirst(Identifier targetId,
UpdateableStore store)
Inserts node into the element with the id
targetId at first position. |
void |
insertIntoAsLast(Identifier targetId,
UpdateableStore store)
Inserts node into the element with the id
targetId at last position. |
boolean |
isModified()
Has this store been modified since it has been initially loaded? |
void |
materialize()
|
void |
mergeCleanTextNodes()
Merges and/or removes multiple adjacent or empty text nodes under the same element |
UpdateableStore |
pullAttributes()
A store represents a sequence of elements. |
void |
rename(Identifier targetId,
QName qname)
Renames the element with the identifier targetId . |
void |
replaceNode(Identifier targetId,
UpdateableStore store)
Replaces the element with the identifier targetId with
node . |
void |
replaceNodeContent(Identifier targetId,
UpdateableStore store)
Replaces the content of the element with the identifier targetId with text . |
void |
replaceValue(Identifier targetId,
java.lang.String value)
Replaces the string value of the element with the identifier targetId with stringValue . |
void |
setAssignNewIds(boolean assignNewIds)
|
void |
setModified(boolean modVal)
Set the modification state of the store |
java.lang.String |
toString()
|
java.lang.String |
toString(int addDepth)
|
Methods inherited from class ch.ethz.mxquery.update.store.llImpl.TokenList |
---|
count, countIdiedEls, countLevels, deleteFirst, deleteLast, getFirstToken, getLastToken, getParentId, getToken, hasParent, isEmpty, pullFirst |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface ch.ethz.mxquery.model.updatePrimitives.UpdateableStore |
---|
count, getParentId, hasParent, isEmpty |
Field Detail |
---|
public LLStoreSet storeSet
Constructor Detail |
---|
public LLStore(LLStoreSet storeSet, XDMIterator initialDataIterator)
public LLStore(java.lang.String uri, LLStoreSet storeSet, XDMIterator initialDataIterator)
Method Detail |
---|
public java.lang.String getURI()
Source
getURI
in interface Source
public void appendForInsert(XDMIterator node) throws MXQueryException
UpdateableStore
appendForInsert
in interface UpdateableStore
MXQueryException
public void materialize() throws MXQueryException
materialize
in interface UpdateableStore
MXQueryException
public void delete(Identifier targetId) throws MXQueryException
UpdateableStore
targetId
.
delete
in interface UpdateableStore
targetId
- element identifier
MXQueryException
public void insertAfter(Identifier targetId, UpdateableStore store) throws MXQueryException
UpdateableStore
node
after the element with the id
targetId
into the store.
insertAfter
in interface UpdateableStore
targetId
- element identifierstore
- some data (XQuery Data Model)
MXQueryException
public void insertAttributes(Identifier targetId, UpdateableStore store) throws MXQueryException
UpdateableStore
node
into the XML-start-tag that
has the identifier targetId
.
insertAttributes
in interface UpdateableStore
targetId
- element identifierstore
- attributes to insert (one attribute or a sequence of
attributes)
MXQueryException
public void checkNSXDM() throws MXQueryException
checkNSXDM
in interface UpdateableStore
MXQueryException
public void insertBefore(Identifier targetId, UpdateableStore store) throws MXQueryException
UpdateableStore
node
before the element with the id
targetId
into the store.
insertBefore
in interface UpdateableStore
targetId
- element identifierstore
- some data (XQuery Data Model)
MXQueryException
public void insertInto(Identifier targetId, UpdateableStore store) throws MXQueryException
UpdateableStore
node
into the element with the id
targetId
.
insertInto
in interface UpdateableStore
targetId
- element identifierstore
- some data (XQuery Data Model)
MXQueryException
public void insertIntoAsFirst(Identifier targetId, UpdateableStore store) throws MXQueryException
UpdateableStore
node
into the element with the id
targetId
at first position.
insertIntoAsFirst
in interface UpdateableStore
targetId
- element identifierstore
- some data (XQuery Data Model)
MXQueryException
public void insertIntoAsLast(Identifier targetId, UpdateableStore store) throws MXQueryException
UpdateableStore
node
into the element with the id
targetId
at last position.
insertIntoAsLast
in interface UpdateableStore
targetId
- element identifierstore
- some data (XQuery Data Model)
MXQueryException
public void rename(Identifier targetId, QName qname) throws MXQueryException
UpdateableStore
targetId
.
rename
in interface UpdateableStore
targetId
- element identifier (element must be an XML-node, or processing
instruction node)qname
- new name
MXQueryException
public void replaceNodeContent(Identifier targetId, UpdateableStore store) throws MXQueryException
UpdateableStore
targetId
with text
.
replaceNodeContent
in interface UpdateableStore
targetId
- element identifier (element must be an XML-node)store
- contains per facility only one text element (string, int, ...)
MXQueryException
public void replaceNode(Identifier targetId, UpdateableStore store) throws MXQueryException
UpdateableStore
targetId
with
node
.
replaceNode
in interface UpdateableStore
targetId
- element identifierstore
- some data (XQuery Data Model)
MXQueryException
public void replaceValue(Identifier targetId, java.lang.String value) throws MXQueryException
UpdateableStore
targetId
with stringValue
.
replaceValue
in interface UpdateableStore
targetId
- element identifier (element must be an attribute, text,
comment, or processing instruction node)value
- data that contains a string
MXQueryException
public boolean containsTopAttrs() throws MXQueryException
UpdateableStore
this
store contains top attributes. Top means attributes that are saved
directly in the sequence and not indirectly inside other elements.
containsTopAttrs
in interface UpdateableStore
MXQueryException
public boolean containsOnlyAttrs() throws MXQueryException
UpdateableStore
containsOnlyAttrs
in interface UpdateableStore
MXQueryException
public UpdateableStore pullAttributes() throws MXQueryException
UpdateableStore
this
store) and deletes them in this
store.
pullAttributes
in interface UpdateableStore
MXQueryException
public Window getIterator(Context ctx) throws MXQueryException
Source
getIterator
in interface Source
MXQueryException
public Window getIteratorForId(Identifier identifier) throws MXQueryException
UpdateableStore
getIteratorForId
in interface UpdateableStore
identifier
cannot be found.
MXQueryException
public XDMIterator getParentIterator(Identifier id) throws MXQueryException
UpdateableStore
getParentIterator
in interface UpdateableStore
id
- Node to take as base for the parent
MXQueryException
public StoreSet getStoreSet()
UpdateableStore
getStoreSet
in interface UpdateableStore
public java.lang.String toString(int addDepth)
public java.lang.String toString()
toString
in class java.lang.Object
public int compare(Source store)
compare
in interface Source
public Source copySource(Context ctx, java.util.Vector nestedPredCtxStack)
copySource
in interface Source
public boolean isModified()
UpdateableStore
isModified
in interface UpdateableStore
public void setModified(boolean modVal)
UpdateableStore
setModified
in interface UpdateableStore
public java.lang.String getSystemID()
UpdateableStore
getSystemID
in interface UpdateableStore
public java.lang.String getPublicID()
UpdateableStore
getPublicID
in interface UpdateableStore
public java.lang.String getDoctypeRootElem()
UpdateableStore
getDoctypeRootElem
in interface UpdateableStore
public void setAssignNewIds(boolean assignNewIds)
public LLStore getNewStoreForSequence(int startPosition, int endPosition) throws MXQueryException
MXQueryException
public void mergeCleanTextNodes()
UpdateableStore
mergeCleanTextNodes
in interface UpdateableStore
|
MXQuery 0.6.0 API Documentation - Copyright 2006-2009 ETH Zurich | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |