public class HTMrange extends Object
Current Version =============== ID: $Id: HTMrange.java,v 1.3 2003/03/05 19:22:24 womullan Exp $ Revision: $Revision: 1.3 $ Date/time: $Date: 2003/03/05 19:22:24 $
| Modifier and Type | Field and Description |
|---|---|
static int |
GAP_HISTO_SIZE |
static int |
HIGHS |
static int |
InclAdjacentXXX |
static int |
InclHi |
static int |
InclInside |
static int |
InclLo |
static int |
InclOutside |
static int |
INSIDE |
static int |
INTERSECT |
static int |
LOWS |
protected SkipList |
my_his |
protected SkipList |
my_los |
static int |
OUTSIDE |
static float |
SKIP_PROB |
| Constructor and Description |
|---|
HTMrange() |
| Modifier and Type | Method and Description |
|---|---|
void |
addRange(long lo,
long hi)
simply add this range - no checks performed the lo is added to the lows
and the high is added to the highs
|
long |
bestgap(int desiredSize)
return the smallest gapsize at which rangelist would be smaller than
desired size
|
int |
compare(HTMrange other)
this is not imlemented properly
|
void |
defrag()
merge contiguous ranges
|
void |
defrag(long gap)
checks that the gap between intervals is at least gap.
|
void |
finalize() |
long[] |
getNext()
returns the next hlo,hi pair in the long[] this is like an iterator but
it can only be used by one thread i.e.
|
int |
isIn(HTMrange otherRange)
Check if the range contains the given range.
|
boolean |
isIn(long key)
does the range contain this key calls inside and simplifies answer to
boolean
|
int |
isIn(long a,
long b)
Check if the range a to b is contained in this set.
|
void |
levelto(int depth)
not implemented
|
void |
mergeRange(long lo,
long hi)
Add the given range to this set.
|
long[] |
minmax() |
int |
nranges()
return the number of ranges
|
void |
purge() |
void |
reset()
reset the hi and lo iterators
|
long |
stats(int desiredSize) |
int |
tinside(long mid)
check if mid is included in this set
|
String |
toString() |
String |
toString(boolean symbolic)
converts the lo,his pairs to HTM names if sybolic is true
|
String |
toString(int what,
boolean symbolic)
return only his or lows (statics defined on this class) according to what
is passed in what.
|
public static final int LOWS
public static final int HIGHS
public static final int INSIDE
public static final int OUTSIDE
public static final int INTERSECT
public static final int GAP_HISTO_SIZE
public static final float SKIP_PROB
public static final int InclOutside
public static final int InclInside
public static final int InclLo
public static final int InclHi
public static final int InclAdjacentXXX
protected SkipList my_los
protected SkipList my_his
public int compare(HTMrange other)
public int isIn(long a,
long b)
public boolean isIn(long key)
public int isIn(HTMrange otherRange)
public int tinside(long mid)
public void mergeRange(long lo,
long hi)
public void addRange(long lo,
long hi)
public void defrag(long gap)
public void defrag()
public void levelto(int depth)
public void purge()
public void reset()
public int nranges()
public long bestgap(int desiredSize)
public long stats(int desiredSize)
public String toString(boolean symbolic) throws HTMException
HTMExceptionpublic long[] minmax()
throws HTMException
HTMExceptionpublic long[] getNext()