decode static method

Subscription decode(
  1. Object result
)

Implementation

static Subscription decode(Object result) {
  result as List<Object?>;
  return Subscription(
    subscriptionPeriod: result[0] != null
        ? SubscriptionPeriod.decode(result[0]! as List<Object?>)
        : null,
    freeTrialPeriod: result[1] != null
        ? SubscriptionPeriod.decode(result[1]! as List<Object?>)
        : null,
    gracePeriod: result[2] != null
        ? SubscriptionPeriod.decode(result[2]! as List<Object?>)
        : null,
    introductoryPrice: result[3] as String?,
    introductoryPriceAmount: result[4] as String?,
    introductoryPricePeriod: result[5] != null
        ? SubscriptionPeriod.decode(result[5]! as List<Object?>)
        : null,
  );
}