public void CounterAsset(Asset asset) { _uriBuilder.SetQueryParam("counter_asset_type", asset.GetType()); if (asset is AssetTypeCreditAlphaNum) { AssetTypeCreditAlphaNum creditAlphaNumAsset = (AssetTypeCreditAlphaNum)asset; _uriBuilder.SetQueryParam("counter_asset_code", creditAlphaNumAsset.Code); _uriBuilder.SetQueryParam("counter_asset_issuer", creditAlphaNumAsset.Issuer.AccountId); } }
public TradesAggregationRequestBuilder CounterAsset(Asset asset) { _uriBuilder.SetQueryParam("counter_asset_type", asset.GetType()); if (asset is AssetTypeCreditAlphaNum) { AssetTypeCreditAlphaNum creditAlphaNumAsset = (AssetTypeCreditAlphaNum)asset; _uriBuilder.SetQueryParam("counter_asset_code", creditAlphaNumAsset.Code); _uriBuilder.SetQueryParam("counter_asset_issuer", creditAlphaNumAsset.Issuer.AccountId); } return(this); }
public TradesAggregationRequestBuilder BaseAsset(Asset asset) { UriBuilder.SetQueryParam("base_asset_type", asset.GetType()); if (asset is AssetTypeCreditAlphaNum) { AssetTypeCreditAlphaNum creditAlphaNumAsset = (AssetTypeCreditAlphaNum)asset; UriBuilder.SetQueryParam("base_asset_code", creditAlphaNumAsset.Code); UriBuilder.SetQueryParam("base_asset_issuer", creditAlphaNumAsset.Issuer); } return(this); }
public PathStrictReceiveRequestBuilder DestinationAsset(Asset asset) { UriBuilder.SetQueryParam("destination_asset_type", asset.GetType()); if (asset is AssetTypeCreditAlphaNum) { AssetTypeCreditAlphaNum creditAlphaNumAsset = (AssetTypeCreditAlphaNum)asset; UriBuilder.SetQueryParam("destination_asset_code", creditAlphaNumAsset.Code); UriBuilder.SetQueryParam("destination_asset_issuer", creditAlphaNumAsset.Issuer); } return(this); }
public PathStrictSendRequestBuilder SourceAsset(Asset asset) { UriBuilder.SetQueryParam("source_asset_type", asset.GetType()); if (asset is AssetTypeCreditAlphaNum) { AssetTypeCreditAlphaNum creditAlphaNumAsset = (AssetTypeCreditAlphaNum) asset; UriBuilder.SetQueryParam("source_asset_code", creditAlphaNumAsset.Code); UriBuilder.SetQueryParam("source_asset_issuer", creditAlphaNumAsset.Issuer); } return this; }
public PathsRequestBuilder DestinationAsset(Asset asset) { _uriBuilder.SetQueryParam("destination_asset_type", asset.GetType()); if (asset is AssetTypeCreditAlphaNum) { AssetTypeCreditAlphaNum creditAlphaNumAsset = (AssetTypeCreditAlphaNum)asset; _uriBuilder.SetQueryParam("destination_asset_code", creditAlphaNumAsset.Code); _uriBuilder.SetQueryParam("destination_asset_issuer", creditAlphaNumAsset.Issuer.AccountId); } return(this); }
private async Task InitializeWalletsAsync() { if (!_airDropWallet.IsInitialized) { await _airDropWallet.InitializeAsync(); } if (_playUSA == null || _playMONEY == null) { var rivalCoins = await Wallet.GetRivalCoinsAsync(_airDropWallet.Network); _playUSA = rivalCoins.FirstOrDefault(rivalCoin => rivalCoin.Asset.Code == "PlayUSA").Asset; _playMONEY = rivalCoins.FirstOrDefault(rivalCoin => rivalCoin.Asset.Code == "PlayMONEY").Asset; } }