|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--gzz.media.impl.Enfilade1DImpl
A simple tree implementation of enfilades.
Nested Class Summary | |
static class |
Enfilade1DImpl.Enfilade1DImplMaker
|
Nested classes inherited from class gzz.media.Enfilade1D |
|
Field Summary | |
static java.lang.String |
rcsid
|
static Enfilade1D.Maker |
theMaker
|
Constructor Summary | |
Enfilade1DImpl(Enfilade1DImpl left,
Span middle,
Enfilade1DImpl right)
|
|
Enfilade1DImpl(java.util.List spans,
int from,
int n)
|
|
Enfilade1DImpl(Span span)
|
Method Summary | |
void |
addToList(java.util.List l)
|
boolean |
equals(java.lang.Object o)
|
java.util.List |
getList()
Get a List of the spans in this enfilade. |
Enfilade1D.Maker |
getMaker()
|
int |
hashCode()
|
boolean |
intersects(Enfilade1D other0)
Return true if this enfilade intersects (span-wise) the other one. |
boolean |
intersects(Span s)
Return true if this enfilade intersects (span-wise) the given span. |
int |
length()
Get the sum of the lengths. |
java.lang.String |
makeString()
Return a String object where offsets are the same as in this enfilade. |
Enfilade1D |
optimized()
Return a possibly optimized version of this enfilade. |
Enfilade1D |
plus(Enfilade1D other)
Return an Enfilade1D object whose vstream is a concatenation of this enfilade and the other one given. |
Enfilade1D |
plus(Span1D other)
Return an Enfilade1D object whose vstream is a concatenation of this enfilade and the span given. |
Enfilade1D |
prepended(Span1D other)
Return an Enfilade1D object whose vstream is a concatenation of the given span and this enfilade. |
Enfilade1D |
sub(int o1)
|
Enfilade1D |
sub(int o1,
int o2)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final java.lang.String rcsid
public static Enfilade1D.Maker theMaker
Constructor Detail |
public Enfilade1DImpl(Enfilade1DImpl left, Span middle, Enfilade1DImpl right)
public Enfilade1DImpl(Span span)
public Enfilade1DImpl(java.util.List spans, int from, int n)
Method Detail |
public Enfilade1D.Maker getMaker()
getMaker
in interface Enfilade1D
public int length()
Enfilade1D
length
in interface Enfilade1D
public Enfilade1D sub(int o1)
sub
in interface Enfilade1D
public Enfilade1D sub(int o1, int o2)
sub
in interface Enfilade1D
public Enfilade1D plus(Enfilade1D other)
Enfilade1D
plus
in interface Enfilade1D
public Enfilade1D plus(Span1D other)
Enfilade1D
plus
in interface Enfilade1D
public Enfilade1D prepended(Span1D other)
Enfilade1D
prepended
in interface Enfilade1D
public java.lang.String makeString()
Enfilade1D
This is not toString() because that routine will give a string which explicitly indicates that this is an enfilade, and also gives the permanent ids of the spans therein.
makeString
in interface Enfilade1D
public java.lang.String toString()
toString
in class java.lang.Object
public java.util.List getList()
Enfilade1D
getList
in interface Enfilade1D
public void addToList(java.util.List l)
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean intersects(Enfilade1D other0)
public boolean intersects(Span s)
public Enfilade1D optimized()
Enfilade1D
It is at its most useful for enfilades that have been created by adding little by little to the end, and which are not shared. Of course, most text entered in cells *is* just like that...
This method must at least join spans which are next to each other and which are contiguous (the latter can be appended to the former). This is necessary because coniguous spans MUST be appended before saving, otherwise we'd generate lots of JUNK!
Invariants which implementations MUST obey: ( XXX too harsh? )
optimized
in interface Enfilade1D
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |