Uses of Class
com.google.common.geometry.S2ShapeIndex
-
Uses of S2ShapeIndex in com.google.common.geometry
Subclasses of S2ShapeIndex in com.google.common.geometryFields in com.google.common.geometry declared as S2ShapeIndexModifier and TypeFieldDescriptionprivate final S2ShapeIndexS2EdgeQuery.index(package private) S2ShapeIndexS2Loop.indexSpatial index for this loop.(package private) S2ShapeIndexS2Polygon.indexThe spatial index for this S2Polygon.Methods in com.google.common.geometry that return S2ShapeIndexModifier and TypeMethodDescriptionS2ShapeIndexCoder.decode(PrimitiveArrays.Bytes data, PrimitiveArrays.Cursor cursor) S2Polygon.index()Returns the index of this polygon.static S2ShapeIndexAs above, but does not CHECK-fail on invalid input.static S2ShapeIndexS2TextFormat.makeIndexOrDie(String str) Returns a S2ShapeIndex containing the points, polylines, and loops (in the form of a single polygon) described by the following format:Methods in com.google.common.geometry with parameters of type S2ShapeIndexModifier and TypeMethodDescriptionstatic doubleS2ShapeIndexMeasures.area(S2ShapeIndex shapeIndex) Returns the total area of all polygons in shapeIndex.static voidS2Polygon.breakEdgesAndAddToBuilder(S2ShapeIndex index, S2PolygonBuilder builder) Takes a set of possibly intersecting edges, stored in the S2ShapeIndex, and breaks the edges into small pieces so that there is no intersection anymore, and adds all these edges to the builder.static S2PointS2ShapeIndexMeasures.centroid(S2ShapeIndex shapeIndex) Returns the centroid of all shapes whose dimension is maximal within shapeIndex, multiplied by the measure of those shapes.static intS2ShapeIndexMeasures.dimension(S2ShapeIndex shapeIndex) Returns the maximum dimension of any shape in shapeIndex, or -1 if shapeIndex has no shapes.voidS2ShapeIndexCoder.encode(S2ShapeIndex value, OutputStream output) static booleanS2ShapeUtil.equals(S2ShapeIndex a, S2ShapeIndex b) Returns true if all methods of the two S2ShapeIndex values return identical results, including all the S2Shapes in both indexes.(package private) static booleanS2ShapeUtil.findAnyCrossing(S2ShapeIndex index, List<S2Loop> loops, S2Error error) Given an S2ShapeIndex containing a set of loops, return true if any loop has a self-intersection (including duplicate vertices) or crosses any other loop (including vertex crossings and duplicate edges) and set "error" to a human-readable error message.(package private) static booleanS2ShapeUtil.findSelfIntersection(S2ShapeIndex index, S2Loop loop, S2Error error) Given an S2ShapeIndex containing a single loop, return true if the loop has a self-intersection (including duplicate vertices) and set "error" to a human-readable error message.static S1AngleS2ShapeIndexMeasures.length(S2ShapeIndex shapeIndex) Returns the total length of all polylines in shapeIndex, orS1Angle.ZEROif shapeIndex contains no polylines.static S1AngleS2ShapeIndexMeasures.perimeter(S2ShapeIndex shapeIndex) Returns the total perimeter of all polygons in shapeIndex (including both "shells" and "holes"), orS1Angle.ZEROshapeIndex contains no polygons.S2ShapeUtil.shapeToShapeId(S2ShapeIndex index) Returns a multimap ofS2Shapefromindexto the shape's ID (i.e., its position withinindex.shapes).static StringS2TextFormat.toString(S2ShapeIndex index) Convert an S2CellUnion to the S2TextFormat string representation documented above.Constructors in com.google.common.geometry with parameters of type S2ShapeIndexModifierConstructorDescriptionEdgeClipper(S2ShapeIndex index, boolean addSharedEdges, com.google.common.base.Predicate<S2Shape> reverseEdges) Initialize an EdgeClipper for the given S2ShapeIndex.RangeIterator(S2ShapeIndex index) S2ContainsPointQuery(S2ShapeIndex index) Constructs a semi-open contains-point query from the given iterator.S2ContainsPointQuery(S2ShapeIndex index, S2ContainsPointQuery.Options options) Constructs a contains-point query from the given iterator, with the specified options.S2EdgeQuery(S2ShapeIndex index) Constructor from anS2ShapeIndex.S2ShapeIndexRegion(S2ShapeIndex index) Creates a new region with the given index, and asemi-openvertex model.S2ShapeIndexRegion(S2ShapeIndex index, S2ContainsPointQuery.S2VertexModel model) Creates a new region with the given index, and a givenS2ContainsPointQuery.S2VertexModel.