toJson method
Converts this LocationConstraint object to a JSON object.
Each parameter of LocationConstraint corresponds to a key in the resulting JSON object.
Implementation
Map<String, dynamic> toJson() {
return {
'isRequired': isRequired,
'suggestLocation': suggestLocation,
'locations': locations?.map((e) => e?.toJson()).toList(),
};
}