Skip to content

Commit

Permalink
Fix native types (tests) regarding height getter of point.
Browse files Browse the repository at this point in the history
  • Loading branch information
meistermeier committed Dec 20, 2018
1 parent 13709b8 commit e2ee13e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public Point apply(AbstractPoint object) {
} else if (object instanceof GeographicPoint3d) {
GeographicPoint3d point = (GeographicPoint3d) object;
value = Values.point(point.getSrid(), point.getLongitude(), point.getLatitude(),
point.getElevation());
point.getHeight());
} else {
throw new IllegalArgumentException("Unsupported point implementation: " + object.getClass());
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public PointValue apply(AbstractPoint object) {
} else if (object instanceof GeographicPoint3d) {
GeographicPoint3d point = (GeographicPoint3d) object;
return Values.pointValue(CoordinateReferenceSystem.WGS84_3D, point.getLongitude(), point.getLatitude(),
point.getElevation());
point.getHeight());
} else {
throw new IllegalArgumentException("Unsupported point implementation: " + object.getClass());
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public void mappingShouldWork() {
Assertions.assertThat(point.getSrid()).isEqualTo(4979);
Assertions.assertThat(((GeographicPoint3d) point).getLatitude()).isEqualTo(20.0);
Assertions.assertThat(((GeographicPoint3d) point).getLongitude()).isEqualTo(10.0);
Assertions.assertThat(((GeographicPoint3d) point).getElevation()).isEqualTo(30.0);
Assertions.assertThat(((GeographicPoint3d) point).getHeight()).isEqualTo(30.0);

point = adapter.apply(Values.pointValue(CoordinateReferenceSystem.Cartesian_3D, 10.0, 20.0, 30));
Assertions.assertThat(point).isInstanceOf(CartesianPoint3d.class);
Expand Down

0 comments on commit e2ee13e

Please sign in to comment.