|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.biojava.bio.symbol.AbstractLocation
org.biojava.bio.symbol.AbstractRangeLocation
Base class for simple contiguous Location implementations.
getMin
and getMax
, and translate
..Field Summary |
Fields inherited from interface org.biojava.bio.symbol.Location |
empty, naturalOrder |
Constructor Summary | |
AbstractRangeLocation()
|
Method Summary | |
java.util.Iterator |
blockIterator()
Return an Iterator over the set of maximal contiguous sub-locations. |
boolean |
contains(int p)
Checks if this location contains a point. |
boolean |
isContiguous()
Determine if a Location is contiguous. |
SymbolList |
symbols(SymbolList seq)
Return the symbols in a sequence that fall within this range. |
Methods inherited from class org.biojava.bio.symbol.AbstractLocation |
contains, equals, getDecorator, hashCode, intersection, newInstance, overlaps, union |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.biojava.bio.symbol.Location |
getMax, getMin, translate |
Constructor Detail |
public AbstractRangeLocation()
Method Detail |
public java.util.Iterator blockIterator()
Location
Given any location, it can be considered to contain zero or more maximal contiguous blocks of width 1 or greater. The empty location is composed from nothing. A contiguous location is composed from itself. A non-contiguous location is composed from contiguous blocks seperated by gaps.
This method should return an Iterator over these maximally contiguous blocks starting with the left-most block, and finishing at the right-most block.
public boolean isContiguous()
Location
true
if and only if this Location
contains every point from min
to
max
inclusive.public SymbolList symbols(SymbolList seq)
Location
seq
- the SymbolList to process
public boolean contains(int p)
Location
p
- the point to check
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |