OSPolicyAssignment.fromJson constructor

OSPolicyAssignment.fromJson(
  1. Map _json
)

Implementation

OSPolicyAssignment.fromJson(core.Map _json)
    : this(
        baseline: _json.containsKey('baseline')
            ? _json['baseline'] as core.bool
            : null,
        deleted: _json.containsKey('deleted')
            ? _json['deleted'] as core.bool
            : null,
        description: _json.containsKey('description')
            ? _json['description'] as core.String
            : null,
        etag: _json.containsKey('etag') ? _json['etag'] as core.String : null,
        instanceFilter: _json.containsKey('instanceFilter')
            ? OSPolicyAssignmentInstanceFilter.fromJson(
                _json['instanceFilter']
                    as core.Map<core.String, core.dynamic>)
            : null,
        name: _json.containsKey('name') ? _json['name'] as core.String : null,
        osPolicies: _json.containsKey('osPolicies')
            ? (_json['osPolicies'] as core.List)
                .map<OSPolicy>((value) => OSPolicy.fromJson(
                    value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        reconciling: _json.containsKey('reconciling')
            ? _json['reconciling'] as core.bool
            : null,
        revisionCreateTime: _json.containsKey('revisionCreateTime')
            ? _json['revisionCreateTime'] as core.String
            : null,
        revisionId: _json.containsKey('revisionId')
            ? _json['revisionId'] as core.String
            : null,
        rollout: _json.containsKey('rollout')
            ? OSPolicyAssignmentRollout.fromJson(
                _json['rollout'] as core.Map<core.String, core.dynamic>)
            : null,
        rolloutState: _json.containsKey('rolloutState')
            ? _json['rolloutState'] as core.String
            : null,
        uid: _json.containsKey('uid') ? _json['uid'] as core.String : null,
      );