Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Override hashCode and overload == operator for GeoJSON types #45

Open
4 of 11 tasks
lukas-h opened this issue Dec 12, 2021 · 3 comments
Open
4 of 11 tasks

Override hashCode and overload == operator for GeoJSON types #45

lukas-h opened this issue Dec 12, 2021 · 3 comments
Assignees
Labels
blocking question Further information is requested

Comments

@lukas-h
Copy link
Member

lukas-h commented Dec 12, 2021

  • Position
  • BBox
  • Point
  • MultiPoint
  • LineString
  • MultiLineString
  • Polygon
  • MultiPolygon
  • GeometryCollection
  • Feature
  • FeatureCollection

as discussed in #43

@lukas-h lukas-h self-assigned this Dec 14, 2021
@lukas-h lukas-h added this to the Improve GeoJSON Core milestone Mar 2, 2022
@tobrun
Copy link
Collaborator

tobrun commented Mar 19, 2022

👍 on this issue, to be able to scale the functionality of this library, this is a must have feature.

For context, was adding a new functionality and couldn't easily compare two FeatureCollections:

GeoJSONObject actual = flip(GeoJSONObject.fromJson(json));
GeoJSONObject expected = GeoJSONObject.fromJson(flippedJson);
expect(actual, expected);

@lukas-h
Copy link
Member Author

lukas-h commented Jun 27, 2022

Hi @tobrun,

we are currently working on a separate library that offers equality functions for the more complex data types of geojson.
https://github.com/dartclub/turf_equality
The lib is based on: https://www.npmjs.com/package/geojson-equality

We have to find a way to combine the new lib into turf_dart at a later point.

And I still think it's a problem if we override == with a really performance hungry function that can compare e.g. highly nested FeatureCollections.

CC @armantorkzaban

@lukas-h
Copy link
Member Author

lukas-h commented Sep 11, 2022

–> DECISION: What should be done with booleanEqual?

@lukas-h lukas-h added the question Further information is requested label Sep 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocking question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants