fromJson static method

PurchaseStore fromJson(
  1. String name
)

Implementation

static PurchaseStore fromJson(String name) {
  switch (name) {
    case 'appStore':
      return PurchaseStore.appStore;
    case 'playStore':
      return PurchaseStore.playStore;
    case 'stripe':
      return PurchaseStore.stripe;
    default:
      throw ArgumentError(
        'Value "$name" cannot be converted to "PurchaseStore"',
      );
  }
}