ListLocationsRequest.fromJson constructor

ListLocationsRequest.fromJson(
  1. Object? j
)

Implementation

factory ListLocationsRequest.fromJson(Object? j) {
  final json = j as Map<String, Object?>;
  return ListLocationsRequest(
    name: switch (json['name']) {
      null => '',
      Object $1 => decodeString($1),
    },
    filter: switch (json['filter']) {
      null => '',
      Object $1 => decodeString($1),
    },
    pageSize: switch (json['pageSize']) {
      null => 0,
      Object $1 => decodeInt($1),
    },
    pageToken: switch (json['pageToken']) {
      null => '',
      Object $1 => decodeString($1),
    },
  );
}