BackendRule.fromJson constructor

BackendRule.fromJson(
  1. Map json_
)

Implementation

BackendRule.fromJson(core.Map json_)
    : this(
        address: json_.containsKey('address')
            ? json_['address'] as core.String
            : null,
        deadline: json_.containsKey('deadline')
            ? (json_['deadline'] as core.num).toDouble()
            : null,
        disableAuth: json_.containsKey('disableAuth')
            ? json_['disableAuth'] as core.bool
            : null,
        jwtAudience: json_.containsKey('jwtAudience')
            ? json_['jwtAudience'] as core.String
            : null,
        minDeadline: json_.containsKey('minDeadline')
            ? (json_['minDeadline'] as core.num).toDouble()
            : null,
        operationDeadline: json_.containsKey('operationDeadline')
            ? (json_['operationDeadline'] as core.num).toDouble()
            : null,
        overridesByRequestProtocol:
            json_.containsKey('overridesByRequestProtocol')
                ? (json_['overridesByRequestProtocol']
                        as core.Map<core.String, core.dynamic>)
                    .map(
                    (key, value) => core.MapEntry(
                      key,
                      BackendRule.fromJson(
                          value as core.Map<core.String, core.dynamic>),
                    ),
                  )
                : null,
        pathTranslation: json_.containsKey('pathTranslation')
            ? json_['pathTranslation'] as core.String
            : null,
        protocol: json_.containsKey('protocol')
            ? json_['protocol'] as core.String
            : null,
        selector: json_.containsKey('selector')
            ? json_['selector'] as core.String
            : null,
      );