|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectedu.uky.rch.ept.xmlSegmentTree.element.position.SimplePosition
| Constructor Summary | |
SimplePosition(int position)
|
|
| Method Summary | |
Element |
begin(Element e)
Transform an element of which this is the beginning position. |
int |
compareTo(Object o)
Compare this position to another Position. |
Element |
end(Element e)
Transform an element of which this is the ending position. |
boolean |
equals(Object o)
|
Position |
extend(Position p)
Find the Position the same distance from this position as another position, but on the other side. |
Position |
midpoint(Position p)
Find the Position midway between this position and another one. |
Position |
next()
Return the position immediately following this one. |
int |
pos()
Return the integer value of this position. |
Position |
previous()
Return the position immediately preceding this one. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public SimplePosition(int position)
| Method Detail |
public int pos()
Positionpos() should
be nondecreasing with respect to the ordering imposed by
Position.compareTo(java.lang.Object), but need not be strictly increasing.
pos in interface Positionpublic Position next()
Position
next in interface Positionpublic Position previous()
Position
previous in interface Positionpublic Position midpoint(Position p)
Position
midpoint in interface Positionp - the other endpoint.
p.public Element begin(Element e)
Position
begin in interface Positione - the Element to transform.
e, possibly
e itself.public Element end(Element e)
Position
end in interface Positione - the Element to transform.
e, possibly
e itself.public Position extend(Position p)
Position
extend in interface Positionp - the other endpoint.
p.public int compareTo(Object o)
PositionPosition. As is always
the case with Comparables, implementors must ensure that
compareTo is transitive, antisymmetric, and irreflexive
regardless of the particular classes of the arguments. In
practice, this means that compareTo may treat objects of
the same class specially, but should use Position.pos() to compare
Elements which are not related in an implementation heirarchy.
compareTo in interface Positiono - the object against which to compare.
o,
1 if this position follows o, or 0 if
this position equals o.public boolean equals(Object o)
public String toString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||