fromJson<T> static method

dynamic fromJson<T>(
  1. Map<String, dynamic> json
)

Implementation

static dynamic fromJson<T>(Map<String, dynamic> json) {
  switch (T) {
    case AccountResponse:
      return AccountResponse.fromJson(json);
    case AssetResponse:
      return AssetResponse.fromJson(json);
    case EffectResponse:
      return EffectResponse.fromJson(json);
    case LedgerResponse:
      return LedgerResponse.fromJson(json);
    case OfferResponse:
      return OfferResponse.fromJson(json);
    case OrderBookResponse:
      return OrderBookResponse.fromJson(json);
    case OperationResponse:
      return OperationResponse.fromJson(json);
    case FeeStatsResponse:
      return FeeStatsResponse.fromJson(json);
    case PathResponse:
      return PathResponse.fromJson(json);
    case RootResponse:
      return RootResponse.fromJson(json);
    case SubmitTransactionResponse:
      return SubmitTransactionResponse.fromJson(json);
    case TradeAggregationResponse:
      return TradeAggregationResponse.fromJson(json);
    case TradeResponse:
      return TradeResponse.fromJson(json);
    case TransactionResponse:
      return TransactionResponse.fromJson(json);
    case FederationResponse:
      return FederationResponse.fromJson(json);
    case ClaimableBalanceResponse:
      return ClaimableBalanceResponse.fromJson(json);
    case ChallengeResponse:
      return ChallengeResponse.fromJson(json);
    case SubmitCompletedChallengeResponse:
      return SubmitCompletedChallengeResponse.fromJson(json);
    case DepositResponse:
      return DepositResponse.fromJson(json);
    case WithdrawResponse:
      return WithdrawResponse.fromJson(json);
    case InfoResponse:
      return InfoResponse.fromJson(json);
    case FeeResponse:
      return FeeResponse.fromJson(json);
    case AnchorTransactionsResponse:
      return AnchorTransactionsResponse.fromJson(json);
    case AnchorTransactionResponse:
      return AnchorTransactionResponse.fromJson(json);
    case GetCustomerInfoResponse:
      return GetCustomerInfoResponse.fromJson(json);
    case PutCustomerInfoResponse:
      return PutCustomerInfoResponse.fromJson(json);
    case LiquidityPoolResponse:
      return LiquidityPoolResponse.fromJson(json);
    case SEP24InfoResponse:
      return SEP24InfoResponse.fromJson(json);
    case SEP24FeeResponse:
      return SEP24FeeResponse.fromJson(json);
    case SEP24InteractiveResponse:
      return SEP24InteractiveResponse.fromJson(json);
    case SEP24TransactionsResponse:
      return SEP24TransactionsResponse.fromJson(json);
    case SEP24TransactionResponse:
      return SEP24TransactionResponse.fromJson(json);
  }

  switch (T.toString()) {
    case "Page<AccountResponse>":
      return Page<AccountResponse>.fromJson(json);
    case "Page<AssetResponse>":
      return Page<AssetResponse>.fromJson(json);
    case "Page<EffectResponse>":
      return Page<EffectResponse>.fromJson(json);
    case "Page<LedgerResponse>":
      return Page<LedgerResponse>.fromJson(json);
    case "Page<OfferResponse>":
      return Page<OfferResponse>.fromJson(json);
    case "Page<OrderBookResponse>":
      return Page<OrderBookResponse>.fromJson(json);
    case "Page<OperationResponse>":
      return Page<OperationResponse>.fromJson(json);
    case "Page<FeeStatsResponse>":
      return Page<FeeStatsResponse>.fromJson(json);
    case "Page<PathResponse>":
      return Page<PathResponse>.fromJson(json);
    case "Page<RootResponse>":
      return Page<RootResponse>.fromJson(json);
    case "Page<SubmitTransactionResponse>":
      return Page<SubmitTransactionResponse>.fromJson(json);
    case "Page<TradeAggregationResponse>":
      return Page<TradeAggregationResponse>.fromJson(json);
    case "Page<TradeResponse>":
      return Page<TradeResponse>.fromJson(json);
    case "Page<TransactionResponse>":
      return Page<TransactionResponse>.fromJson(json);
    case "Page<ClaimableBalanceResponse>":
      return Page<ClaimableBalanceResponse>.fromJson(json);
    case "Page<LiquidityPoolResponse>":
      return Page<LiquidityPoolResponse>.fromJson(json);
  }
}