GoogleCloudPaymentsResellerSubscriptionV1Subscription.fromJson constructor Null safety

GoogleCloudPaymentsResellerSubscriptionV1Subscription.fromJson(
  1. Map _json
)

Implementation

GoogleCloudPaymentsResellerSubscriptionV1Subscription.fromJson(core.Map _json)
    : this(
        cancellationDetails: _json.containsKey('cancellationDetails')
            ? GoogleCloudPaymentsResellerSubscriptionV1SubscriptionCancellationDetails
                .fromJson(_json['cancellationDetails']
                    as core.Map<core.String, core.dynamic>)
            : null,
        createTime: _json.containsKey('createTime')
            ? _json['createTime'] as core.String
            : null,
        cycleEndTime: _json.containsKey('cycleEndTime')
            ? _json['cycleEndTime'] as core.String
            : null,
        endUserEntitled: _json.containsKey('endUserEntitled')
            ? _json['endUserEntitled'] as core.bool
            : null,
        freeTrialEndTime: _json.containsKey('freeTrialEndTime')
            ? _json['freeTrialEndTime'] as core.String
            : null,
        name: _json.containsKey('name') ? _json['name'] as core.String : null,
        partnerUserToken: _json.containsKey('partnerUserToken')
            ? _json['partnerUserToken'] as core.String
            : null,
        processingState: _json.containsKey('processingState')
            ? _json['processingState'] as core.String
            : null,
        products: _json.containsKey('products')
            ? (_json['products'] as core.List)
                .map((value) => value as core.String)
                .toList()
            : null,
        promotions: _json.containsKey('promotions')
            ? (_json['promotions'] as core.List)
                .map((value) => value as core.String)
                .toList()
            : null,
        redirectUri: _json.containsKey('redirectUri')
            ? _json['redirectUri'] as core.String
            : null,
        serviceLocation: _json.containsKey('serviceLocation')
            ? GoogleCloudPaymentsResellerSubscriptionV1Location.fromJson(
                _json['serviceLocation']
                    as core.Map<core.String, core.dynamic>)
            : null,
        state:
            _json.containsKey('state') ? _json['state'] as core.String : null,
        updateTime: _json.containsKey('updateTime')
            ? _json['updateTime'] as core.String
            : null,
        upgradeDowngradeDetails: _json.containsKey('upgradeDowngradeDetails')
            ? GoogleCloudPaymentsResellerSubscriptionV1SubscriptionUpgradeDowngradeDetails
                .fromJson(_json['upgradeDowngradeDetails']
                    as core.Map<core.String, core.dynamic>)
            : null,
      );