You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current implementation of GeoJsonDataSource does not give any way to dynamically load features in multiple batches, because it always clears the entity collection when load is called. CzmlDataSource offers a process method which simply calls the underlying (private) load method without clearing existing entities. This method should be added to GeoJsonDataSource for consistency.
(I previously had a comment here about doing the same thing for KmlDataSource, but on reflection that doesn't make sense. CZML and GeoJson are based on packets/features and it makes sense to support stream-wise loading; KML is a document format that usually includes e.g. style references and it makes sense to only support loading when the whole thing is available.)
The text was updated successfully, but these errors were encountered:
I put together a simple PR adding this to GeoJsonDataSource, because it was trivial. I'm reasonably confident that the current implementation will handle processing various kinds of input without inducing any weird behavior. I added one test, to call load with some features, and then process with additional features, and that works. More tests could be added to poke at edge cases but I suspect it's fine. (The team could of course have insight to the contrary!)
thw0rted
changed the title
All file-based data sources should have a process method similar to CzmlDataSourceGeoJsonDataSource should have a process method similar to CzmlDataSource
Dec 10, 2020
The current implementation of
GeoJsonDataSource
does not give any way to dynamically load features in multiple batches, because it always clears the entity collection whenload
is called.CzmlDataSource
offers aprocess
method which simply calls the underlying (private)load
method without clearing existing entities. This method should be added toGeoJsonDataSource
for consistency.(I previously had a comment here about doing the same thing for
KmlDataSource
, but on reflection that doesn't make sense. CZML and GeoJson are based on packets/features and it makes sense to support stream-wise loading; KML is a document format that usually includes e.g. style references and it makes sense to only support loading when the whole thing is available.)The text was updated successfully, but these errors were encountered: