Class QuadPrefixTree.QuadCell
java.lang.Object
org.apache.lucene.spatial.prefix.tree.LegacyCell
org.apache.lucene.spatial.prefix.tree.QuadPrefixTree.QuadCell
- All Implemented Interfaces:
Cell,CellCanPrune
- Direct Known Subclasses:
PackedQuadPrefixTree.PackedQuadCell
- Enclosing class:
QuadPrefixTree
individual QuadPrefixTree grid cell
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected BytesRefprotected QuadPrefixTreegetGrid()protected intorg.locationtech.spatial4j.shape.ShapegetShape()Gets the shape for this cell; typically a Rectangle.protected QuadPrefixTree.QuadCellgetSubCell(org.locationtech.spatial4j.shape.Point p) Performant implementations are expected to implement this efficiently by considering the current cell's boundary.protected Collection<Cell> Gets the cells at the next grid cell level that covers this cell.intReturns the number of children for this cell.protected org.locationtech.spatial4j.shape.RectangleMethods inherited from class org.apache.lucene.spatial.prefix.tree.LegacyCell
compare, compareToNoLeaf, equals, getLevel, getNextLevelCells, getShapeRel, getTokenBytesNoLeaf, getTokenBytesWithLeaf, hashCode, isLeaf, isPrefixOf, readCell, readLeafAdjust, setLeaf, setShapeRel, toString
-
Method Details
-
getGrid
- Specified by:
getGridin classLegacyCell
-
getMaxLevels
protected int getMaxLevels()- Specified by:
getMaxLevelsin classLegacyCell
-
getSubCells
Description copied from class:LegacyCellGets the cells at the next grid cell level that covers this cell. Precondition: Never called when getLevel() == maxLevel.- Specified by:
getSubCellsin classLegacyCell- Returns:
- A set of cells (no dups), sorted, modifiable, not empty, not null.
-
concat
-
getSubCellsSize
public int getSubCellsSize()Description copied from interface:CellCanPruneReturns the number of children for this cell.- Returns:
- the number of children.
-
getSubCell
Description copied from class:LegacyCellPerformant implementations are expected to implement this efficiently by considering the current cell's boundary.- Precondition: Never called when getLevel() == maxLevel.
- Precondition: this.getShape().relate(p) != DISJOINT.
- Specified by:
getSubCellin classLegacyCell
-
getShape
public org.locationtech.spatial4j.shape.Shape getShape()Description copied from interface:CellGets the shape for this cell; typically a Rectangle. -
makeShape
protected org.locationtech.spatial4j.shape.Rectangle makeShape()
-