LocationPolicyLocation.fromJson constructor

LocationPolicyLocation.fromJson(
  1. Object? j
)

Implementation

factory LocationPolicyLocation.fromJson(Object? j) {
  final json = j as Map<String, Object?>;
  return LocationPolicyLocation(
    constraints: switch (json['constraints']) {
      null => null,
      Object $1 => LocationPolicyLocationConstraints.fromJson($1),
    },
    preference: switch (json['preference']) {
      null => null,
      Object $1 => decodeString($1),
    },
  );
}