id
int32
0
165k
repo
stringlengths
7
58
path
stringlengths
12
218
func_name
stringlengths
3
140
original_string
stringlengths
73
34.1k
language
stringclasses
1 value
code
stringlengths
73
34.1k
code_tokens
list
docstring
stringlengths
3
16k
docstring_tokens
list
sha
stringlengths
40
40
url
stringlengths
105
339
112,000
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.setRemainingPredicatesToFalse_
private void setRemainingPredicatesToFalse_() { for (int i = 0; i < 9; i++) { if (m_perform_predicates[i] && m_matrix[i] == -2) { m_matrix[i] = -1; m_perform_predicates[i] = false; } } }
java
private void setRemainingPredicatesToFalse_() { for (int i = 0; i < 9; i++) { if (m_perform_predicates[i] && m_matrix[i] == -2) { m_matrix[i] = -1; m_perform_predicates[i] = false; } } }
[ "private", "void", "setRemainingPredicatesToFalse_", "(", ")", "{", "for", "(", "int", "i", "=", "0", ";", "i", "<", "9", ";", "i", "++", ")", "{", "if", "(", "m_perform_predicates", "[", "i", "]", "&&", "m_matrix", "[", "i", "]", "==", "-", "2", ...
Sets the remaining predicates to false
[ "Sets", "the", "remaining", "predicates", "to", "false" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1373-L1380
112,001
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.isPredicateKnown_
private boolean isPredicateKnown_(int predicate) { assert(m_scl.charAt(predicate) != '*'); if (m_matrix[predicate] == -2) return false; if (m_matrix[predicate] == -1) { m_perform_predicates[predicate] = false; m_predicate_count--; return ...
java
private boolean isPredicateKnown_(int predicate) { assert(m_scl.charAt(predicate) != '*'); if (m_matrix[predicate] == -2) return false; if (m_matrix[predicate] == -1) { m_perform_predicates[predicate] = false; m_predicate_count--; return ...
[ "private", "boolean", "isPredicateKnown_", "(", "int", "predicate", ")", "{", "assert", "(", "m_scl", ".", "charAt", "(", "predicate", ")", "!=", "'", "'", ")", ";", "if", "(", "m_matrix", "[", "predicate", "]", "==", "-", "2", ")", "return", "false", ...
Checks whether the predicate is known.
[ "Checks", "whether", "the", "predicate", "is", "known", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1383-L1415
112,002
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.setAreaAreaPredicates_
private void setAreaAreaPredicates_() { m_predicates_half_edge = Predicates.AreaAreaPredicates; m_max_dim[MatrixPredicate.InteriorInterior] = 2; m_max_dim[MatrixPredicate.InteriorBoundary] = 1; m_max_dim[MatrixPredicate.InteriorExterior] = 2; m_max_dim[MatrixPredicate.BoundaryIn...
java
private void setAreaAreaPredicates_() { m_predicates_half_edge = Predicates.AreaAreaPredicates; m_max_dim[MatrixPredicate.InteriorInterior] = 2; m_max_dim[MatrixPredicate.InteriorBoundary] = 1; m_max_dim[MatrixPredicate.InteriorExterior] = 2; m_max_dim[MatrixPredicate.BoundaryIn...
[ "private", "void", "setAreaAreaPredicates_", "(", ")", "{", "m_predicates_half_edge", "=", "Predicates", ".", "AreaAreaPredicates", ";", "m_max_dim", "[", "MatrixPredicate", ".", "InteriorInterior", "]", "=", "2", ";", "m_max_dim", "[", "MatrixPredicate", ".", "Inte...
Sets the area-area predicates function.
[ "Sets", "the", "area", "-", "area", "predicates", "function", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1418-L1438
112,003
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.setAreaLinePredicates_
private void setAreaLinePredicates_() { m_predicates_half_edge = Predicates.AreaLinePredicates; m_predicates_cluster = Predicates.AreaPointPredicates; m_max_dim[MatrixPredicate.InteriorInterior] = 1; m_max_dim[MatrixPredicate.InteriorBoundary] = 0; m_max_dim[MatrixPredicate.Inte...
java
private void setAreaLinePredicates_() { m_predicates_half_edge = Predicates.AreaLinePredicates; m_predicates_cluster = Predicates.AreaPointPredicates; m_max_dim[MatrixPredicate.InteriorInterior] = 1; m_max_dim[MatrixPredicate.InteriorBoundary] = 0; m_max_dim[MatrixPredicate.Inte...
[ "private", "void", "setAreaLinePredicates_", "(", ")", "{", "m_predicates_half_edge", "=", "Predicates", ".", "AreaLinePredicates", ";", "m_predicates_cluster", "=", "Predicates", ".", "AreaPointPredicates", ";", "m_max_dim", "[", "MatrixPredicate", ".", "InteriorInterior...
Sets the area-line predicate function.
[ "Sets", "the", "area", "-", "line", "predicate", "function", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1441-L1461
112,004
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.setLineLinePredicates_
private void setLineLinePredicates_() { m_predicates_half_edge = Predicates.LineLinePredicates; m_predicates_cluster = Predicates.LinePointPredicates; m_max_dim[MatrixPredicate.InteriorInterior] = 1; m_max_dim[MatrixPredicate.InteriorBoundary] = 0; m_max_dim[MatrixPredicate.Inte...
java
private void setLineLinePredicates_() { m_predicates_half_edge = Predicates.LineLinePredicates; m_predicates_cluster = Predicates.LinePointPredicates; m_max_dim[MatrixPredicate.InteriorInterior] = 1; m_max_dim[MatrixPredicate.InteriorBoundary] = 0; m_max_dim[MatrixPredicate.Inte...
[ "private", "void", "setLineLinePredicates_", "(", ")", "{", "m_predicates_half_edge", "=", "Predicates", ".", "LineLinePredicates", ";", "m_predicates_cluster", "=", "Predicates", ".", "LinePointPredicates", ";", "m_max_dim", "[", "MatrixPredicate", ".", "InteriorInterior...
Sets the line-line predicates function.
[ "Sets", "the", "line", "-", "line", "predicates", "function", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1464-L1485
112,005
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.setAreaPointPredicates_
private void setAreaPointPredicates_() { m_predicates_cluster = Predicates.AreaPointPredicates; m_max_dim[MatrixPredicate.InteriorInterior] = 0; m_max_dim[MatrixPredicate.InteriorBoundary] = -1; m_max_dim[MatrixPredicate.InteriorExterior] = 2; m_max_dim[MatrixPredicate.BoundaryI...
java
private void setAreaPointPredicates_() { m_predicates_cluster = Predicates.AreaPointPredicates; m_max_dim[MatrixPredicate.InteriorInterior] = 0; m_max_dim[MatrixPredicate.InteriorBoundary] = -1; m_max_dim[MatrixPredicate.InteriorExterior] = 2; m_max_dim[MatrixPredicate.BoundaryI...
[ "private", "void", "setAreaPointPredicates_", "(", ")", "{", "m_predicates_cluster", "=", "Predicates", ".", "AreaPointPredicates", ";", "m_max_dim", "[", "MatrixPredicate", ".", "InteriorInterior", "]", "=", "0", ";", "m_max_dim", "[", "MatrixPredicate", ".", "Inte...
Sets the area-point predicate function.
[ "Sets", "the", "area", "-", "point", "predicate", "function", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1488-L1529
112,006
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.areaAreaPredicates_
private boolean areaAreaPredicates_(int half_edge, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorAreaInteriorArea_(half_edge, id_a, id_b); bRelationKnown &= isPredicateKnown_( MatrixPredicate.InteriorInterior); } if (m_per...
java
private boolean areaAreaPredicates_(int half_edge, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorAreaInteriorArea_(half_edge, id_a, id_b); bRelationKnown &= isPredicateKnown_( MatrixPredicate.InteriorInterior); } if (m_per...
[ "private", "boolean", "areaAreaPredicates_", "(", "int", "half_edge", ",", "int", "id_a", ",", "int", "id_b", ")", "{", "boolean", "bRelationKnown", "=", "true", ";", "if", "(", "m_perform_predicates", "[", "MatrixPredicate", ".", "InteriorInterior", "]", ")", ...
Invokes the 9 relational predicates of area vs area.
[ "Invokes", "the", "9", "relational", "predicates", "of", "area", "vs", "area", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1634-L1692
112,007
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.areaLinePredicates_
private boolean areaLinePredicates_(int half_edge, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorAreaInteriorLine_(half_edge, id_a, id_b); bRelationKnown &= isPredicateKnown_(MatrixPredicate.Int...
java
private boolean areaLinePredicates_(int half_edge, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorAreaInteriorLine_(half_edge, id_a, id_b); bRelationKnown &= isPredicateKnown_(MatrixPredicate.Int...
[ "private", "boolean", "areaLinePredicates_", "(", "int", "half_edge", ",", "int", "id_a", ",", "int", "id_b", ")", "{", "boolean", "bRelationKnown", "=", "true", ";", "if", "(", "m_perform_predicates", "[", "MatrixPredicate", ".", "InteriorInterior", "]", ")", ...
Invokes the 9 relational predicates of area vs Line.
[ "Invokes", "the", "9", "relational", "predicates", "of", "area", "vs", "Line", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1871-L1923
112,008
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.lineLinePredicates_
private boolean lineLinePredicates_(int half_edge, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorLineInteriorLine_(half_edge, id_a, id_b, m_cluster_index_a, m_cluster_index_b); bRelationKnown &=...
java
private boolean lineLinePredicates_(int half_edge, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorLineInteriorLine_(half_edge, id_a, id_b, m_cluster_index_a, m_cluster_index_b); bRelationKnown &=...
[ "private", "boolean", "lineLinePredicates_", "(", "int", "half_edge", ",", "int", "id_a", ",", "int", "id_b", ")", "{", "boolean", "bRelationKnown", "=", "true", ";", "if", "(", "m_perform_predicates", "[", "MatrixPredicate", ".", "InteriorInterior", "]", ")", ...
Invokes the 9 relational predicates of Line vs Line.
[ "Invokes", "the", "9", "relational", "predicates", "of", "Line", "vs", "Line", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1926-L1978
112,009
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.areaPointPredicates_
private boolean areaPointPredicates_(int cluster, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorAreaInteriorPoint_(cluster, id_a); bRelationKnown &= isPredicateKnown_(MatrixPredicate.InteriorInt...
java
private boolean areaPointPredicates_(int cluster, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorAreaInteriorPoint_(cluster, id_a); bRelationKnown &= isPredicateKnown_(MatrixPredicate.InteriorInt...
[ "private", "boolean", "areaPointPredicates_", "(", "int", "cluster", ",", "int", "id_a", ",", "int", "id_b", ")", "{", "boolean", "bRelationKnown", "=", "true", ";", "if", "(", "m_perform_predicates", "[", "MatrixPredicate", ".", "InteriorInterior", "]", ")", ...
Invokes the 9 relational predicates of area vs Point.
[ "Invokes", "the", "9", "relational", "predicates", "of", "area", "vs", "Point", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L1981-L2015
112,010
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.linePointPredicates_
private boolean linePointPredicates_(int cluster, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorLineInteriorPoint_(cluster, id_a, id_b, m_cluster_index_a); bRelationKnown &= isPredicateKnown_(Ma...
java
private boolean linePointPredicates_(int cluster, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorLineInteriorPoint_(cluster, id_a, id_b, m_cluster_index_a); bRelationKnown &= isPredicateKnown_(Ma...
[ "private", "boolean", "linePointPredicates_", "(", "int", "cluster", ",", "int", "id_a", ",", "int", "id_b", ")", "{", "boolean", "bRelationKnown", "=", "true", ";", "if", "(", "m_perform_predicates", "[", "MatrixPredicate", ".", "InteriorInterior", "]", ")", ...
Invokes the 9 relational predicates of Line vs Point.
[ "Invokes", "the", "9", "relational", "predicates", "of", "Line", "vs", "Point", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L2018-L2052
112,011
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.pointPointPredicates_
private boolean pointPointPredicates_(int cluster, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorPointInteriorPoint_(cluster, id_a, id_b); bRelationKnown &= isPredicateKnown_(MatrixPredicate.Int...
java
private boolean pointPointPredicates_(int cluster, int id_a, int id_b) { boolean bRelationKnown = true; if (m_perform_predicates[MatrixPredicate.InteriorInterior]) { interiorPointInteriorPoint_(cluster, id_a, id_b); bRelationKnown &= isPredicateKnown_(MatrixPredicate.Int...
[ "private", "boolean", "pointPointPredicates_", "(", "int", "cluster", ",", "int", "id_a", ",", "int", "id_b", ")", "{", "boolean", "bRelationKnown", "=", "true", ";", "if", "(", "m_perform_predicates", "[", "MatrixPredicate", ".", "InteriorInterior", "]", ")", ...
Invokes the 9 relational predicates of Point vs Point.
[ "Invokes", "the", "9", "relational", "predicates", "of", "Point", "vs", "Point", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L2055-L2077
112,012
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.interiorAreaInteriorArea_
private void interiorAreaInteriorArea_(int half_edge, int id_a, int id_b) { if (m_matrix[MatrixPredicate.InteriorInterior] == 2) return; int faceParentage = m_topo_graph.getHalfEdgeFaceParentage(half_edge); if ((faceParentage & id_a) != 0 && (faceParentage & id_b) != 0) m_matrix[MatrixPredicate.InteriorIn...
java
private void interiorAreaInteriorArea_(int half_edge, int id_a, int id_b) { if (m_matrix[MatrixPredicate.InteriorInterior] == 2) return; int faceParentage = m_topo_graph.getHalfEdgeFaceParentage(half_edge); if ((faceParentage & id_a) != 0 && (faceParentage & id_b) != 0) m_matrix[MatrixPredicate.InteriorIn...
[ "private", "void", "interiorAreaInteriorArea_", "(", "int", "half_edge", ",", "int", "id_a", ",", "int", "id_b", ")", "{", "if", "(", "m_matrix", "[", "MatrixPredicate", ".", "InteriorInterior", "]", "==", "2", ")", "return", ";", "int", "faceParentage", "="...
with the interior of area B.
[ "with", "the", "interior", "of", "area", "B", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L2081-L2089
112,013
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java
RelationalOperationsMatrix.convertGeometry_
private static Geometry convertGeometry_(Geometry geometry, double tolerance) { int gt = geometry.getType().value(); if (Geometry.isSegment(gt)) { Polyline polyline = new Polyline(geometry.getDescription()); polyline.addSegment((Segment) geometry, true); return polyline; } if (gt == Geometry.Geometry...
java
private static Geometry convertGeometry_(Geometry geometry, double tolerance) { int gt = geometry.getType().value(); if (Geometry.isSegment(gt)) { Polyline polyline = new Polyline(geometry.getDescription()); polyline.addSegment((Segment) geometry, true); return polyline; } if (gt == Geometry.Geometry...
[ "private", "static", "Geometry", "convertGeometry_", "(", "Geometry", "geometry", ",", "double", "tolerance", ")", "{", "int", "gt", "=", "geometry", ".", "getType", "(", ")", ".", "value", "(", ")", ";", "if", "(", "Geometry", ".", "isSegment", "(", "gt...
Upgrades the geometry to a feature geometry.
[ "Upgrades", "the", "geometry", "to", "a", "feature", "geometry", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/RelationalOperationsMatrix.java#L2834-L2875
112,014
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/GeoDist.java
GeoDist.PE_EQ
static private boolean PE_EQ(double a, double b) { return (a == b) || PE_ABS(a - b) <= PE_EPS * (1 + (PE_ABS(a) + PE_ABS(b)) / 2); }
java
static private boolean PE_EQ(double a, double b) { return (a == b) || PE_ABS(a - b) <= PE_EPS * (1 + (PE_ABS(a) + PE_ABS(b)) / 2); }
[ "static", "private", "boolean", "PE_EQ", "(", "double", "a", ",", "double", "b", ")", "{", "return", "(", "a", "==", "b", ")", "||", "PE_ABS", "(", "a", "-", "b", ")", "<=", "PE_EPS", "*", "(", "1", "+", "(", "PE_ABS", "(", "a", ")", "+", "PE...
Determine if two doubles are equal within a default tolerance
[ "Determine", "if", "two", "doubles", "are", "equal", "within", "a", "default", "tolerance" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/GeoDist.java#L46-L49
112,015
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/ConstructOffset.java
ConstructOffset.addPoint
void addPoint(GraphicPoint offPt, int i_src) { if (m_offsetPtCount == 0) // TODO: can we have this outside of this // method? { addPoint(offPt); return; } int n_src = m_srcPtCount; GraphicPoint pt1, pt; pt1 = m_srcPts.get(i_src == 0 ? n_src - 1 : i_src - 1); pt = m_srcPts.get(i_src); //...
java
void addPoint(GraphicPoint offPt, int i_src) { if (m_offsetPtCount == 0) // TODO: can we have this outside of this // method? { addPoint(offPt); return; } int n_src = m_srcPtCount; GraphicPoint pt1, pt; pt1 = m_srcPts.get(i_src == 0 ? n_src - 1 : i_src - 1); pt = m_srcPts.get(i_src); //...
[ "void", "addPoint", "(", "GraphicPoint", "offPt", ",", "int", "i_src", ")", "{", "if", "(", "m_offsetPtCount", "==", "0", ")", "// TODO: can we have this outside of this", "// method?", "{", "addPoint", "(", "offPt", ")", ";", "return", ";", "}", "int", "n_src...
this situation is handled here by adding an additional "bad" segment
[ "this", "situation", "is", "handled", "here", "by", "adding", "an", "additional", "bad", "segment" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/ConstructOffset.java#L191-L293
112,016
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/ConstructOffset.java
ConstructOffset.compressOffsetArray
void compressOffsetArray(int i0) { int i_ = i0; while (m_offsetPts.get(i_).m_prev < i_) i_ = m_offsetPts.get(i_).m_prev; int j = 0, i = i_; do { GraphicPoint pt = m_offsetPts.get(i); m_offsetPts.set(j, pt); i = pt.m_next; j++; } while (i != i_); m_offsetPts.set(j, m_offsetPts.get(0)); // d...
java
void compressOffsetArray(int i0) { int i_ = i0; while (m_offsetPts.get(i_).m_prev < i_) i_ = m_offsetPts.get(i_).m_prev; int j = 0, i = i_; do { GraphicPoint pt = m_offsetPts.get(i); m_offsetPts.set(j, pt); i = pt.m_next; j++; } while (i != i_); m_offsetPts.set(j, m_offsetPts.get(0)); // d...
[ "void", "compressOffsetArray", "(", "int", "i0", ")", "{", "int", "i_", "=", "i0", ";", "while", "(", "m_offsetPts", ".", "get", "(", "i_", ")", ".", "m_prev", "<", "i_", ")", "i_", "=", "m_offsetPts", ".", "get", "(", "i_", ")", ".", "m_prev", "...
is, its the index of a point that isn't part of a deleted loop
[ "is", "its", "the", "index", "of", "a", "point", "that", "isn", "t", "part", "of", "a", "deleted", "loop" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/ConstructOffset.java#L944-L961
112,017
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point2D.java
Point2D.compare
public int compare(Point2D other) { return y < other.y ? -1 : (y > other.y ? 1 : (x < other.x ? -1 : (x > other.x ? 1 : 0))); }
java
public int compare(Point2D other) { return y < other.y ? -1 : (y > other.y ? 1 : (x < other.x ? -1 : (x > other.x ? 1 : 0))); }
[ "public", "int", "compare", "(", "Point2D", "other", ")", "{", "return", "y", "<", "other", ".", "y", "?", "-", "1", ":", "(", "y", ">", "other", ".", "y", "?", "1", ":", "(", "x", "<", "other", ".", "x", "?", "-", "1", ":", "(", "x", ">"...
Compares two vertices lexicographically by y.
[ "Compares", "two", "vertices", "lexicographically", "by", "y", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point2D.java#L170-L173
112,018
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point2D.java
Point2D.compareX
int compareX(Point2D other) { return x < other.x ? -1 : (x > other.x ? 1 : (y < other.y ? -1 : (y > other.y ? 1 : 0))); }
java
int compareX(Point2D other) { return x < other.x ? -1 : (x > other.x ? 1 : (y < other.y ? -1 : (y > other.y ? 1 : 0))); }
[ "int", "compareX", "(", "Point2D", "other", ")", "{", "return", "x", "<", "other", ".", "x", "?", "-", "1", ":", "(", "x", ">", "other", ".", "x", "?", "1", ":", "(", "y", "<", "other", ".", "y", "?", "-", "1", ":", "(", "y", ">", "other"...
Compares two vertices lexicographically by x.
[ "Compares", "two", "vertices", "lexicographically", "by", "x", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point2D.java#L177-L180
112,019
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point2D.java
Point2D._norm
double _norm(int metric) { if (metric < 0 || _isNan()) return NumberUtils.NaN(); switch (metric) { case 0: // L-infinite return Math.abs(x) >= Math.abs(y) ? Math.abs(x) : Math.abs(y); case 1: // L1 or Manhattan metric return Math.abs(x) + Math.abs(y); case 2: // L2 or Euclidean metric return Ma...
java
double _norm(int metric) { if (metric < 0 || _isNan()) return NumberUtils.NaN(); switch (metric) { case 0: // L-infinite return Math.abs(x) >= Math.abs(y) ? Math.abs(x) : Math.abs(y); case 1: // L1 or Manhattan metric return Math.abs(x) + Math.abs(y); case 2: // L2 or Euclidean metric return Ma...
[ "double", "_norm", "(", "int", "metric", ")", "{", "if", "(", "metric", "<", "0", "||", "_isNan", "(", ")", ")", "return", "NumberUtils", ".", "NaN", "(", ")", ";", "switch", "(", "metric", ")", "{", "case", "0", ":", "// L-infinite", "return", "Ma...
for predefined metrics, use the DistanceMetricEnum defined in WKSPoint.h
[ "for", "predefined", "metrics", "use", "the", "DistanceMetricEnum", "defined", "in", "WKSPoint", ".", "h" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point2D.java#L393-L413
112,020
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point2D.java
Point2D.orientationRobust
public static int orientationRobust(Point2D p, Point2D q, Point2D r) { ECoordinate det_ec = new ECoordinate(); det_ec.set(q.x); det_ec.sub(p.x); ECoordinate rp_y_ec = new ECoordinate(); rp_y_ec.set(r.y); rp_y_ec.sub(p.y); ECoordinate qp_y_ec = new ECoordinate(); qp_y_ec.set(q.y); qp_y_ec.sub(p.y); ...
java
public static int orientationRobust(Point2D p, Point2D q, Point2D r) { ECoordinate det_ec = new ECoordinate(); det_ec.set(q.x); det_ec.sub(p.x); ECoordinate rp_y_ec = new ECoordinate(); rp_y_ec.set(r.y); rp_y_ec.sub(p.y); ECoordinate qp_y_ec = new ECoordinate(); qp_y_ec.set(q.y); qp_y_ec.sub(p.y); ...
[ "public", "static", "int", "orientationRobust", "(", "Point2D", "p", ",", "Point2D", "q", ",", "Point2D", "r", ")", "{", "ECoordinate", "det_ec", "=", "new", "ECoordinate", "(", ")", ";", "det_ec", ".", "set", "(", "q", ".", "x", ")", ";", "det_ec", ...
Calculates the orientation of the triangle formed by p, q, r. Returns 1 for counter-clockwise, -1 for clockwise, and 0 for collinear. May use high precision arithmetics for some special degenerate cases.
[ "Calculates", "the", "orientation", "of", "the", "triangle", "formed", "by", "p", "q", "r", ".", "Returns", "1", "for", "counter", "-", "clockwise", "-", "1", "for", "clockwise", "and", "0", "for", "collinear", ".", "May", "use", "high", "precision", "ar...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point2D.java#L442-L496
112,021
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/ECoordinate.java
ECoordinate.log
void log(ECoordinate v) { double d = v.m_eps / v.m_value; m_value = Math.log(v.m_value); m_eps = d * (1.0 + 0.5 * d) + epsCoordinate() * Math.abs(m_value); }
java
void log(ECoordinate v) { double d = v.m_eps / v.m_value; m_value = Math.log(v.m_value); m_eps = d * (1.0 + 0.5 * d) + epsCoordinate() * Math.abs(m_value); }
[ "void", "log", "(", "ECoordinate", "v", ")", "{", "double", "d", "=", "v", ".", "m_eps", "/", "v", ".", "m_value", ";", "m_value", "=", "Math", ".", "log", "(", "v", ".", "m_value", ")", ";", "m_eps", "=", "d", "*", "(", "1.0", "+", "0.5", "*...
Calculates natural log of v and assigns to this coordinate
[ "Calculates", "natural", "log", "of", "v", "and", "assigns", "to", "this", "coordinate" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/ECoordinate.java#L291-L295
112,022
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/ECoordinate.java
ECoordinate.tolEq
boolean tolEq(ECoordinate v, double tolerance) // ! == with tolerance { return Math.abs(m_value - v.m_value) <= tolerance || eq(v); }
java
boolean tolEq(ECoordinate v, double tolerance) // ! == with tolerance { return Math.abs(m_value - v.m_value) <= tolerance || eq(v); }
[ "boolean", "tolEq", "(", "ECoordinate", "v", ",", "double", "tolerance", ")", "// ! == with tolerance", "{", "return", "Math", ".", "abs", "(", "m_value", "-", "v", ".", "m_value", ")", "<=", "tolerance", "||", "eq", "(", "v", ")", ";", "}" ]
user defined tolerance.
[ "user", "defined", "tolerance", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/ECoordinate.java#L336-L339
112,023
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/ConvexHull.java
ConvexHull.addGeometry
void addGeometry(Geometry geometry) { if (geometry.isEmpty()) return; int type = geometry.getType().value(); if (MultiVertexGeometry.isMultiVertex(type)) addMultiVertexGeometry_((MultiVertexGeometry) geometry); else if (MultiPath.isSegment(type)) addSegment_((Segment) geometry); else if (type == ...
java
void addGeometry(Geometry geometry) { if (geometry.isEmpty()) return; int type = geometry.getType().value(); if (MultiVertexGeometry.isMultiVertex(type)) addMultiVertexGeometry_((MultiVertexGeometry) geometry); else if (MultiPath.isSegment(type)) addSegment_((Segment) geometry); else if (type == ...
[ "void", "addGeometry", "(", "Geometry", "geometry", ")", "{", "if", "(", "geometry", ".", "isEmpty", "(", ")", ")", "return", ";", "int", "type", "=", "geometry", ".", "getType", "(", ")", ".", "value", "(", ")", ";", "if", "(", "MultiVertexGeometry", ...
Adds a geometry to the current bounding geometry using an incremental algorithm for dynamic insertion. @param geometry The geometry to add to the bounding geometry.
[ "Adds", "a", "geometry", "to", "the", "current", "bounding", "geometry", "using", "an", "incremental", "algorithm", "for", "dynamic", "insertion", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/ConvexHull.java#L58-L74
112,024
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/ConvexHull.java
ConvexHull.getBoundingGeometry
Geometry getBoundingGeometry() { // Extracts the convex hull from the tree. Reading the tree in order from first to last is the resulting convex hull. Point point = new Point(); int first = m_tree_hull.getFirst(-1); Polygon hull = new Polygon(m_shape.getVertexDescription()); if (m_tree_hull.size(-1) == 0) ...
java
Geometry getBoundingGeometry() { // Extracts the convex hull from the tree. Reading the tree in order from first to last is the resulting convex hull. Point point = new Point(); int first = m_tree_hull.getFirst(-1); Polygon hull = new Polygon(m_shape.getVertexDescription()); if (m_tree_hull.size(-1) == 0) ...
[ "Geometry", "getBoundingGeometry", "(", ")", "{", "// Extracts the convex hull from the tree. Reading the tree in order from first to last is the resulting convex hull.", "Point", "point", "=", "new", "Point", "(", ")", ";", "int", "first", "=", "m_tree_hull", ".", "getFirst", ...
Gets the current bounding geometry. Returns a Geometry.
[ "Gets", "the", "current", "bounding", "geometry", ".", "Returns", "a", "Geometry", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/ConvexHull.java#L81-L98
112,025
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/ConvexHull.java
ConvexHull.construct
static int construct(Point2D[] points, int count, int[] out_convex_hull) { ConvexHull convex_hull = new ConvexHull(points, count); int t0 = 0, tm = 1; Point2D pt_0 = points[t0]; while (tm < count && points[tm].isEqual(pt_0, NumberUtils.doubleEps())) tm++; // We don't want to close the gap between t0 and tm...
java
static int construct(Point2D[] points, int count, int[] out_convex_hull) { ConvexHull convex_hull = new ConvexHull(points, count); int t0 = 0, tm = 1; Point2D pt_0 = points[t0]; while (tm < count && points[tm].isEqual(pt_0, NumberUtils.doubleEps())) tm++; // We don't want to close the gap between t0 and tm...
[ "static", "int", "construct", "(", "Point2D", "[", "]", "points", ",", "int", "count", ",", "int", "[", "]", "out_convex_hull", ")", "{", "ConvexHull", "convex_hull", "=", "new", "ConvexHull", "(", "points", ",", "count", ")", ";", "int", "t0", "=", "0...
Static method to construct the convex hull from an array of points. The out_convex_hull array will be populated with the subset of index positions which contribute to the convex hull. Returns the number of points in the convex hull. \param points The points used to create the convex hull. \param count The number of poi...
[ "Static", "method", "to", "construct", "the", "convex", "hull", "from", "an", "array", "of", "points", ".", "The", "out_convex_hull", "array", "will", "be", "populated", "with", "the", "subset", "of", "index", "positions", "which", "contribute", "to", "the", ...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/ConvexHull.java#L220-L250
112,026
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/ConvexHull.java
ConvexHull.isPathConvex
static boolean isPathConvex(MultiPath multi_path, int path_index, ProgressTracker progress_tracker) { MultiPathImpl mimpl = (MultiPathImpl) multi_path._getImpl(); int path_start = mimpl.getPathStart(path_index); int path_end = mimpl.getPathEnd(path_index); boolean bxyclosed = !mimpl.isClosedPath(path_index) &&...
java
static boolean isPathConvex(MultiPath multi_path, int path_index, ProgressTracker progress_tracker) { MultiPathImpl mimpl = (MultiPathImpl) multi_path._getImpl(); int path_start = mimpl.getPathStart(path_index); int path_end = mimpl.getPathEnd(path_index); boolean bxyclosed = !mimpl.isClosedPath(path_index) &&...
[ "static", "boolean", "isPathConvex", "(", "MultiPath", "multi_path", ",", "int", "path_index", ",", "ProgressTracker", "progress_tracker", ")", "{", "MultiPathImpl", "mimpl", "=", "(", "MultiPathImpl", ")", "multi_path", ".", "_getImpl", "(", ")", ";", "int", "p...
Returns true if the given path of the input MultiPath is convex. Returns false otherwise. \param multi_path The MultiPath to check if the path is convex. \param path_index The path of the MultiPath to check if its convex.
[ "Returns", "true", "if", "the", "given", "path", "of", "the", "input", "MultiPath", "is", "convex", ".", "Returns", "false", "otherwise", ".", "\\", "param", "multi_path", "The", "MultiPath", "to", "check", "if", "the", "path", "is", "convex", ".", "\\", ...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/ConvexHull.java#L257-L321
112,027
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/ConvexHull.java
ConvexHull.addMultiVertexGeometry_
private void addMultiVertexGeometry_(MultiVertexGeometry mvg) { Point point = new Point(); Point2D pt_p = new Point2D(); for (int i = 0; i < mvg.getPointCount(); i++) { mvg.getXY(i, pt_p); int p = addPoint_(pt_p); if (p != -1) { mvg.getPointByVal(i, point); int tp = m_shape.addPoint(m_path_hand...
java
private void addMultiVertexGeometry_(MultiVertexGeometry mvg) { Point point = new Point(); Point2D pt_p = new Point2D(); for (int i = 0; i < mvg.getPointCount(); i++) { mvg.getXY(i, pt_p); int p = addPoint_(pt_p); if (p != -1) { mvg.getPointByVal(i, point); int tp = m_shape.addPoint(m_path_hand...
[ "private", "void", "addMultiVertexGeometry_", "(", "MultiVertexGeometry", "mvg", ")", "{", "Point", "point", "=", "new", "Point", "(", ")", ";", "Point2D", "pt_p", "=", "new", "Point2D", "(", ")", ";", "for", "(", "int", "i", "=", "0", ";", "i", "<", ...
Dynamically inserts each geometry into the convex hull.
[ "Dynamically", "inserts", "each", "geometry", "into", "the", "convex", "hull", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/ConvexHull.java#L324-L338
112,028
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point.java
Point.getXY
public final Point2D getXY() { if (isEmptyImpl()) throw new GeometryException( "This operation should not be performed on an empty geometry."); Point2D pt = new Point2D(); pt.setCoords(m_attributes[0], m_attributes[1]); return pt; }
java
public final Point2D getXY() { if (isEmptyImpl()) throw new GeometryException( "This operation should not be performed on an empty geometry."); Point2D pt = new Point2D(); pt.setCoords(m_attributes[0], m_attributes[1]); return pt; }
[ "public", "final", "Point2D", "getXY", "(", ")", "{", "if", "(", "isEmptyImpl", "(", ")", ")", "throw", "new", "GeometryException", "(", "\"This operation should not be performed on an empty geometry.\"", ")", ";", "Point2D", "pt", "=", "new", "Point2D", "(", ")",...
Returns XY coordinates of this point.
[ "Returns", "XY", "coordinates", "of", "this", "point", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point.java#L100-L108
112,029
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point.java
Point.getXYZ
public Point3D getXYZ() { if (isEmptyImpl()) throw new GeometryException( "This operation should not be performed on an empty geometry."); Point3D pt = new Point3D(); pt.x = m_attributes[0]; pt.y = m_attributes[1]; if (m_description.hasZ()) pt.z = m_attributes[2]; else pt.z = VertexDescriptio...
java
public Point3D getXYZ() { if (isEmptyImpl()) throw new GeometryException( "This operation should not be performed on an empty geometry."); Point3D pt = new Point3D(); pt.x = m_attributes[0]; pt.y = m_attributes[1]; if (m_description.hasZ()) pt.z = m_attributes[2]; else pt.z = VertexDescriptio...
[ "public", "Point3D", "getXYZ", "(", ")", "{", "if", "(", "isEmptyImpl", "(", ")", ")", "throw", "new", "GeometryException", "(", "\"This operation should not be performed on an empty geometry.\"", ")", ";", "Point3D", "pt", "=", "new", "Point3D", "(", ")", ";", ...
Returns XYZ coordinates of the point. Z will be set to 0 if Z is missing.
[ "Returns", "XYZ", "coordinates", "of", "the", "point", ".", "Z", "will", "be", "set", "to", "0", "if", "Z", "is", "missing", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point.java#L133-L147
112,030
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point.java
Point.setXYZ
public void setXYZ(Point3D pt) { _touch(); boolean bHasZ = hasAttribute(Semantics.Z); if (!bHasZ && !VertexDescription.isDefaultValue(Semantics.Z, pt.z)) {// add // Z // only // if // pt.z // is ...
java
public void setXYZ(Point3D pt) { _touch(); boolean bHasZ = hasAttribute(Semantics.Z); if (!bHasZ && !VertexDescription.isDefaultValue(Semantics.Z, pt.z)) {// add // Z // only // if // pt.z // is ...
[ "public", "void", "setXYZ", "(", "Point3D", "pt", ")", "{", "_touch", "(", ")", ";", "boolean", "bHasZ", "=", "hasAttribute", "(", "Semantics", ".", "Z", ")", ";", "if", "(", "!", "bHasZ", "&&", "!", "VertexDescription", ".", "isDefaultValue", "(", "Se...
Sets the XYZ coordinates of this point. @param pt The point to create the XYZ coordinate from.
[ "Sets", "the", "XYZ", "coordinates", "of", "this", "point", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point.java#L155-L179
112,031
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point.java
Point.getAttributeAsInt
public int getAttributeAsInt(int semantics, int ordinate) { if (isEmptyImpl()) throw new GeometryException( "This operation was performed on an Empty Geometry."); int ncomps = VertexDescription.getComponentCount(semantics); if (ordinate >= ncomps) throw new IndexOutOfBoundsException(); int attribut...
java
public int getAttributeAsInt(int semantics, int ordinate) { if (isEmptyImpl()) throw new GeometryException( "This operation was performed on an Empty Geometry."); int ncomps = VertexDescription.getComponentCount(semantics); if (ordinate >= ncomps) throw new IndexOutOfBoundsException(); int attribut...
[ "public", "int", "getAttributeAsInt", "(", "int", "semantics", ",", "int", "ordinate", ")", "{", "if", "(", "isEmptyImpl", "(", ")", ")", "throw", "new", "GeometryException", "(", "\"This operation was performed on an Empty Geometry.\"", ")", ";", "int", "ncomps", ...
Returns value of the given vertex attribute's ordinate. The ordinate is always 0 because integer attributes always have one component. @param semantics The attribute semantics. @param ordinate The attribute's ordinate. For example, the y coordinate of the NORMAL has ordinate of 1. @return The ordinate value truncated ...
[ "Returns", "value", "of", "the", "given", "vertex", "attribute", "s", "ordinate", ".", "The", "ordinate", "is", "always", "0", "because", "integer", "attributes", "always", "have", "one", "component", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point.java#L312-L327
112,032
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point.java
Point.setAttribute
public void setAttribute(int semantics, int ordinate, double value) { _touch(); int ncomps = VertexDescription.getComponentCount(semantics); if (ncomps < ordinate) throw new IndexOutOfBoundsException(); int attributeIndex = m_description.getAttributeIndex(semantics); if (attributeIndex < 0) { addAttrib...
java
public void setAttribute(int semantics, int ordinate, double value) { _touch(); int ncomps = VertexDescription.getComponentCount(semantics); if (ncomps < ordinate) throw new IndexOutOfBoundsException(); int attributeIndex = m_description.getAttributeIndex(semantics); if (attributeIndex < 0) { addAttrib...
[ "public", "void", "setAttribute", "(", "int", "semantics", ",", "int", "ordinate", ",", "double", "value", ")", "{", "_touch", "(", ")", ";", "int", "ncomps", "=", "VertexDescription", ".", "getComponentCount", "(", "semantics", ")", ";", "if", "(", "ncomp...
Sets the value of the attribute. @param semantics The attribute semantics. @param ordinate The ordinate of the attribute. @param value Is the array to write values to. The attribute type and the number of elements must match the persistence type, as well as the number of components of the attribute.
[ "Sets", "the", "value", "of", "the", "attribute", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point.java#L341-L358
112,033
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point.java
Point._setToDefault
void _setToDefault() { resizeAttributes(m_description.getTotalComponentCount()); Point.attributeCopy(m_description._getDefaultPointAttributes(), m_attributes, m_description.getTotalComponentCount()); m_attributes[0] = NumberUtils.NaN(); m_attributes[1] = NumberUtils.NaN(); }
java
void _setToDefault() { resizeAttributes(m_description.getTotalComponentCount()); Point.attributeCopy(m_description._getDefaultPointAttributes(), m_attributes, m_description.getTotalComponentCount()); m_attributes[0] = NumberUtils.NaN(); m_attributes[1] = NumberUtils.NaN(); }
[ "void", "_setToDefault", "(", ")", "{", "resizeAttributes", "(", "m_description", ".", "getTotalComponentCount", "(", ")", ")", ";", "Point", ".", "attributeCopy", "(", "m_description", ".", "_getDefaultPointAttributes", "(", ")", ",", "m_attributes", ",", "m_desc...
Sets the Point to a default, non-empty state.
[ "Sets", "the", "Point", "to", "a", "default", "non", "-", "empty", "state", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point.java#L433-L439
112,034
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Point.java
Point.setXY
public void setXY(double x, double y) { _touch(); if (m_attributes == null) _setToDefault(); m_attributes[0] = x; m_attributes[1] = y; }
java
public void setXY(double x, double y) { _touch(); if (m_attributes == null) _setToDefault(); m_attributes[0] = x; m_attributes[1] = y; }
[ "public", "void", "setXY", "(", "double", "x", ",", "double", "y", ")", "{", "_touch", "(", ")", ";", "if", "(", "m_attributes", "==", "null", ")", "_setToDefault", "(", ")", ";", "m_attributes", "[", "0", "]", "=", "x", ";", "m_attributes", "[", "...
Set the X and Y coordinate of the point. @param x X coordinate of the point. @param y Y coordinate of the point.
[ "Set", "the", "X", "and", "Y", "coordinate", "of", "the", "point", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Point.java#L572-L580
112,035
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.removeShape
void removeShape() { if (m_shape == null) return; if (m_geometryIDIndex != -1) { m_shape.removeGeometryUserIndex(m_geometryIDIndex); m_geometryIDIndex = -1; } if (m_clusterIndex != -1) { m_shape.removeUserIndex(m_clusterIndex); m_clusterIndex = -1; } if (m_halfEdgeIndex != -1) { m_shape...
java
void removeShape() { if (m_shape == null) return; if (m_geometryIDIndex != -1) { m_shape.removeGeometryUserIndex(m_geometryIDIndex); m_geometryIDIndex = -1; } if (m_clusterIndex != -1) { m_shape.removeUserIndex(m_clusterIndex); m_clusterIndex = -1; } if (m_halfEdgeIndex != -1) { m_shape...
[ "void", "removeShape", "(", ")", "{", "if", "(", "m_shape", "==", "null", ")", "return", ";", "if", "(", "m_geometryIDIndex", "!=", "-", "1", ")", "{", "m_shape", ".", "removeGeometryUserIndex", "(", "m_geometryIDIndex", ")", ";", "m_geometryIDIndex", "=", ...
the edit shape.
[ "the", "edit", "shape", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L1903-L1955
112,036
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.getXY
void getXY(int cluster, Point2D pt) { int vindex = getClusterVertexIndex_(cluster); m_shape.getXYWithIndex(vindex, pt); }
java
void getXY(int cluster, Point2D pt) { int vindex = getClusterVertexIndex_(cluster); m_shape.getXYWithIndex(vindex, pt); }
[ "void", "getXY", "(", "int", "cluster", ",", "Point2D", "pt", ")", "{", "int", "vindex", "=", "getClusterVertexIndex_", "(", "cluster", ")", ";", "m_shape", ".", "getXYWithIndex", "(", "vindex", ",", "pt", ")", ";", "}" ]
Returns the coordinates of the cluster
[ "Returns", "the", "coordinates", "of", "the", "cluster" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L1968-L1971
112,037
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.getClusterUserIndex
int getClusterUserIndex(int cluster, int index) { int i = getClusterIndex_(cluster); AttributeStreamOfInt32 stream = m_clusterIndices.get(index); if (stream.size() <= i) return -1; return stream.read(i); }
java
int getClusterUserIndex(int cluster, int index) { int i = getClusterIndex_(cluster); AttributeStreamOfInt32 stream = m_clusterIndices.get(index); if (stream.size() <= i) return -1; return stream.read(i); }
[ "int", "getClusterUserIndex", "(", "int", "cluster", ",", "int", "index", ")", "{", "int", "i", "=", "getClusterIndex_", "(", "cluster", ")", ";", "AttributeStreamOfInt32", "stream", "=", "m_clusterIndices", ".", "get", "(", "index", ")", ";", "if", "(", "...
Returns a user index value for the cluster.
[ "Returns", "a", "user", "index", "value", "for", "the", "cluster", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2018-L2024
112,038
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.setClusterUserIndex
void setClusterUserIndex(int cluster, int index, int value) { int i = getClusterIndex_(cluster); AttributeStreamOfInt32 stream = m_clusterIndices.get(index); if (stream.size() <= i) stream.resize(m_clusterData.size(), -1); stream.write(i, value); }
java
void setClusterUserIndex(int cluster, int index, int value) { int i = getClusterIndex_(cluster); AttributeStreamOfInt32 stream = m_clusterIndices.get(index); if (stream.size() <= i) stream.resize(m_clusterData.size(), -1); stream.write(i, value); }
[ "void", "setClusterUserIndex", "(", "int", "cluster", ",", "int", "index", ",", "int", "value", ")", "{", "int", "i", "=", "getClusterIndex_", "(", "cluster", ")", ";", "AttributeStreamOfInt32", "stream", "=", "m_clusterIndices", ".", "get", "(", "index", ")...
Sets a user index value for the cluster.
[ "Sets", "a", "user", "index", "value", "for", "the", "cluster", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2027-L2034
112,039
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.createUserIndexForClusters
int createUserIndexForClusters() { if (m_clusterIndices == null) { m_clusterIndices = new ArrayList<AttributeStreamOfInt32>(3); } AttributeStreamOfInt32 new_stream = new AttributeStreamOfInt32( m_clusterData.capacity(), -1); for (int i = 0, n = m_clusterIndices.size(); i < n; i++) { if (m_clusterIndi...
java
int createUserIndexForClusters() { if (m_clusterIndices == null) { m_clusterIndices = new ArrayList<AttributeStreamOfInt32>(3); } AttributeStreamOfInt32 new_stream = new AttributeStreamOfInt32( m_clusterData.capacity(), -1); for (int i = 0, n = m_clusterIndices.size(); i < n; i++) { if (m_clusterIndi...
[ "int", "createUserIndexForClusters", "(", ")", "{", "if", "(", "m_clusterIndices", "==", "null", ")", "{", "m_clusterIndices", "=", "new", "ArrayList", "<", "AttributeStreamOfInt32", ">", "(", "3", ")", ";", "}", "AttributeStreamOfInt32", "new_stream", "=", "new...
Creates a new user index for the cluster. The index values are set to -1.
[ "Creates", "a", "new", "user", "index", "for", "the", "cluster", ".", "The", "index", "values", "are", "set", "to", "-", "1", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2037-L2052
112,040
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.getHalfEdgeUserIndex
int getHalfEdgeUserIndex(int half_edge, int index) { int i = getHalfEdgeIndex_(half_edge); AttributeStreamOfInt32 stream = m_edgeIndices.get(index); if (stream.size() <= i) return -1; return stream.read(i); }
java
int getHalfEdgeUserIndex(int half_edge, int index) { int i = getHalfEdgeIndex_(half_edge); AttributeStreamOfInt32 stream = m_edgeIndices.get(index); if (stream.size() <= i) return -1; return stream.read(i); }
[ "int", "getHalfEdgeUserIndex", "(", "int", "half_edge", ",", "int", "index", ")", "{", "int", "i", "=", "getHalfEdgeIndex_", "(", "half_edge", ")", ";", "AttributeStreamOfInt32", "stream", "=", "m_edgeIndices", ".", "get", "(", "index", ")", ";", "if", "(", ...
Returns a user index value for the half edge
[ "Returns", "a", "user", "index", "value", "for", "the", "half", "edge" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2120-L2127
112,041
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.setHalfEdgeUserIndex
void setHalfEdgeUserIndex(int half_edge, int index, int value) { int i = getHalfEdgeIndex_(half_edge); AttributeStreamOfInt32 stream = m_edgeIndices.get(index); if (stream.size() <= i) stream.resize(m_halfEdgeData.size(), -1); stream.write(i, value); }
java
void setHalfEdgeUserIndex(int half_edge, int index, int value) { int i = getHalfEdgeIndex_(half_edge); AttributeStreamOfInt32 stream = m_edgeIndices.get(index); if (stream.size() <= i) stream.resize(m_halfEdgeData.size(), -1); stream.write(i, value); }
[ "void", "setHalfEdgeUserIndex", "(", "int", "half_edge", ",", "int", "index", ",", "int", "value", ")", "{", "int", "i", "=", "getHalfEdgeIndex_", "(", "half_edge", ")", ";", "AttributeStreamOfInt32", "stream", "=", "m_edgeIndices", ".", "get", "(", "index", ...
Sets a user index value for a half edge
[ "Sets", "a", "user", "index", "value", "for", "a", "half", "edge" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2130-L2137
112,042
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.createUserIndexForHalfEdges
int createUserIndexForHalfEdges() { if (m_edgeIndices == null) m_edgeIndices = new ArrayList<AttributeStreamOfInt32>(3); AttributeStreamOfInt32 new_stream = new AttributeStreamOfInt32( m_halfEdgeData.capacity(), -1); for (int i = 0, n = m_edgeIndices.size(); i < n; i++) { if (m_edgeIndices.get(i) == nu...
java
int createUserIndexForHalfEdges() { if (m_edgeIndices == null) m_edgeIndices = new ArrayList<AttributeStreamOfInt32>(3); AttributeStreamOfInt32 new_stream = new AttributeStreamOfInt32( m_halfEdgeData.capacity(), -1); for (int i = 0, n = m_edgeIndices.size(); i < n; i++) { if (m_edgeIndices.get(i) == nu...
[ "int", "createUserIndexForHalfEdges", "(", ")", "{", "if", "(", "m_edgeIndices", "==", "null", ")", "m_edgeIndices", "=", "new", "ArrayList", "<", "AttributeStreamOfInt32", ">", "(", "3", ")", ";", "AttributeStreamOfInt32", "new_stream", "=", "new", "AttributeStre...
create a new user index for half edges. The index values are set to -1.
[ "create", "a", "new", "user", "index", "for", "half", "edges", ".", "The", "index", "values", "are", "set", "to", "-", "1", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2140-L2154
112,043
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.deleteUserIndexForHalfEdges
void deleteUserIndexForHalfEdges(int userIndex) { assert (m_edgeIndices.get(userIndex) != null); m_edgeIndices.set(userIndex, null); }
java
void deleteUserIndexForHalfEdges(int userIndex) { assert (m_edgeIndices.get(userIndex) != null); m_edgeIndices.set(userIndex, null); }
[ "void", "deleteUserIndexForHalfEdges", "(", "int", "userIndex", ")", "{", "assert", "(", "m_edgeIndices", ".", "get", "(", "userIndex", ")", "!=", "null", ")", ";", "m_edgeIndices", ".", "set", "(", "userIndex", ",", "null", ")", ";", "}" ]
Deletes the given user index for half edges
[ "Deletes", "the", "given", "user", "index", "for", "half", "edges" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2157-L2160
112,044
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.deleteEdgeInternal_
int deleteEdgeInternal_(int half_edge) { int chain = getHalfEdgeChain(half_edge); int halfEdgeTwin = getHalfEdgeTwin(half_edge); int chainTwin = getHalfEdgeChain(halfEdgeTwin); // This function only works for spikes. These two asserts check for that assert (chainTwin == chain); assert (half_edge == getHalfE...
java
int deleteEdgeInternal_(int half_edge) { int chain = getHalfEdgeChain(half_edge); int halfEdgeTwin = getHalfEdgeTwin(half_edge); int chainTwin = getHalfEdgeChain(halfEdgeTwin); // This function only works for spikes. These two asserts check for that assert (chainTwin == chain); assert (half_edge == getHalfE...
[ "int", "deleteEdgeInternal_", "(", "int", "half_edge", ")", "{", "int", "chain", "=", "getHalfEdgeChain", "(", "half_edge", ")", ";", "int", "halfEdgeTwin", "=", "getHalfEdgeTwin", "(", "half_edge", ")", ";", "int", "chainTwin", "=", "getHalfEdgeChain", "(", "...
Use with care.
[ "Use", "with", "care", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2166-L2196
112,045
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.deleteEdgesBreakFaces_
void deleteEdgesBreakFaces_(AttributeStreamOfInt32 edgesToDelete) { for (int i = 0, n = edgesToDelete.size(); i < n; i++) { int half_edge = edgesToDelete.get(i); int chain = getHalfEdgeChain(half_edge); int halfEdgeTwin = getHalfEdgeTwin(half_edge); int chainTwin = getHalfEdgeChain(halfEdgeTwin); setCh...
java
void deleteEdgesBreakFaces_(AttributeStreamOfInt32 edgesToDelete) { for (int i = 0, n = edgesToDelete.size(); i < n; i++) { int half_edge = edgesToDelete.get(i); int chain = getHalfEdgeChain(half_edge); int halfEdgeTwin = getHalfEdgeTwin(half_edge); int chainTwin = getHalfEdgeChain(halfEdgeTwin); setCh...
[ "void", "deleteEdgesBreakFaces_", "(", "AttributeStreamOfInt32", "edgesToDelete", ")", "{", "for", "(", "int", "i", "=", "0", ",", "n", "=", "edgesToDelete", ".", "size", "(", ")", ";", "i", "<", "n", ";", "i", "++", ")", "{", "int", "half_edge", "=", ...
parentage information still.
[ "parentage", "information", "still", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2204-L2215
112,046
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.getChainArea
double getChainArea(int chain) { int chainIndex = getChainIndex_(chain); double v = m_chainAreas.read(chainIndex); if (NumberUtils.isNaN(v)) { updateChainAreaAndPerimeter_(chain); v = m_chainAreas.read(chainIndex); } return v; }
java
double getChainArea(int chain) { int chainIndex = getChainIndex_(chain); double v = m_chainAreas.read(chainIndex); if (NumberUtils.isNaN(v)) { updateChainAreaAndPerimeter_(chain); v = m_chainAreas.read(chainIndex); } return v; }
[ "double", "getChainArea", "(", "int", "chain", ")", "{", "int", "chainIndex", "=", "getChainIndex_", "(", "chain", ")", ";", "double", "v", "=", "m_chainAreas", ".", "read", "(", "chainIndex", ")", ";", "if", "(", "NumberUtils", ".", "isNaN", "(", "v", ...
+Inf is returned for the universe chain.
[ "+", "Inf", "is", "returned", "for", "the", "universe", "chain", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2369-L2378
112,047
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.getChainPerimeter
double getChainPerimeter(int chain) { int chainIndex = getChainIndex_(chain); double v = m_chainPerimeters.read(chainIndex); if (NumberUtils.isNaN(v)) { updateChainAreaAndPerimeter_(chain); v = m_chainPerimeters.read(chainIndex); } return v; }
java
double getChainPerimeter(int chain) { int chainIndex = getChainIndex_(chain); double v = m_chainPerimeters.read(chainIndex); if (NumberUtils.isNaN(v)) { updateChainAreaAndPerimeter_(chain); v = m_chainPerimeters.read(chainIndex); } return v; }
[ "double", "getChainPerimeter", "(", "int", "chain", ")", "{", "int", "chainIndex", "=", "getChainIndex_", "(", "chain", ")", ";", "double", "v", "=", "m_chainPerimeters", ".", "read", "(", "chainIndex", ")", ";", "if", "(", "NumberUtils", ".", "isNaN", "("...
universe chain.
[ "universe", "chain", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2382-L2391
112,048
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.getChainUserIndex
int getChainUserIndex(int chain, int index) { int i = getChainIndex_(chain); AttributeStreamOfInt32 stream = m_chainIndices.get(index); if (stream.size() <= i) return -1; return stream.read(i); }
java
int getChainUserIndex(int chain, int index) { int i = getChainIndex_(chain); AttributeStreamOfInt32 stream = m_chainIndices.get(index); if (stream.size() <= i) return -1; return stream.read(i); }
[ "int", "getChainUserIndex", "(", "int", "chain", ",", "int", "index", ")", "{", "int", "i", "=", "getChainIndex_", "(", "chain", ")", ";", "AttributeStreamOfInt32", "stream", "=", "m_chainIndices", ".", "get", "(", "index", ")", ";", "if", "(", "stream", ...
Returns a user index value for the chain.
[ "Returns", "a", "user", "index", "value", "for", "the", "chain", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2394-L2400
112,049
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.setChainUserIndex
void setChainUserIndex(int chain, int index, int value) { int i = getChainIndex_(chain); AttributeStreamOfInt32 stream = m_chainIndices.get(index); if (stream.size() <= i) stream.resize(m_chainData.size(), -1); stream.write(i, value); }
java
void setChainUserIndex(int chain, int index, int value) { int i = getChainIndex_(chain); AttributeStreamOfInt32 stream = m_chainIndices.get(index); if (stream.size() <= i) stream.resize(m_chainData.size(), -1); stream.write(i, value); }
[ "void", "setChainUserIndex", "(", "int", "chain", ",", "int", "index", ",", "int", "value", ")", "{", "int", "i", "=", "getChainIndex_", "(", "chain", ")", ";", "AttributeStreamOfInt32", "stream", "=", "m_chainIndices", ".", "get", "(", "index", ")", ";", ...
Sets a user index value for the chain.
[ "Sets", "a", "user", "index", "value", "for", "the", "chain", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2403-L2410
112,050
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.createUserIndexForChains
int createUserIndexForChains() { if (m_chainIndices == null) { m_chainIndices = new ArrayList<AttributeStreamOfInt32>(3); } AttributeStreamOfInt32 new_stream = new AttributeStreamOfInt32( m_chainData.capacity(), -1); for (int i = 0, n = m_chainIndices.size(); i < n; i++) { if (m_chainIndices.get(i) =...
java
int createUserIndexForChains() { if (m_chainIndices == null) { m_chainIndices = new ArrayList<AttributeStreamOfInt32>(3); } AttributeStreamOfInt32 new_stream = new AttributeStreamOfInt32( m_chainData.capacity(), -1); for (int i = 0, n = m_chainIndices.size(); i < n; i++) { if (m_chainIndices.get(i) =...
[ "int", "createUserIndexForChains", "(", ")", "{", "if", "(", "m_chainIndices", "==", "null", ")", "{", "m_chainIndices", "=", "new", "ArrayList", "<", "AttributeStreamOfInt32", ">", "(", "3", ")", ";", "}", "AttributeStreamOfInt32", "new_stream", "=", "new", "...
Creates a new user index for the chains. The index values are set to -1.
[ "Creates", "a", "new", "user", "index", "for", "the", "chains", ".", "The", "index", "values", "are", "set", "to", "-", "1", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2413-L2428
112,051
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/TopoGraph.java
TopoGraph.getHalfEdgeConnector
int getHalfEdgeConnector(int clusterFrom, int clusterTo) { int first_edge = getClusterHalfEdge(clusterFrom); if (first_edge == -1) return -1; int edge = first_edge; int firstEdgeTo = -1; int eTo = -1; // Doing two loops in parallel - one on the half-edges attached to the // clusterFrom, another - attac...
java
int getHalfEdgeConnector(int clusterFrom, int clusterTo) { int first_edge = getClusterHalfEdge(clusterFrom); if (first_edge == -1) return -1; int edge = first_edge; int firstEdgeTo = -1; int eTo = -1; // Doing two loops in parallel - one on the half-edges attached to the // clusterFrom, another - attac...
[ "int", "getHalfEdgeConnector", "(", "int", "clusterFrom", ",", "int", "clusterTo", ")", "{", "int", "first_edge", "=", "getClusterHalfEdge", "(", "clusterFrom", ")", ";", "if", "(", "first_edge", "==", "-", "1", ")", "return", "-", "1", ";", "int", "edge",...
Could be a slow operation when valency of each cluster is high.
[ "Could", "be", "a", "slow", "operation", "when", "valency", "of", "each", "cluster", "is", "high", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/TopoGraph.java#L2456-L2487
112,052
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTreeImpl.java
QuadTreeImpl.reset
void reset(Envelope2D extent, int height) { m_quad_tree_nodes.deleteAll(false); m_element_nodes.deleteAll(false); m_data.clear(); m_free_data.clear(false); reset_(extent, height); }
java
void reset(Envelope2D extent, int height) { m_quad_tree_nodes.deleteAll(false); m_element_nodes.deleteAll(false); m_data.clear(); m_free_data.clear(false); reset_(extent, height); }
[ "void", "reset", "(", "Envelope2D", "extent", ",", "int", "height", ")", "{", "m_quad_tree_nodes", ".", "deleteAll", "(", "false", ")", ";", "m_element_nodes", ".", "deleteAll", "(", "false", ")", ";", "m_data", ".", "clear", "(", ")", ";", "m_free_data", ...
Resets the Quad_tree_impl to the given extent and height. \param extent The extent of the Quad_tree_impl. \param height The max height of the Quad_tree_impl.
[ "Resets", "the", "Quad_tree_impl", "to", "the", "given", "extent", "and", "height", ".", "\\", "param", "extent", "The", "extent", "of", "the", "Quad_tree_impl", ".", "\\", "param", "height", "The", "max", "height", "of", "the", "Quad_tree_impl", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTreeImpl.java#L366-L372
112,053
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTreeImpl.java
QuadTreeImpl.insert
int insert(int element, Envelope2D bounding_box) { if (m_root == -1) create_root_(); if (m_b_store_duplicates) { int success = insert_duplicates_(element, bounding_box, 0, m_extent, m_root, false, -1); if (success != -1) { if (m_data_extent.isEmpty()) m_data_extent.setCoords(bounding_box); e...
java
int insert(int element, Envelope2D bounding_box) { if (m_root == -1) create_root_(); if (m_b_store_duplicates) { int success = insert_duplicates_(element, bounding_box, 0, m_extent, m_root, false, -1); if (success != -1) { if (m_data_extent.isEmpty()) m_data_extent.setCoords(bounding_box); e...
[ "int", "insert", "(", "int", "element", ",", "Envelope2D", "bounding_box", ")", "{", "if", "(", "m_root", "==", "-", "1", ")", "create_root_", "(", ")", ";", "if", "(", "m_b_store_duplicates", ")", "{", "int", "success", "=", "insert_duplicates_", "(", "...
Inserts the element and bounding_box into the Quad_tree_impl. Note that this will invalidate any active iterator on the Quad_tree_impl. Returns an Element_handle corresponding to the element and bounding_box. \param element The element of the Geometry to be inserted. \param bounding_box The bounding_box of the Geometry...
[ "Inserts", "the", "element", "and", "bounding_box", "into", "the", "Quad_tree_impl", ".", "Note", "that", "this", "will", "invalidate", "any", "active", "iterator", "on", "the", "Quad_tree_impl", ".", "Returns", "an", "Element_handle", "corresponding", "to", "the"...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTreeImpl.java#L381-L408
112,054
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTreeImpl.java
QuadTreeImpl.insert
int insert(int element, Envelope2D bounding_box, int hint_index) { if (m_root == -1) create_root_(); if (m_b_store_duplicates) { int success = insert_duplicates_(element, bounding_box, 0, m_extent, m_root, false, -1); if (success != -1) { if (m_data_extent.isEmpty()) m_data_extent.setCoords(boun...
java
int insert(int element, Envelope2D bounding_box, int hint_index) { if (m_root == -1) create_root_(); if (m_b_store_duplicates) { int success = insert_duplicates_(element, bounding_box, 0, m_extent, m_root, false, -1); if (success != -1) { if (m_data_extent.isEmpty()) m_data_extent.setCoords(boun...
[ "int", "insert", "(", "int", "element", ",", "Envelope2D", "bounding_box", ",", "int", "hint_index", ")", "{", "if", "(", "m_root", "==", "-", "1", ")", "create_root_", "(", ")", ";", "if", "(", "m_b_store_duplicates", ")", "{", "int", "success", "=", ...
Inserts the element and bounding_box into the Quad_tree_impl at the given quad_handle. Note that this will invalidate any active iterator on the Quad_tree_impl. Returns an Element_handle corresponding to the element and bounding_box. \param element The element of the Geometry to be inserted. \param bounding_box The bou...
[ "Inserts", "the", "element", "and", "bounding_box", "into", "the", "Quad_tree_impl", "at", "the", "given", "quad_handle", ".", "Note", "that", "this", "will", "invalidate", "any", "active", "iterator", "on", "the", "Quad_tree_impl", ".", "Returns", "an", "Elemen...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTreeImpl.java#L418-L454
112,055
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTreeImpl.java
QuadTreeImpl.removeElement
void removeElement(int element_handle) { if (m_b_store_duplicates) throw new GeometryException("invalid call"); int quad_handle = get_quad_(element_handle); disconnect_element_handle_(element_handle); free_element_and_box_node_(element_handle); int q = quad_handle; while (q != -1) { set_sub_tree_el...
java
void removeElement(int element_handle) { if (m_b_store_duplicates) throw new GeometryException("invalid call"); int quad_handle = get_quad_(element_handle); disconnect_element_handle_(element_handle); free_element_and_box_node_(element_handle); int q = quad_handle; while (q != -1) { set_sub_tree_el...
[ "void", "removeElement", "(", "int", "element_handle", ")", "{", "if", "(", "m_b_store_duplicates", ")", "throw", "new", "GeometryException", "(", "\"invalid call\"", ")", ";", "int", "quad_handle", "=", "get_quad_", "(", "element_handle", ")", ";", "disconnect_el...
Removes the element and bounding_box at the given element_handle. Note that this will invalidate any active iterator on the Quad_tree_impl. \param element_handle The handle corresponding to the element and bounding_box to be removed.
[ "Removes", "the", "element", "and", "bounding_box", "at", "the", "given", "element_handle", ".", "Note", "that", "this", "will", "invalidate", "any", "active", "iterator", "on", "the", "Quad_tree_impl", ".", "\\", "param", "element_handle", "The", "handle", "cor...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTreeImpl.java#L461-L487
112,056
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTreeImpl.java
QuadTreeImpl.getExtent
Envelope2D getExtent(int quad_handle) { Envelope2D quad_extent = new Envelope2D(); quad_extent.setCoords(m_extent); if (quad_handle == m_root) return quad_extent; AttributeStreamOfInt32 quadrants = new AttributeStreamOfInt32(0); int q = quad_handle; do { quadrants.add(get_quadrant_(q)); q = get...
java
Envelope2D getExtent(int quad_handle) { Envelope2D quad_extent = new Envelope2D(); quad_extent.setCoords(m_extent); if (quad_handle == m_root) return quad_extent; AttributeStreamOfInt32 quadrants = new AttributeStreamOfInt32(0); int q = quad_handle; do { quadrants.add(get_quadrant_(q)); q = get...
[ "Envelope2D", "getExtent", "(", "int", "quad_handle", ")", "{", "Envelope2D", "quad_extent", "=", "new", "Envelope2D", "(", ")", ";", "quad_extent", ".", "setCoords", "(", "m_extent", ")", ";", "if", "(", "quad_handle", "==", "m_root", ")", "return", "quad_e...
Returns the extent of the quad at the given quad_handle. \param quad_handle The handle corresponding to the quad.
[ "Returns", "the", "extent", "of", "the", "quad", "at", "the", "given", "quad_handle", ".", "\\", "param", "quad_handle", "The", "handle", "corresponding", "to", "the", "quad", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTreeImpl.java#L552-L592
112,057
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTreeImpl.java
QuadTreeImpl.getIntersectionCount
int getIntersectionCount(Envelope2D query, double tolerance, int max_count) { if (m_root == -1) return 0; Envelope2D query_inflated = new Envelope2D(); query_inflated.setCoords(query); query_inflated.inflate(tolerance, tolerance); AttributeStreamOfInt32 quads_stack = new AttributeStreamOfInt32(0); Arra...
java
int getIntersectionCount(Envelope2D query, double tolerance, int max_count) { if (m_root == -1) return 0; Envelope2D query_inflated = new Envelope2D(); query_inflated.setCoords(query); query_inflated.inflate(tolerance, tolerance); AttributeStreamOfInt32 quads_stack = new AttributeStreamOfInt32(0); Arra...
[ "int", "getIntersectionCount", "(", "Envelope2D", "query", ",", "double", "tolerance", ",", "int", "max_count", ")", "{", "if", "(", "m_root", "==", "-", "1", ")", "return", "0", ";", "Envelope2D", "query_inflated", "=", "new", "Envelope2D", "(", ")", ";",...
Returns the number of elements in the quad tree that intersect the qiven query. Some elements may be duplicated if the quad tree stores duplicates. \param query The Envelope_2D used for the query. \param tolerance The tolerance used for the intersection tests. \param max_count If the intersection count becomes greater ...
[ "Returns", "the", "number", "of", "elements", "in", "the", "quad", "tree", "that", "intersect", "the", "qiven", "query", ".", "Some", "elements", "may", "be", "duplicated", "if", "the", "quad", "tree", "stores", "duplicates", ".", "\\", "param", "query", "...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTreeImpl.java#L638-L713
112,058
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/OperatorSimplifyLocalHelper.java
OperatorSimplifyLocalHelper.isSimplePlanar
static protected int isSimplePlanar(/* const */Geometry geometry, /* const */ SpatialReference spatialReference, boolean bForce, ProgressTracker progressTracker) { assert (false); // this code is not called yet. if (geometry.isEmpty()) return 1; Geometry.Type gt = geometry.getType(); if (gt == Geometry.T...
java
static protected int isSimplePlanar(/* const */Geometry geometry, /* const */ SpatialReference spatialReference, boolean bForce, ProgressTracker progressTracker) { assert (false); // this code is not called yet. if (geometry.isEmpty()) return 1; Geometry.Type gt = geometry.getType(); if (gt == Geometry.T...
[ "static", "protected", "int", "isSimplePlanar", "(", "/* const */", "Geometry", "geometry", ",", "/* const */", "SpatialReference", "spatialReference", ",", "boolean", "bForce", ",", "ProgressTracker", "progressTracker", ")", "{", "assert", "(", "false", ")", ";", "...
The code is executed in the 2D plane only.Attributes are ignored. MultiPoint-check for clustering. Polyline -check for clustering and cracking. Polygon -check for clustering,cracking,absence of self-intersections,and correct ring ordering.
[ "The", "code", "is", "executed", "in", "the", "2D", "plane", "only", ".", "Attributes", "are", "ignored", ".", "MultiPoint", "-", "check", "for", "clustering", ".", "Polyline", "-", "check", "for", "clustering", "and", "cracking", ".", "Polygon", "-", "che...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/OperatorSimplifyLocalHelper.java#L1726-L1773
112,059
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/OperatorSimplifyLocalHelper.java
OperatorSimplifyLocalHelper.edgeAngleCompare_
private int edgeAngleCompare_(/* const */Edge edge1, /* const */Edge edge2) { if (edge1.equals(edge2)) return 0; Point2D v1 = edge1.m_segment._getTangent(edge1.getReversed() ? 1.0 : 0.0); if (edge1.getReversed()) v1.negate(); Point2D v2 = edge2.m_segment._getTangent(edge2.getReversed() ? 1.0 : 0....
java
private int edgeAngleCompare_(/* const */Edge edge1, /* const */Edge edge2) { if (edge1.equals(edge2)) return 0; Point2D v1 = edge1.m_segment._getTangent(edge1.getReversed() ? 1.0 : 0.0); if (edge1.getReversed()) v1.negate(); Point2D v2 = edge2.m_segment._getTangent(edge2.getReversed() ? 1.0 : 0....
[ "private", "int", "edgeAngleCompare_", "(", "/* const */", "Edge", "edge1", ",", "/* const */", "Edge", "edge2", ")", "{", "if", "(", "edge1", ".", "equals", "(", "edge2", ")", ")", "return", "0", ";", "Point2D", "v1", "=", "edge1", ".", "m_segment", "."...
compares angles between two edges
[ "compares", "angles", "between", "two", "edges" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/OperatorSimplifyLocalHelper.java#L2190-L2220
112,060
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.getEnvelope2D
Envelope2D getEnvelope2D() { Envelope2D env = new Envelope2D(); env.setEmpty(); VertexIterator vert_iter = queryVertexIterator(); Point2D pt = new Point2D(); boolean b_first = true; for (int ivertex = vert_iter.next(); ivertex != -1; ivertex = vert_iter .next()) { getXY(ivertex, pt); if (b_first) ...
java
Envelope2D getEnvelope2D() { Envelope2D env = new Envelope2D(); env.setEmpty(); VertexIterator vert_iter = queryVertexIterator(); Point2D pt = new Point2D(); boolean b_first = true; for (int ivertex = vert_iter.next(); ivertex != -1; ivertex = vert_iter .next()) { getXY(ivertex, pt); if (b_first) ...
[ "Envelope2D", "getEnvelope2D", "(", ")", "{", "Envelope2D", "env", "=", "new", "Envelope2D", "(", ")", ";", "env", ".", "setEmpty", "(", ")", ";", "VertexIterator", "vert_iter", "=", "queryVertexIterator", "(", ")", ";", "Point2D", "pt", "=", "new", "Point...
Returns envelope of all coordinates.
[ "Returns", "envelope", "of", "all", "coordinates", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L549-L567
112,061
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.addGeometry
int addGeometry(Geometry geometry) { Geometry.Type gt = geometry.getType(); if (Geometry.isMultiPath(gt.value())) return addMultiPath_((MultiPath) geometry); if (gt == Geometry.Type.MultiPoint) return addMultiPoint_((MultiPoint) geometry); throw GeometryException.GeometryInternalError(); }
java
int addGeometry(Geometry geometry) { Geometry.Type gt = geometry.getType(); if (Geometry.isMultiPath(gt.value())) return addMultiPath_((MultiPath) geometry); if (gt == Geometry.Type.MultiPoint) return addMultiPoint_((MultiPoint) geometry); throw GeometryException.GeometryInternalError(); }
[ "int", "addGeometry", "(", "Geometry", "geometry", ")", "{", "Geometry", ".", "Type", "gt", "=", "geometry", ".", "getType", "(", ")", ";", "if", "(", "Geometry", ".", "isMultiPath", "(", "gt", ".", "value", "(", ")", ")", ")", "return", "addMultiPath_...
Adds a Geometry to the Edit_shape
[ "Adds", "a", "Geometry", "to", "the", "Edit_shape" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L575-L583
112,062
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.appendGeometry
void appendGeometry(int dstGeometry, Geometry srcGeometry) { Geometry.Type gt = srcGeometry.getType(); if (Geometry.isMultiPath(gt.value())) { appendMultiPath_(dstGeometry, (MultiPath) srcGeometry); return; } else if (gt.value() == Geometry.GeometryType.MultiPoint) { appendMultiPoint_(dstGeometry, (Multi...
java
void appendGeometry(int dstGeometry, Geometry srcGeometry) { Geometry.Type gt = srcGeometry.getType(); if (Geometry.isMultiPath(gt.value())) { appendMultiPath_(dstGeometry, (MultiPath) srcGeometry); return; } else if (gt.value() == Geometry.GeometryType.MultiPoint) { appendMultiPoint_(dstGeometry, (Multi...
[ "void", "appendGeometry", "(", "int", "dstGeometry", ",", "Geometry", "srcGeometry", ")", "{", "Geometry", ".", "Type", "gt", "=", "srcGeometry", ".", "getType", "(", ")", ";", "if", "(", "Geometry", ".", "isMultiPath", "(", "gt", ".", "value", "(", ")",...
Append a Geometry to the given geometry of the Edit_shape
[ "Append", "a", "Geometry", "to", "the", "given", "geometry", "of", "the", "Edit_shape" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L586-L597
112,063
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.addPathFromMultiPath
int addPathFromMultiPath(MultiPath multi_path, int ipath, boolean as_polygon) { int newgeom = createGeometry(as_polygon ? Geometry.Type.Polygon : Geometry.Type.Polyline, multi_path.getDescription()); MultiPathImpl mp_impl = (MultiPathImpl) multi_path._getImpl(); if (multi_path.getPathSize(ipath) < 2) retu...
java
int addPathFromMultiPath(MultiPath multi_path, int ipath, boolean as_polygon) { int newgeom = createGeometry(as_polygon ? Geometry.Type.Polygon : Geometry.Type.Polyline, multi_path.getDescription()); MultiPathImpl mp_impl = (MultiPathImpl) multi_path._getImpl(); if (multi_path.getPathSize(ipath) < 2) retu...
[ "int", "addPathFromMultiPath", "(", "MultiPath", "multi_path", ",", "int", "ipath", ",", "boolean", "as_polygon", ")", "{", "int", "newgeom", "=", "createGeometry", "(", "as_polygon", "?", "Geometry", ".", "Type", ".", "Polygon", ":", "Geometry", ".", "Type", ...
Adds a path
[ "Adds", "a", "path" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L600-L638
112,064
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.removeGeometry
int removeGeometry(int geometry) { for (int path = getFirstPath(geometry); path != -1; path = removePath(path)) { // removing paths in a loop } int prev = getPrevGeometry(geometry); int next = getNextGeometry(geometry); if (prev != -1) setNextGeometry_(prev, next); else { m_first_geometry = next; ...
java
int removeGeometry(int geometry) { for (int path = getFirstPath(geometry); path != -1; path = removePath(path)) { // removing paths in a loop } int prev = getPrevGeometry(geometry); int next = getNextGeometry(geometry); if (prev != -1) setNextGeometry_(prev, next); else { m_first_geometry = next; ...
[ "int", "removeGeometry", "(", "int", "geometry", ")", "{", "for", "(", "int", "path", "=", "getFirstPath", "(", "geometry", ")", ";", "path", "!=", "-", "1", ";", "path", "=", "removePath", "(", "path", ")", ")", "{", "// removing paths in a loop", "}", ...
Deletes existing geometry from the edit shape and returns the next one.
[ "Deletes", "existing", "geometry", "from", "the", "edit", "shape", "and", "returns", "the", "next", "one", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L769-L789
112,065
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.createGeometry
int createGeometry(Geometry.Type geometry_type, VertexDescription description) { int newgeom = newGeometry_(geometry_type.value()); if (m_vertices == null) { m_vertices_mp = new MultiPoint(description); m_vertices = (MultiPointImpl) m_vertices_mp._getImpl(); } else m_vertices_mp.mergeVertexDescription...
java
int createGeometry(Geometry.Type geometry_type, VertexDescription description) { int newgeom = newGeometry_(geometry_type.value()); if (m_vertices == null) { m_vertices_mp = new MultiPoint(description); m_vertices = (MultiPointImpl) m_vertices_mp._getImpl(); } else m_vertices_mp.mergeVertexDescription...
[ "int", "createGeometry", "(", "Geometry", ".", "Type", "geometry_type", ",", "VertexDescription", "description", ")", "{", "int", "newgeom", "=", "newGeometry_", "(", "geometry_type", ".", "value", "(", ")", ")", ";", "if", "(", "m_vertices", "==", "null", "...
create a new empty geometry of the given type and attribute set.
[ "create", "a", "new", "empty", "geometry", "of", "the", "given", "type", "and", "attribute", "set", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L792-L822
112,066
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.setGeometryUserIndex
void setGeometryUserIndex(int geom, int index, int value) { AttributeStreamOfInt32 stream = m_geometry_indices.get(index); int pindex = getGeometryIndex_(geom); if (pindex >= stream.size()) stream.resize(Math.max((int) (pindex * 1.25), (int) 16), -1); stream.write(pindex, value); }
java
void setGeometryUserIndex(int geom, int index, int value) { AttributeStreamOfInt32 stream = m_geometry_indices.get(index); int pindex = getGeometryIndex_(geom); if (pindex >= stream.size()) stream.resize(Math.max((int) (pindex * 1.25), (int) 16), -1); stream.write(pindex, value); }
[ "void", "setGeometryUserIndex", "(", "int", "geom", ",", "int", "index", ",", "int", "value", ")", "{", "AttributeStreamOfInt32", "stream", "=", "m_geometry_indices", ".", "get", "(", "index", ")", ";", "int", "pindex", "=", "getGeometryIndex_", "(", "geom", ...
Sets value to the given user index on a geometry.
[ "Sets", "value", "to", "the", "given", "user", "index", "on", "a", "geometry", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L847-L853
112,067
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.getGeometryUserIndex
int getGeometryUserIndex(int geom, int index) { int pindex = getGeometryIndex_(geom); AttributeStreamOfInt32 stream = m_geometry_indices.get(index); if (pindex < stream.size()) return stream.read(pindex); else return -1; }
java
int getGeometryUserIndex(int geom, int index) { int pindex = getGeometryIndex_(geom); AttributeStreamOfInt32 stream = m_geometry_indices.get(index); if (pindex < stream.size()) return stream.read(pindex); else return -1; }
[ "int", "getGeometryUserIndex", "(", "int", "geom", ",", "int", "index", ")", "{", "int", "pindex", "=", "getGeometryIndex_", "(", "geom", ")", ";", "AttributeStreamOfInt32", "stream", "=", "m_geometry_indices", ".", "get", "(", "index", ")", ";", "if", "(", ...
Returns the value of the given user index of a geometry
[ "Returns", "the", "value", "of", "the", "given", "user", "index", "of", "a", "geometry" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L856-L863
112,068
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.createGeometryUserIndex
int createGeometryUserIndex() { if (m_geometry_indices == null) m_geometry_indices = new ArrayList<AttributeStreamOfInt32>(4); // Try getting existing index. Use linear search. We do not expect many // indices to be created. for (int i = 0; i < m_geometry_indices.size(); i++) { if (m_geometry_indices.get...
java
int createGeometryUserIndex() { if (m_geometry_indices == null) m_geometry_indices = new ArrayList<AttributeStreamOfInt32>(4); // Try getting existing index. Use linear search. We do not expect many // indices to be created. for (int i = 0; i < m_geometry_indices.size(); i++) { if (m_geometry_indices.get...
[ "int", "createGeometryUserIndex", "(", ")", "{", "if", "(", "m_geometry_indices", "==", "null", ")", "m_geometry_indices", "=", "new", "ArrayList", "<", "AttributeStreamOfInt32", ">", "(", "4", ")", ";", "// Try getting existing index. Use linear search. We do not expect ...
stores -1 for that geometry.
[ "stores", "-", "1", "for", "that", "geometry", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L869-L887
112,069
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.hasDegenerateSegments
boolean hasDegenerateSegments(double tolerance) { for (int geometry = getFirstGeometry(); geometry != -1; geometry = getNextGeometry(geometry)) { if (!Geometry.isMultiPath(getGeometryType(geometry))) continue; boolean b_polygon = getGeometryType(geometry) == Geometry.GeometryType.Polygon; for (int path...
java
boolean hasDegenerateSegments(double tolerance) { for (int geometry = getFirstGeometry(); geometry != -1; geometry = getNextGeometry(geometry)) { if (!Geometry.isMultiPath(getGeometryType(geometry))) continue; boolean b_polygon = getGeometryType(geometry) == Geometry.GeometryType.Polygon; for (int path...
[ "boolean", "hasDegenerateSegments", "(", "double", "tolerance", ")", "{", "for", "(", "int", "geometry", "=", "getFirstGeometry", "(", ")", ";", "geometry", "!=", "-", "1", ";", "geometry", "=", "getNextGeometry", "(", "geometry", ")", ")", "{", "if", "(",...
Checks if there are degenerate segments in any of multipath geometries
[ "Checks", "if", "there", "are", "degenerate", "segments", "in", "any", "of", "multipath", "geometries" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1022-L1061
112,070
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.splitSegment
int splitSegment(int origin_vertex, double[] split_scalars, int split_count) { int actual_splits = 0; int next_vertex = getNextVertex(origin_vertex); if (next_vertex == -1) throw GeometryException.GeometryInternalError(); int vindex = getVertexIndex(origin_vertex); int vindex_next = getVertexIndex(next_ve...
java
int splitSegment(int origin_vertex, double[] split_scalars, int split_count) { int actual_splits = 0; int next_vertex = getNextVertex(origin_vertex); if (next_vertex == -1) throw GeometryException.GeometryInternalError(); int vindex = getVertexIndex(origin_vertex); int vindex_next = getVertexIndex(next_ve...
[ "int", "splitSegment", "(", "int", "origin_vertex", ",", "double", "[", "]", "split_scalars", ",", "int", "split_count", ")", "{", "int", "actual_splits", "=", "0", ";", "int", "next_vertex", "=", "getNextVertex", "(", "origin_vertex", ")", ";", "if", "(", ...
happend).
[ "happend", ")", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1097-L1155
112,071
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.createUserIndex
int createUserIndex() { if (m_indices == null) m_indices = new ArrayList<AttributeStreamOfInt32>(0); // Try getting existing index. Use linear search. We do not expect many // indices to be created. for (int i = 0; i < m_indices.size(); i++) { if (m_indices.get(i) == null) { m_indices.set(i, (Attribu...
java
int createUserIndex() { if (m_indices == null) m_indices = new ArrayList<AttributeStreamOfInt32>(0); // Try getting existing index. Use linear search. We do not expect many // indices to be created. for (int i = 0; i < m_indices.size(); i++) { if (m_indices.get(i) == null) { m_indices.set(i, (Attribu...
[ "int", "createUserIndex", "(", ")", "{", "if", "(", "m_indices", "==", "null", ")", "m_indices", "=", "new", "ArrayList", "<", "AttributeStreamOfInt32", ">", "(", "0", ")", ";", "// Try getting existing index. Use linear search. We do not expect many", "// indices to be...
store an integer user value on the vertex.
[ "store", "an", "integer", "user", "value", "on", "the", "vertex", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1408-L1425
112,072
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.getSegment
Segment getSegment(int vertex) { if (m_segments != null) { int vindex = getVertexIndex(vertex); return m_segments.get(vindex); } return null; }
java
Segment getSegment(int vertex) { if (m_segments != null) { int vindex = getVertexIndex(vertex); return m_segments.get(vindex); } return null; }
[ "Segment", "getSegment", "(", "int", "vertex", ")", "{", "if", "(", "m_segments", "!=", "null", ")", "{", "int", "vindex", "=", "getVertexIndex", "(", "vertex", ")", ";", "return", "m_segments", ".", "get", "(", "vindex", ")", ";", "}", "return", "null...
if it is a Line.
[ "if", "it", "is", "a", "Line", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1434-L1440
112,073
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.queryLineConnector
boolean queryLineConnector(int vertex, Line line) { int next = getNextVertex(vertex); if (next == -1) return false; if (!m_b_has_attributes) { Point2D pt = new Point2D(); getXY(vertex, pt); line.setStartXY(pt); getXY(next, pt); line.setEndXY(pt); } else { Point pt = new Point(); queryPo...
java
boolean queryLineConnector(int vertex, Line line) { int next = getNextVertex(vertex); if (next == -1) return false; if (!m_b_has_attributes) { Point2D pt = new Point2D(); getXY(vertex, pt); line.setStartXY(pt); getXY(next, pt); line.setEndXY(pt); } else { Point pt = new Point(); queryPo...
[ "boolean", "queryLineConnector", "(", "int", "vertex", ",", "Line", "line", ")", "{", "int", "next", "=", "getNextVertex", "(", "vertex", ")", ";", "if", "(", "next", "==", "-", "1", ")", "return", "false", ";", "if", "(", "!", "m_b_has_attributes", ")...
Can be used together with get_segment.
[ "Can", "be", "used", "together", "with", "get_segment", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1446-L1466
112,074
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.insertPath
int insertPath(int geometry, int before_path) { int prev = -1; if (before_path != -1) { if (geometry != getGeometryFromPath(before_path)) throw GeometryException.GeometryInternalError(); prev = getPrevPath(before_path); } else prev = getLastPath(geometry); int newpath = newPath_(geometry); if ...
java
int insertPath(int geometry, int before_path) { int prev = -1; if (before_path != -1) { if (geometry != getGeometryFromPath(before_path)) throw GeometryException.GeometryInternalError(); prev = getPrevPath(before_path); } else prev = getLastPath(geometry); int newpath = newPath_(geometry); if ...
[ "int", "insertPath", "(", "int", "geometry", ",", "int", "before_path", ")", "{", "int", "prev", "=", "-", "1", ";", "if", "(", "before_path", "!=", "-", "1", ")", "{", "if", "(", "geometry", "!=", "getGeometryFromPath", "(", "before_path", ")", ")", ...
path at the end.
[ "path", "at", "the", "end", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1470-L1497
112,075
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.removePath
int removePath(int path) { int prev = getPrevPath(path); int next = getNextPath(path); int geometry = getGeometryFromPath(path); if (prev != -1) setNextPath_(prev, next); else { setFirstPath_(geometry, next); } if (next != -1) setPrevPath_(next, prev); else { setLastPath_(geometry, prev); ...
java
int removePath(int path) { int prev = getPrevPath(path); int next = getNextPath(path); int geometry = getGeometryFromPath(path); if (prev != -1) setNextPath_(prev, next); else { setFirstPath_(geometry, next); } if (next != -1) setPrevPath_(next, prev); else { setLastPath_(geometry, prev); ...
[ "int", "removePath", "(", "int", "path", ")", "{", "int", "prev", "=", "getPrevPath", "(", "path", ")", ";", "int", "next", "=", "getNextPath", "(", "path", ")", ";", "int", "geometry", "=", "getGeometryFromPath", "(", "path", ")", ";", "if", "(", "p...
Removes a path, gets rid of all its vertices, and returns the next one
[ "Removes", "a", "path", "gets", "rid", "of", "all", "its", "vertices", "and", "returns", "the", "next", "one" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1539-L1559
112,076
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.clearPath
void clearPath(int path) { int first_vertex = getFirstVertex(path); if (first_vertex != -1) { // TODO: can ve do this in one shot? int vertex = first_vertex; for (int i = 0, n = getPathSize(path); i < n; i++) { int v = vertex; vertex = getNextVertex(vertex); freeVertex_(v); } int geometry...
java
void clearPath(int path) { int first_vertex = getFirstVertex(path); if (first_vertex != -1) { // TODO: can ve do this in one shot? int vertex = first_vertex; for (int i = 0, n = getPathSize(path); i < n; i++) { int v = vertex; vertex = getNextVertex(vertex); freeVertex_(v); } int geometry...
[ "void", "clearPath", "(", "int", "path", ")", "{", "int", "first_vertex", "=", "getFirstVertex", "(", "path", ")", ";", "if", "(", "first_vertex", "!=", "-", "1", ")", "{", "// TODO: can ve do this in one shot?", "int", "vertex", "=", "first_vertex", ";", "f...
Clears all vertices from the path
[ "Clears", "all", "vertices", "from", "the", "path" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1562-L1577
112,077
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.getRingArea
double getRingArea(int path) { if (isRingAreaValid_(path)) return m_path_areas.get(getPathIndex_(path)); Line line = new Line(); int vertex = getFirstVertex(path); if (vertex == -1) return 0; Point2D pt0 = new Point2D(); getXY(vertex, pt0); double area = 0; for (int i = 0, n = getPathSize(path); ...
java
double getRingArea(int path) { if (isRingAreaValid_(path)) return m_path_areas.get(getPathIndex_(path)); Line line = new Line(); int vertex = getFirstVertex(path); if (vertex == -1) return 0; Point2D pt0 = new Point2D(); getXY(vertex, pt0); double area = 0; for (int i = 0, n = getPathSize(path); ...
[ "double", "getRingArea", "(", "int", "path", ")", "{", "if", "(", "isRingAreaValid_", "(", "path", ")", ")", "return", "m_path_areas", ".", "get", "(", "getPathIndex_", "(", "path", ")", ")", ";", "Line", "line", "=", "new", "Line", "(", ")", ";", "i...
Returns the ring area
[ "Returns", "the", "ring", "area" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1662-L1690
112,078
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.setPathUserIndex
void setPathUserIndex(int path, int index, int value) { AttributeStreamOfInt32 stream = m_pathindices.get(index); int pindex = getPathIndex_(path); if (stream.size() < m_path_areas.size()) stream.resize(m_path_areas.size(), -1); stream.write(pindex, value); }
java
void setPathUserIndex(int path, int index, int value) { AttributeStreamOfInt32 stream = m_pathindices.get(index); int pindex = getPathIndex_(path); if (stream.size() < m_path_areas.size()) stream.resize(m_path_areas.size(), -1); stream.write(pindex, value); }
[ "void", "setPathUserIndex", "(", "int", "path", ",", "int", "index", ",", "int", "value", ")", "{", "AttributeStreamOfInt32", "stream", "=", "m_pathindices", ".", "get", "(", "index", ")", ";", "int", "pindex", "=", "getPathIndex_", "(", "path", ")", ";", ...
Sets value to the given user index on a path.
[ "Sets", "value", "to", "the", "given", "user", "index", "on", "a", "path", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1693-L1699
112,079
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.getPathUserIndex
int getPathUserIndex(int path, int index) { int pindex = getPathIndex_(path); AttributeStreamOfInt32 stream = m_pathindices.get(index); if (pindex < stream.size()) return stream.read(pindex); else return -1; }
java
int getPathUserIndex(int path, int index) { int pindex = getPathIndex_(path); AttributeStreamOfInt32 stream = m_pathindices.get(index); if (pindex < stream.size()) return stream.read(pindex); else return -1; }
[ "int", "getPathUserIndex", "(", "int", "path", ",", "int", "index", ")", "{", "int", "pindex", "=", "getPathIndex_", "(", "path", ")", ";", "AttributeStreamOfInt32", "stream", "=", "m_pathindices", ".", "get", "(", "index", ")", ";", "if", "(", "pindex", ...
Returns the value of the given user index of a path
[ "Returns", "the", "value", "of", "the", "given", "user", "index", "of", "a", "path" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1702-L1709
112,080
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.createPathUserIndex
int createPathUserIndex() { if (m_pathindices == null) m_pathindices = new ArrayList<AttributeStreamOfInt32>(0); // Try getting existing index. Use linear search. We do not expect many // indices to be created. for (int i = 0; i < m_pathindices.size(); i++) { if (m_pathindices.get(i) == null) { m_path...
java
int createPathUserIndex() { if (m_pathindices == null) m_pathindices = new ArrayList<AttributeStreamOfInt32>(0); // Try getting existing index. Use linear search. We do not expect many // indices to be created. for (int i = 0; i < m_pathindices.size(); i++) { if (m_pathindices.get(i) == null) { m_path...
[ "int", "createPathUserIndex", "(", ")", "{", "if", "(", "m_pathindices", "==", "null", ")", "m_pathindices", "=", "new", "ArrayList", "<", "AttributeStreamOfInt32", ">", "(", "0", ")", ";", "// Try getting existing index. Use linear search. We do not expect many", "// i...
index allows to store an integer user value on the path.
[ "index", "allows", "to", "store", "an", "integer", "user", "value", "on", "the", "path", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1713-L1730
112,081
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.movePath
void movePath(int geom, int before_path, int path_to_move) { if (path_to_move == -1) throw new IllegalArgumentException(); if (before_path == path_to_move) return; int next = getNextPath(path_to_move); int prev = getPrevPath(path_to_move); int geom_src = getGeometryFromPath(path_to_move); if (prev =...
java
void movePath(int geom, int before_path, int path_to_move) { if (path_to_move == -1) throw new IllegalArgumentException(); if (before_path == path_to_move) return; int next = getNextPath(path_to_move); int prev = getPrevPath(path_to_move); int geom_src = getGeometryFromPath(path_to_move); if (prev =...
[ "void", "movePath", "(", "int", "geom", ",", "int", "before_path", ",", "int", "path_to_move", ")", "{", "if", "(", "path_to_move", "==", "-", "1", ")", "throw", "new", "IllegalArgumentException", "(", ")", ";", "if", "(", "before_path", "==", "path_to_mov...
before_path can be -1, then the path is moved to the end of the dst_geom.
[ "before_path", "can", "be", "-", "1", "then", "the", "path", "is", "moved", "to", "the", "end", "of", "the", "dst_geom", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1740-L1785
112,082
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.addVertex
int addVertex(int path, int vertex) { m_vertices.getPointByVal(getVertexIndex(vertex), getHelperPoint_()); return insertVertex_(path, -1, getHelperPoint_()); }
java
int addVertex(int path, int vertex) { m_vertices.getPointByVal(getVertexIndex(vertex), getHelperPoint_()); return insertVertex_(path, -1, getHelperPoint_()); }
[ "int", "addVertex", "(", "int", "path", ",", "int", "vertex", ")", "{", "m_vertices", ".", "getPointByVal", "(", "getVertexIndex", "(", "vertex", ")", ",", "getHelperPoint_", "(", ")", ")", ";", "return", "insertVertex_", "(", "path", ",", "-", "1", ",",...
Returns new vertex handle.
[ "Returns", "new", "vertex", "handle", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1789-L1792
112,083
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.removeVertex
int removeVertex(int vertex, boolean b_left_segment) { int path = getPathFromVertex(vertex); int prev = getPrevVertex(vertex); int next = getNextVertex(vertex); if (prev != -1) setNextVertex_(prev, next); int path_size = getPathSize(path); if (vertex == getFirstVertex(path)) { setFirstVertex_(path, ...
java
int removeVertex(int vertex, boolean b_left_segment) { int path = getPathFromVertex(vertex); int prev = getPrevVertex(vertex); int next = getNextVertex(vertex); if (prev != -1) setNextVertex_(prev, next); int path_size = getPathSize(path); if (vertex == getFirstVertex(path)) { setFirstVertex_(path, ...
[ "int", "removeVertex", "(", "int", "vertex", ",", "boolean", "b_left_segment", ")", "{", "int", "path", "=", "getPathFromVertex", "(", "vertex", ")", ";", "int", "prev", "=", "getPrevVertex", "(", "vertex", ")", ";", "int", "next", "=", "getNextVertex", "(...
reconnect. Returns next vertex after erased one.
[ "reconnect", ".", "Returns", "next", "vertex", "after", "erased", "one", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L1796-L1842
112,084
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/EditShape.java
EditShape.applyTransformation
void applyTransformation(Transformation2D transform) { m_vertices_mp.applyTransformation(transform); if (m_segments != null) { for (int i = 0, n = m_segments.size(); i < n; i++) { if (m_segments.get(i) != null) { m_segments.get(i).applyTransformation(transform); } } } }
java
void applyTransformation(Transformation2D transform) { m_vertices_mp.applyTransformation(transform); if (m_segments != null) { for (int i = 0, n = m_segments.size(); i < n; i++) { if (m_segments.get(i) != null) { m_segments.get(i).applyTransformation(transform); } } } }
[ "void", "applyTransformation", "(", "Transformation2D", "transform", ")", "{", "m_vertices_mp", ".", "applyTransformation", "(", "transform", ")", ";", "if", "(", "m_segments", "!=", "null", ")", "{", "for", "(", "int", "i", "=", "0", ",", "n", "=", "m_seg...
Applies affine transformation
[ "Applies", "affine", "transformation" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/EditShape.java#L2038-L2047
112,085
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTree.java
QuadTree.insert
public int insert(int element, Envelope2D boundingBox, int hintIndex) { return m_impl.insert(element, boundingBox, hintIndex); }
java
public int insert(int element, Envelope2D boundingBox, int hintIndex) { return m_impl.insert(element, boundingBox, hintIndex); }
[ "public", "int", "insert", "(", "int", "element", ",", "Envelope2D", "boundingBox", ",", "int", "hintIndex", ")", "{", "return", "m_impl", ".", "insert", "(", "element", ",", "boundingBox", ",", "hintIndex", ")", ";", "}" ]
Inserts the element and bounding_box into the QuadTree at the given quad_handle. Note that a copy will me made of the input bounding_box. Note that this will invalidate any active iterator on the QuadTree. Returns an Element_handle corresponding to the element and bounding_box. \param element The element of the Geometr...
[ "Inserts", "the", "element", "and", "bounding_box", "into", "the", "QuadTree", "at", "the", "given", "quad_handle", ".", "Note", "that", "a", "copy", "will", "me", "made", "of", "the", "input", "bounding_box", ".", "Note", "that", "this", "will", "invalidate...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTree.java#L136-L138
112,086
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTree.java
QuadTree.getIntersectionCount
public int getIntersectionCount(Envelope2D query, double tolerance, int maxCount) { return m_impl.getIntersectionCount(query, tolerance, maxCount); }
java
public int getIntersectionCount(Envelope2D query, double tolerance, int maxCount) { return m_impl.getIntersectionCount(query, tolerance, maxCount); }
[ "public", "int", "getIntersectionCount", "(", "Envelope2D", "query", ",", "double", "tolerance", ",", "int", "maxCount", ")", "{", "return", "m_impl", ".", "getIntersectionCount", "(", "query", ",", "tolerance", ",", "maxCount", ")", ";", "}" ]
Returns the number of elements in the quad tree that intersect the qiven query. Some elements may be duplicated if the quad tree stores duplicates. \param query The Envelope2D used for the query. \param tolerance The tolerance used for the intersection tests. \param max_count If the intersection count becomes greater t...
[ "Returns", "the", "number", "of", "elements", "in", "the", "quad", "tree", "that", "intersect", "the", "qiven", "query", ".", "Some", "elements", "may", "be", "duplicated", "if", "the", "quad", "tree", "stores", "duplicates", ".", "\\", "param", "query", "...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTree.java#L202-L204
112,087
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTree.java
QuadTree.getIterator
public QuadTreeIterator getIterator(Geometry query, double tolerance) { QuadTreeImpl.QuadTreeIteratorImpl iterator = m_impl.getIterator(query, tolerance); return new QuadTreeIterator(iterator, false); }
java
public QuadTreeIterator getIterator(Geometry query, double tolerance) { QuadTreeImpl.QuadTreeIteratorImpl iterator = m_impl.getIterator(query, tolerance); return new QuadTreeIterator(iterator, false); }
[ "public", "QuadTreeIterator", "getIterator", "(", "Geometry", "query", ",", "double", "tolerance", ")", "{", "QuadTreeImpl", ".", "QuadTreeIteratorImpl", "iterator", "=", "m_impl", ".", "getIterator", "(", "query", ",", "tolerance", ")", ";", "return", "new", "Q...
Gets an iterator on the QuadTree. The query will be the Envelope2D that bounds the input Geometry. To reuse the existing iterator on the same QuadTree but with a new query, use the reset_iterator function on the QuadTree_iterator. \param query The Geometry used for the query. If the Geometry is a Line segment, then the...
[ "Gets", "an", "iterator", "on", "the", "QuadTree", ".", "The", "query", "will", "be", "the", "Envelope2D", "that", "bounds", "the", "input", "Geometry", ".", "To", "reuse", "the", "existing", "iterator", "on", "the", "same", "QuadTree", "but", "with", "a",...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTree.java#L263-L266
112,088
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTree.java
QuadTree.getIterator
public QuadTreeIterator getIterator() { QuadTreeImpl.QuadTreeIteratorImpl iterator = m_impl.getIterator(); return new QuadTreeIterator(iterator, false); }
java
public QuadTreeIterator getIterator() { QuadTreeImpl.QuadTreeIteratorImpl iterator = m_impl.getIterator(); return new QuadTreeIterator(iterator, false); }
[ "public", "QuadTreeIterator", "getIterator", "(", ")", "{", "QuadTreeImpl", ".", "QuadTreeIteratorImpl", "iterator", "=", "m_impl", ".", "getIterator", "(", ")", ";", "return", "new", "QuadTreeIterator", "(", "iterator", ",", "false", ")", ";", "}" ]
Gets an iterator on the QuadTree.
[ "Gets", "an", "iterator", "on", "the", "QuadTree", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTree.java#L283-L286
112,089
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTree.java
QuadTree.getIterator
public QuadTreeIterator getIterator(Geometry query, double tolerance, boolean bSorted) { if (!bSorted) { QuadTreeImpl.QuadTreeIteratorImpl iterator = m_impl.getIterator(query, tolerance); return new QuadTreeIterator(iterator, false); } else { QuadTreeImpl.QuadTreeSortedIteratorImpl iterator = m_impl.getSor...
java
public QuadTreeIterator getIterator(Geometry query, double tolerance, boolean bSorted) { if (!bSorted) { QuadTreeImpl.QuadTreeIteratorImpl iterator = m_impl.getIterator(query, tolerance); return new QuadTreeIterator(iterator, false); } else { QuadTreeImpl.QuadTreeSortedIteratorImpl iterator = m_impl.getSor...
[ "public", "QuadTreeIterator", "getIterator", "(", "Geometry", "query", ",", "double", "tolerance", ",", "boolean", "bSorted", ")", "{", "if", "(", "!", "bSorted", ")", "{", "QuadTreeImpl", ".", "QuadTreeIteratorImpl", "iterator", "=", "m_impl", ".", "getIterator...
Gets an iterator on the QuadTree. The query will be the Envelope2D that bounds the input Geometry. To reuse the existing iterator on the same QuadTree but with a new query, use the reset_iterator function on the QuadTree_iterator. \param query The Geometry used for the query. If the Geometry is a Line segment, then the...
[ "Gets", "an", "iterator", "on", "the", "QuadTree", ".", "The", "query", "will", "be", "the", "Envelope2D", "that", "bounds", "the", "input", "Geometry", ".", "To", "reuse", "the", "existing", "iterator", "on", "the", "same", "QuadTree", "but", "with", "a",...
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTree.java#L295-L303
112,090
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/QuadTree.java
QuadTree.getIterator
public QuadTreeIterator getIterator(boolean bSorted) { if (!bSorted) { QuadTreeImpl.QuadTreeIteratorImpl iterator = m_impl.getIterator(); return new QuadTreeIterator(iterator, false); } else { QuadTreeImpl.QuadTreeSortedIteratorImpl iterator = m_impl.getSortedIterator(); return new QuadTreeIterator(iter...
java
public QuadTreeIterator getIterator(boolean bSorted) { if (!bSorted) { QuadTreeImpl.QuadTreeIteratorImpl iterator = m_impl.getIterator(); return new QuadTreeIterator(iterator, false); } else { QuadTreeImpl.QuadTreeSortedIteratorImpl iterator = m_impl.getSortedIterator(); return new QuadTreeIterator(iter...
[ "public", "QuadTreeIterator", "getIterator", "(", "boolean", "bSorted", ")", "{", "if", "(", "!", "bSorted", ")", "{", "QuadTreeImpl", ".", "QuadTreeIteratorImpl", "iterator", "=", "m_impl", ".", "getIterator", "(", ")", ";", "return", "new", "QuadTreeIterator",...
Gets an iterator on the QuadTree. \param bSorted Put true to iterate the quad tree in the order of the Element_types.
[ "Gets", "an", "iterator", "on", "the", "QuadTree", ".", "\\", "param", "bSorted", "Put", "true", "to", "iterate", "the", "quad", "tree", "in", "the", "order", "of", "the", "Element_types", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/QuadTree.java#L326-L334
112,091
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/Segment.java
Segment.getCoord2D
public Point2D getCoord2D(double t) { Point2D pt = new Point2D(); getCoord2D(t, pt); return pt; }
java
public Point2D getCoord2D(double t) { Point2D pt = new Point2D(); getCoord2D(t, pt); return pt; }
[ "public", "Point2D", "getCoord2D", "(", "double", "t", ")", "{", "Point2D", "pt", "=", "new", "Point2D", "(", ")", ";", "getCoord2D", "(", "t", ",", "pt", ")", ";", "return", "pt", ";", "}" ]
Returns the coordinate of the point on this segment for the given parameter value.
[ "Returns", "the", "coordinate", "of", "the", "point", "on", "this", "segment", "for", "the", "given", "parameter", "value", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/Segment.java#L781-L785
112,092
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/MultiPathImpl.java
MultiPathImpl.startPath
public void startPath(double x, double y) { Point2D endPoint = new Point2D(); endPoint.x = x; endPoint.y = y; startPath(endPoint); }
java
public void startPath(double x, double y) { Point2D endPoint = new Point2D(); endPoint.x = x; endPoint.y = y; startPath(endPoint); }
[ "public", "void", "startPath", "(", "double", "x", ",", "double", "y", ")", "{", "Point2D", "endPoint", "=", "new", "Point2D", "(", ")", ";", "endPoint", ".", "x", "=", "x", ";", "endPoint", ".", "y", "=", "y", ";", "startPath", "(", "endPoint", ")...
Starts a new Path at the Point.
[ "Starts", "a", "new", "Path", "at", "the", "Point", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/MultiPathImpl.java#L137-L142
112,093
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/MultiPathImpl.java
MultiPathImpl.bezierTo
public void bezierTo(Point2D controlPoint1, Point2D controlPoint2, Point2D endPoint) { _beforeNewSegment(1); setXY(m_pointCount - 1, endPoint); double z; _initSegmentData(6); m_pathFlags.setBits(m_pathFlags.size() - 1, (byte) PathFlags.enumHasNonlinearSegments); m_segmentParamIndex.write(m_pointCount...
java
public void bezierTo(Point2D controlPoint1, Point2D controlPoint2, Point2D endPoint) { _beforeNewSegment(1); setXY(m_pointCount - 1, endPoint); double z; _initSegmentData(6); m_pathFlags.setBits(m_pathFlags.size() - 1, (byte) PathFlags.enumHasNonlinearSegments); m_segmentParamIndex.write(m_pointCount...
[ "public", "void", "bezierTo", "(", "Point2D", "controlPoint1", ",", "Point2D", "controlPoint2", ",", "Point2D", "endPoint", ")", "{", "_beforeNewSegment", "(", "1", ")", ";", "setXY", "(", "m_pointCount", "-", "1", ",", "endPoint", ")", ";", "double", "z", ...
adds a Cubic Bezier Segment to the current Path. The Bezier Segment connects the current last Point and the given endPoint.
[ "adds", "a", "Cubic", "Bezier", "Segment", "to", "the", "current", "Path", ".", "The", "Bezier", "Segment", "connects", "the", "current", "last", "Point", "and", "the", "given", "endPoint", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/MultiPathImpl.java#L297-L317
112,094
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/MultiPathImpl.java
MultiPathImpl.openAllPathsAndDuplicateStartVertex
public void openAllPathsAndDuplicateStartVertex() { _touch(); if (m_bPolygon) throw GeometryException.GeometryInternalError();// do not call this // method on a // polygon if (m_pathFlags == null)// if (!m_pathFlags) throw GeometryException.GeometryInternalError(); _verifyA...
java
public void openAllPathsAndDuplicateStartVertex() { _touch(); if (m_bPolygon) throw GeometryException.GeometryInternalError();// do not call this // method on a // polygon if (m_pathFlags == null)// if (!m_pathFlags) throw GeometryException.GeometryInternalError(); _verifyA...
[ "public", "void", "openAllPathsAndDuplicateStartVertex", "(", ")", "{", "_touch", "(", ")", ";", "if", "(", "m_bPolygon", ")", "throw", "GeometryException", ".", "GeometryInternalError", "(", ")", ";", "// do not call this", "// method on a", "// polygon", "if", "("...
Major Changes on 16th of January
[ "Major", "Changes", "on", "16th", "of", "January" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/MultiPathImpl.java#L382-L457
112,095
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/MultiPathImpl.java
MultiPathImpl.closeAllPaths
public void closeAllPaths() { _touch(); if (m_bPolygon || isEmptyImpl()) return; m_bPathStarted = false; for (int ipath = 0, npart = m_paths.size() - 1; ipath < npart; ipath++) { if (isClosedPath(ipath)) continue; byte pf = m_pathFlags.read(ipath); m_pathFlags.write(ipath, (byte) (pf | PathFl...
java
public void closeAllPaths() { _touch(); if (m_bPolygon || isEmptyImpl()) return; m_bPathStarted = false; for (int ipath = 0, npart = m_paths.size() - 1; ipath < npart; ipath++) { if (isClosedPath(ipath)) continue; byte pf = m_pathFlags.read(ipath); m_pathFlags.write(ipath, (byte) (pf | PathFl...
[ "public", "void", "closeAllPaths", "(", ")", "{", "_touch", "(", ")", ";", "if", "(", "m_bPolygon", "||", "isEmptyImpl", "(", ")", ")", "return", ";", "m_bPathStarted", "=", "false", ";", "for", "(", "int", "ipath", "=", "0", ",", "npart", "=", "m_pa...
Closes all open curves by adding an implicit line segment from the end point to the start point.
[ "Closes", "all", "open", "curves", "by", "adding", "an", "implicit", "line", "segment", "from", "the", "end", "point", "to", "the", "start", "point", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/MultiPathImpl.java#L483-L503
112,096
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/MultiPathImpl.java
MultiPathImpl.closePathWithBezier
public void closePathWithBezier(Point2D controlPoint1, Point2D controlPoint2) { _touch(); if (isEmptyImpl()) throw new GeometryException( "Invalid call. This operation cannot be performed on an empty geometry."); m_bPathStarted = false; int pathIndex = m_paths.size() - 2; byte pf = m_pathFlags.read(...
java
public void closePathWithBezier(Point2D controlPoint1, Point2D controlPoint2) { _touch(); if (isEmptyImpl()) throw new GeometryException( "Invalid call. This operation cannot be performed on an empty geometry."); m_bPathStarted = false; int pathIndex = m_paths.size() - 2; byte pf = m_pathFlags.read(...
[ "public", "void", "closePathWithBezier", "(", "Point2D", "controlPoint1", ",", "Point2D", "controlPoint2", ")", "{", "_touch", "(", ")", ";", "if", "(", "isEmptyImpl", "(", ")", ")", "throw", "new", "GeometryException", "(", "\"Invalid call. This operation cannot be...
Closes last path of the MultiPathImpl with the Bezier Segment. The start point of the Bezier is the last point of the path and the last point of the bezier is the first point of the path.
[ "Closes", "last", "path", "of", "the", "MultiPathImpl", "with", "the", "Bezier", "Segment", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/MultiPathImpl.java#L524-L564
112,097
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/OperatorIntersectionCursor.java
OperatorIntersectionCursor.prepareVector_
GeometryCursor prepareVector_(VertexDescription descr, int dimensionMask, Geometry[] res_vec) { int inext = 0; if ((dimensionMask & 1) != 0) { if (res_vec[0] == null) res_vec[0] = new MultiPoint(descr); inext++; } else { for (int i = 0; i < res_vec.length - 1; i++) res_vec[i] = res_vec[i + 1];...
java
GeometryCursor prepareVector_(VertexDescription descr, int dimensionMask, Geometry[] res_vec) { int inext = 0; if ((dimensionMask & 1) != 0) { if (res_vec[0] == null) res_vec[0] = new MultiPoint(descr); inext++; } else { for (int i = 0; i < res_vec.length - 1; i++) res_vec[i] = res_vec[i + 1];...
[ "GeometryCursor", "prepareVector_", "(", "VertexDescription", "descr", ",", "int", "dimensionMask", ",", "Geometry", "[", "]", "res_vec", ")", "{", "int", "inext", "=", "0", ";", "if", "(", "(", "dimensionMask", "&", "1", ")", "!=", "0", ")", "{", "if", ...
as indicated with the dimensionMask
[ "as", "indicated", "with", "the", "dimensionMask" ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/OperatorIntersectionCursor.java#L141-L180
112,098
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/SweepComparator.java
SweepComparator.tryGetCachedEdge_
SimpleEdge tryGetCachedEdge_(int value) { SimpleEdge se = m_simple_edges_cache.get((value & NumberUtils.intMax()) % m_simple_edges_cache.size()); if (se != null) { if (se.m_value == value) return se; else { // int i = 0; // cache collision } } return null; }
java
SimpleEdge tryGetCachedEdge_(int value) { SimpleEdge se = m_simple_edges_cache.get((value & NumberUtils.intMax()) % m_simple_edges_cache.size()); if (se != null) { if (se.m_value == value) return se; else { // int i = 0; // cache collision } } return null; }
[ "SimpleEdge", "tryGetCachedEdge_", "(", "int", "value", ")", "{", "SimpleEdge", "se", "=", "m_simple_edges_cache", ".", "get", "(", "(", "value", "&", "NumberUtils", ".", "intMax", "(", ")", ")", "%", "m_simple_edges_cache", ".", "size", "(", ")", ")", ";"...
Returns a cached edge for the given value. May return NULL.
[ "Returns", "a", "cached", "edge", "for", "the", "given", "value", ".", "May", "return", "NULL", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/SweepComparator.java#L82-L94
112,099
Esri/geometry-api-java
src/main/java/com/esri/core/geometry/SweepComparator.java
SweepComparator.tryDeleteCachedEdge_
void tryDeleteCachedEdge_(int value) { int ind = (value & NumberUtils.intMax()) % m_simple_edges_cache.size(); SimpleEdge se = m_simple_edges_cache.get(ind); if (se != null && se.m_value == value) {// this value is cached m_simple_edges_recycle.add(se); m_simple_edges_cache.set(ind, null); } else { // ...
java
void tryDeleteCachedEdge_(int value) { int ind = (value & NumberUtils.intMax()) % m_simple_edges_cache.size(); SimpleEdge se = m_simple_edges_cache.get(ind); if (se != null && se.m_value == value) {// this value is cached m_simple_edges_recycle.add(se); m_simple_edges_cache.set(ind, null); } else { // ...
[ "void", "tryDeleteCachedEdge_", "(", "int", "value", ")", "{", "int", "ind", "=", "(", "value", "&", "NumberUtils", ".", "intMax", "(", ")", ")", "%", "m_simple_edges_cache", ".", "size", "(", ")", ";", "SimpleEdge", "se", "=", "m_simple_edges_cache", ".",...
Removes cached edge from the cache for the given value.
[ "Removes", "cached", "edge", "from", "the", "cache", "for", "the", "given", "value", "." ]
494da8ec953d76e7c6072afbc081abfe48ff07cf
https://github.com/Esri/geometry-api-java/blob/494da8ec953d76e7c6072afbc081abfe48ff07cf/src/main/java/com/esri/core/geometry/SweepComparator.java#L97-L106