ResponsePolicy.fromJson constructor

ResponsePolicy.fromJson(
  1. Map json_
)

Implementation

ResponsePolicy.fromJson(core.Map json_)
    : this(
        description: json_.containsKey('description')
            ? json_['description'] as core.String
            : null,
        gkeClusters: json_.containsKey('gkeClusters')
            ? (json_['gkeClusters'] as core.List)
                .map((value) => ResponsePolicyGKECluster.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        id: json_.containsKey('id') ? json_['id'] as core.String : null,
        kind: json_.containsKey('kind') ? json_['kind'] as core.String : null,
        labels: json_.containsKey('labels')
            ? (json_['labels'] as core.Map<core.String, core.dynamic>).map(
                (key, value) => core.MapEntry(
                  key,
                  value as core.String,
                ),
              )
            : null,
        networks: json_.containsKey('networks')
            ? (json_['networks'] as core.List)
                .map((value) => ResponsePolicyNetwork.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        responsePolicyName: json_.containsKey('responsePolicyName')
            ? json_['responsePolicyName'] as core.String
            : null,
      );