|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.khelekore.prtree.SimpleMBR
public class SimpleMBR
An implementation of MBRND that keeps a double array with the max and min values
Please note that you should not normally use this class when PRTree wants a MBR since this will actually use a lot of extra memory.
| Constructor Summary | |
|---|---|
SimpleMBR(double... values)
Create a new SimpleMBR using the given double values for max and min. |
|
SimpleMBR(T t,
MBRConverter<T> converter)
Create a new SimpleMBR from a given object and a MBRConverter |
|
| Method Summary | ||
|---|---|---|
int |
getDimensions()
|
|
double |
getMax(int axis)
Get the maximum value for the given axis |
|
double |
getMin(int axis)
Get the minimum value for the given axis |
|
boolean |
intersects(MBR other)
Check if the other MBR intersects this one |
|
|
intersects(T t,
MBRConverter<T> converter)
Check if this MBR intersects the rectangle given by the object and the MBRConverter. |
|
String |
toString()
|
|
MBR |
union(MBR mbr)
Return a new MBR that is the union of this mbr and the other |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public SimpleMBR(double... values)
values - the min and max values for each dimension.
public SimpleMBR(T t,
MBRConverter<T> converter)
t - the object to create the bounding box forconverter - the actual MBRConverter to use| Method Detail |
|---|
public int getDimensions()
getDimensions in interface MBRpublic double getMin(int axis)
MBR
getMin in interface MBRaxis - the axis to use
public double getMax(int axis)
MBR
getMax in interface MBRaxis - the axis to use
public MBR union(MBR mbr)
MBR
union in interface MBRmbr - the MBR to create a union with
public boolean intersects(MBR other)
MBR
intersects in interface MBRother - the MBR to check against
public <T> boolean intersects(T t,
MBRConverter<T> converter)
MBR
intersects in interface MBRT - the object typet - a rectangular objectconverter - the MBRConverter
public String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||