Closed FObermaier closed 2 years ago
This question on stackoverflow revealed that there is an issue with serializing IFeature implementing classes that are
IFeature
FeatureCollection
Feature
The issue is, that FeatureCollectionConverter attempts to copy the features to a Feature[]. The features should be copied to a IFeature[]: https://github.com/NetTopologySuite/NetTopologySuite.IO.GeoJSON/blob/2019c648aa726441cf89ed45cc2ab4b305de3acf/src/NetTopologySuite.IO.GeoJSON/Converters/FeatureCollectionConverter.cs#L45-L48
FeatureCollectionConverter
Feature[]
IFeature[]
@FObermaier this issue can be closed, right?
Fixed with 13fab6fa0ef2ae6d12f763b5ae616f5b7e83cfac
This question on stackoverflow revealed that there is an issue with serializing
IFeature
implementing classes that areFeatureCollection
,Feature
The issue is, that
FeatureCollectionConverter
attempts to copy the features to aFeature[]
. The features should be copied to aIFeature[]
: https://github.com/NetTopologySuite/NetTopologySuite.IO.GeoJSON/blob/2019c648aa726441cf89ed45cc2ab4b305de3acf/src/NetTopologySuite.IO.GeoJSON/Converters/FeatureCollectionConverter.cs#L45-L48