RelativeRotaryLastEvent.fromJson constructor

RelativeRotaryLastEvent.fromJson(
  1. Map<String, dynamic> dataMap
)

Creates a RelativeRotaryLastEvent object from the JSON response to a GET request.

Implementation

factory RelativeRotaryLastEvent.fromJson(Map<String, dynamic> dataMap) {
  return RelativeRotaryLastEvent(
      action: dataMap[ApiFields.action] ?? "",
      rotation:
          RelativeRotaryRotation.fromJson(dataMap[ApiFields.rotation] ?? {}));
}