The application I'm working on captures the users attribute edits in a graphic object that is then pushed into a FeatureSet. Then that FeatureSet is converted to JSON using FeatureSet.toJson method.
If I have a FeatureSet with no Geometry, the method returns a null pointer exception.
But if there is a geometry in there it has no problem.
What is is going on? Shouldn't the FeatureSet.toJson method work even if I do not have geometry?
My current workaround is to pass in the existing geometry, but that seems totally inefficient, when I send the updates it will send the geometry and attributes, all I need to send is the attribute updates... I guess I'll need another workaround to pull only the attributes to that featureSet before it is pushed to the server.