|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.nodal.util.NodeFilter
org.nodal.util.SequenceFilter
Combine Node and SequenceContent interfaces to create the Sequence interface.
This class takes a Node interface and a SequenceContent interface and aggregates their interfaces to create the Sequence interface. It can be used all by itself or inherited so as to provide a filter upon which particular methods can be selectively overridden.
Nested Class Summary |
Nested classes inherited from class org.nodal.model.SequenceNode |
SequenceNode.Editor |
Field Summary | |
protected SequenceContent |
seq
|
Fields inherited from class org.nodal.util.NodeFilter |
node |
Constructor Summary | |
protected |
SequenceFilter(Node n,
SequenceContent r)
|
Method Summary | |
MapNode |
asMapNode()
The Node's contents expressed as a Map. |
RecordNode |
asRecordNode()
The Node's contents expressed as a Record. |
SequenceNode |
asSequenceNode()
The Node's contents expressed as a Sequence. |
NodeContent |
content()
The Node's contents. |
abstract NodeContent.Editor |
edit()
An Editor for changing the Content of this Node. |
Getter |
item(int index)
Return a Getter for the item at the given index. |
java.util.Iterator |
properties()
A sequence of all of the properties currently indexing the contents if this Content. |
Getter |
range(int start,
int end)
Return a Getter for the sequence of items indexed from start to end, inclusive. |
int |
size()
The number of properties contained in this Content object. |
Getter |
value(java.lang.Object obj)
A generic Getter for property values, given a property. |
Methods inherited from class org.nodal.util.NodeFilter |
asAnchor, bareNode, capability, editMap, editRecord, editSequence, history, id, path, repository, type |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.nodal.model.SequenceNode |
editSequence |
Methods inherited from interface org.nodal.model.SequenceContent |
asSeq, getItem, indexIsValid |
Methods inherited from interface org.nodal.model.Content |
getValue, invert, isValidProperty, type |
Methods inherited from interface org.nodal.model.Node |
asAnchor, bareNode, capability, editMap, editRecord, history, id, path, repository, type |
Methods inherited from interface org.nodal.model.TxnMonitorable |
addTxnHandler, removeTxnHandler |
Field Detail |
protected SequenceContent seq
Constructor Detail |
protected SequenceFilter(Node n, SequenceContent r)
Method Detail |
public NodeContent content()
Node
If the Capability does not provide read access, then this will return null.
content
in interface Node
content
in class NodeFilter
public int size()
Content
size
in interface Content
public java.util.Iterator properties()
Content
properties
in interface Content
public Getter value(java.lang.Object obj) throws PropertyConstraintFailure
Content
Will throw an exception if the property type is invalid, but not if the property is not available in this Node's content. This way, a value Getter can be established in anticipation of the addition of a property.
value
in interface Content
obj
- the Object that identifies this property
PropertyConstraintFailure
public MapNode asMapNode()
Node
asMapNode
in interface Node
asMapNode
in class NodeFilter
public RecordNode asRecordNode()
Node
asRecordNode
in interface Node
asRecordNode
in class NodeFilter
public SequenceNode asSequenceNode()
Node
asSequenceNode
in interface Node
asSequenceNode
in class NodeFilter
public Getter item(int index) throws IndexBoundsException
SequenceContent
item
in interface SequenceContent
IndexBoundsException
public Getter range(int start, int end) throws IndexBoundsException
SequenceContent
The value returned by the Getter is an instance of org.nodal.util.Seq.
range
in interface SequenceContent
IndexBoundsException
Seq
public abstract NodeContent.Editor edit()
Node
edit
in interface Node
edit
in class NodeFilter
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |