Subscription.fromJson constructor

Subscription.fromJson(
  1. Map json_
)

Implementation

Subscription.fromJson(core.Map json_)
    : this(
        billingMethod: json_.containsKey('billingMethod')
            ? json_['billingMethod'] as core.String
            : null,
        creationTime: json_.containsKey('creationTime')
            ? json_['creationTime'] as core.String
            : null,
        customerDomain: json_.containsKey('customerDomain')
            ? json_['customerDomain'] as core.String
            : null,
        customerId: json_.containsKey('customerId')
            ? json_['customerId'] as core.String
            : null,
        dealCode: json_.containsKey('dealCode')
            ? json_['dealCode'] as core.String
            : null,
        kind: json_.containsKey('kind') ? json_['kind'] as core.String : null,
        plan: json_.containsKey('plan')
            ? SubscriptionPlan.fromJson(
                json_['plan'] as core.Map<core.String, core.dynamic>)
            : null,
        purchaseOrderId: json_.containsKey('purchaseOrderId')
            ? json_['purchaseOrderId'] as core.String
            : null,
        renewalSettings: json_.containsKey('renewalSettings')
            ? RenewalSettings.fromJson(json_['renewalSettings']
                as core.Map<core.String, core.dynamic>)
            : null,
        resourceUiUrl: json_.containsKey('resourceUiUrl')
            ? json_['resourceUiUrl'] as core.String
            : null,
        seats: json_.containsKey('seats')
            ? Seats.fromJson(
                json_['seats'] as core.Map<core.String, core.dynamic>)
            : null,
        skuId:
            json_.containsKey('skuId') ? json_['skuId'] as core.String : null,
        skuName: json_.containsKey('skuName')
            ? json_['skuName'] as core.String
            : null,
        status: json_.containsKey('status')
            ? json_['status'] as core.String
            : null,
        subscriptionId: json_.containsKey('subscriptionId')
            ? json_['subscriptionId'] as core.String
            : null,
        suspensionReasons: json_.containsKey('suspensionReasons')
            ? (json_['suspensionReasons'] as core.List)
                .map((value) => value as core.String)
                .toList()
            : null,
        transferInfo: json_.containsKey('transferInfo')
            ? SubscriptionTransferInfo.fromJson(
                json_['transferInfo'] as core.Map<core.String, core.dynamic>)
            : null,
        trialSettings: json_.containsKey('trialSettings')
            ? SubscriptionTrialSettings.fromJson(
                json_['trialSettings'] as core.Map<core.String, core.dynamic>)
            : null,
      );