public Task <bool> CreateIfNotExistsAsync( string address) { var(partitionKey, rowKey) = GetKeys(address); var entity = new ObservableBalanceEntity { PartitionKey = partitionKey, RowKey = rowKey }; return(_observableAccountStates.CreateIfNotExistsAsync(entity)); }
public async Task <bool> TryAddAsync(string address) { var entity = new ObservableBalanceEntity { PartitionKey = GetPartitionKey(address), RowKey = GetRowKey(address), Address = address, Amount = 0, BlockNumber = 0 }; return(await _table.TryInsertAsync(entity)); }