public InsertOrReplace ( dynamic entity ) : void | ||
entity | dynamic | |
Результат | void |
public void Test04() { Credentials credentials = new Credentials(ACCOUNT_NAME, KEY); DynamicTableContext context = new DynamicTableContext(TABLE_NAME, credentials); dynamic item = new { PartitionKey = "1", RowKey = Guid.NewGuid().ToString(), Value = "Hello World" }; context.InsertOrReplace(item); }
public void Test04() { Credentials credentials = new Credentials(ACCOUNT_NAME, KEY); DynamicTableContext context = new DynamicTableContext(TABLE_NAME, credentials); dynamic item = new { PartitionKey = "1", RowKey = Guid.NewGuid().ToString(), Value = "Hello World" }; context.InsertOrReplace(item); }
public void Setup() { var account = new CloudStorageAccount(new StorageCredentialsAccountAndKey(ACCOUNT_NAME, KEY), false); var tableClient = account.CreateCloudTableClient(); tableClient.CreateTableIfNotExist(TABLE_NAME); var context = new DynamicTableContext(TABLE_NAME, new Credentials(ACCOUNT_NAME, KEY)); context.InsertOrReplace(new { PartitionKey = "1", RowKey = "1", Value1 = "TEST" }); }
public void Setup() { var account = new CloudStorageAccount(new StorageCredentialsAccountAndKey(ACCOUNT_NAME, KEY), false); var tableClient = account.CreateCloudTableClient(); tableClient.CreateTableIfNotExist(TABLE_NAME); var context = new DynamicTableContext(TABLE_NAME, new Credentials(ACCOUNT_NAME, KEY)); context.InsertOrReplace(new { PartitionKey = "1", RowKey = "1", Value1 = "TEST" }); }
public void Test07() { Credentials credentials = new Credentials(ACCOUNT_NAME, KEY); DynamicTableContext context = new DynamicTableContext(TABLE_NAME, credentials); var dictionary = new Dictionary <string, object>(); dictionary["PartitionKey"] = "2"; dictionary["RowKey"] = "2"; dictionary["Value3"] = "FooBar"; context.InsertOrReplace(dictionary); }
public void Test07() { Credentials credentials = new Credentials(ACCOUNT_NAME, KEY); DynamicTableContext context = new DynamicTableContext(TABLE_NAME, credentials); var dictionary = new Dictionary<string, object>(); dictionary["PartitionKey"] = "2"; dictionary["RowKey"] = "2"; dictionary["Value3"] = "FooBar"; context.InsertOrReplace(dictionary); }