SubstitutionRule.fromJson constructor

SubstitutionRule.fromJson(
  1. Map json_
)

Implementation

SubstitutionRule.fromJson(core.Map json_)
    : this(
        newValue: json_.containsKey('newValue')
            ? json_['newValue'] as core.String
            : null,
        originalValuePattern: json_.containsKey('originalValuePattern')
            ? json_['originalValuePattern'] as core.String
            : null,
        targetGroupKinds: json_.containsKey('targetGroupKinds')
            ? (json_['targetGroupKinds'] as core.List)
                .map((value) => GroupKind.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        targetJsonPath: json_.containsKey('targetJsonPath')
            ? json_['targetJsonPath'] as core.String
            : null,
        targetNamespaces: json_.containsKey('targetNamespaces')
            ? (json_['targetNamespaces'] as core.List)
                .map((value) => value as core.String)
                .toList()
            : null,
      );