toJson abstract method
Returns data as an encodable object compatible with json.encode()
.
The returned JSON Object contains an optional identifier in "id" and the required properties (JSON Object) in "properties".
Implementation
Map<String, Object?> toJson();