OSPolicy.fromJson constructor

OSPolicy.fromJson(
  1. Map _json
)

Implementation

OSPolicy.fromJson(core.Map _json)
    : this(
        allowNoResourceGroupMatch:
            _json.containsKey('allowNoResourceGroupMatch')
                ? _json['allowNoResourceGroupMatch'] as core.bool
                : null,
        description: _json.containsKey('description')
            ? _json['description'] as core.String
            : null,
        id: _json.containsKey('id') ? _json['id'] as core.String : null,
        mode: _json.containsKey('mode') ? _json['mode'] as core.String : null,
        resourceGroups: _json.containsKey('resourceGroups')
            ? (_json['resourceGroups'] as core.List)
                .map<OSPolicyResourceGroup>((value) =>
                    OSPolicyResourceGroup.fromJson(
                        value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
      );