Package org.h2.mvstore.rtree
Class DefaultSpatial
java.lang.Object
org.h2.mvstore.rtree.DefaultSpatial
- All Implemented Interfaces:
Spatial
Class BasicSpatialImpl.
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionDefaultSpatial(long id, float... minMax) Create a new key.privateDefaultSpatial(long id, DefaultSpatial other) -
Method Summary
Modifier and TypeMethodDescriptionclone(long id) Creates a copy of this Spatial object with different id.booleanCheck whether two objects are equals, but do not compare the id fields.longgetId()Get id of this Spatial objectbooleanisNull()Test whether this object has no valuefloatmax(int dim) Get the maximum value for the given dimension.floatmin(int dim) Get the minimum value for the given dimension.voidsetMax(int dim, float x) Set the maximum value for the given dimension.voidsetMin(int dim, float x) Set the minimum value for the given dimension.
-
Field Details
-
id
private final long id -
minMax
private final float[] minMax
-
-
Constructor Details
-
DefaultSpatial
public DefaultSpatial(long id, float... minMax) Create a new key.- Parameters:
id- the idminMax- min x, max x, min y, max y, and so on
-
DefaultSpatial
-
-
Method Details
-
min
public float min(int dim) Description copied from interface:SpatialGet the minimum value for the given dimension. -
setMin
public void setMin(int dim, float x) Description copied from interface:SpatialSet the minimum value for the given dimension. -
max
public float max(int dim) Description copied from interface:SpatialGet the maximum value for the given dimension. -
setMax
public void setMax(int dim, float x) Description copied from interface:SpatialSet the maximum value for the given dimension. -
clone
Description copied from interface:SpatialCreates a copy of this Spatial object with different id. -
getId
public long getId()Description copied from interface:SpatialGet id of this Spatial object -
isNull
public boolean isNull()Description copied from interface:SpatialTest whether this object has no value -
equalsIgnoringId
Description copied from interface:SpatialCheck whether two objects are equals, but do not compare the id fields.- Specified by:
equalsIgnoringIdin interfaceSpatial- Parameters:
o- the other key- Returns:
- true if the contents are the same
-