fromJSON static method

Holds? fromJSON(
  1. Map<String, dynamic>? json
)

Creates an Holds from its JSON representation.

Implementation

static Holds? fromJSON(Map<String, dynamic>? json) {
  if (json == null) {
    return null;
  }
  return Holds(
      total: json.optPositiveInt("total"),
      position: json.optPositiveInt("position"));
}