SasPortalDeviceGrant.fromJson constructor

SasPortalDeviceGrant.fromJson(
  1. Map _json
)

Implementation

SasPortalDeviceGrant.fromJson(core.Map _json)
    : this(
        channelType: _json.containsKey('channelType')
            ? _json['channelType'] as core.String
            : null,
        expireTime: _json.containsKey('expireTime')
            ? _json['expireTime'] as core.String
            : null,
        frequencyRange: _json.containsKey('frequencyRange')
            ? SasPortalFrequencyRange.fromJson(_json['frequencyRange']
                as core.Map<core.String, core.dynamic>)
            : null,
        grantId: _json.containsKey('grantId')
            ? _json['grantId'] as core.String
            : null,
        maxEirp: _json.containsKey('maxEirp')
            ? (_json['maxEirp'] as core.num).toDouble()
            : null,
        moveList: _json.containsKey('moveList')
            ? (_json['moveList'] as core.List)
                .map<SasPortalDpaMoveList>((value) =>
                    SasPortalDpaMoveList.fromJson(
                        value as core.Map<core.String, core.dynamic>))
                .toList()
            : null,
        state:
            _json.containsKey('state') ? _json['state'] as core.String : null,
        suspensionReason: _json.containsKey('suspensionReason')
            ? (_json['suspensionReason'] as core.List)
                .map<core.String>((value) => value as core.String)
                .toList()
            : null,
      );