Skip to content

Commit

Permalink
Improve GeometryCollectionDimension hasDimension code
Browse files Browse the repository at this point in the history
  • Loading branch information
dr-jts committed Dec 20, 2024
1 parent 7665d6f commit 9133b47
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,11 @@ private void init(GeometryCollection coll) {
}

public boolean hasDimension(int dim) {
if (dim == Dimension.A && hasA) return true;
if (dim == Dimension.L && hasL) return true;
if (dim == Dimension.P && hasP) return true;
switch (dim) {
case Dimension.A: return hasA;
case Dimension.L: return hasL;
case Dimension.P: return hasP;
}
return false;
}

Expand Down

0 comments on commit 9133b47

Please sign in to comment.