public async Task AddVersion(OwnershipRegistration registration, OwnershipOwner owner, string version)
 {
     CloudTableClient client = _account.CreateCloudTableClient();
     CloudTable table = client.GetTableReference(OwnershipTableName);
     TableBatchOperation batch = new TableBatchOperation();
     batch.InsertOrReplace(new TypedEntity(registration.GetKey(), owner.GetKey(), OwnerType));
     batch.InsertOrReplace(new TypedEntity(registration.GetKey(), version, PackageType));
     await table.ExecuteBatchAsync(batch);
 }
示例#2
0
        public async Task AddVersion(OwnershipRegistration registration, OwnershipOwner owner, string version)
        {
            CloudTableClient    client = _account.CreateCloudTableClient();
            CloudTable          table  = client.GetTableReference(OwnershipTableName);
            TableBatchOperation batch  = new TableBatchOperation();

            batch.InsertOrReplace(new TypedEntity(registration.GetKey(), owner.GetKey(), OwnerType));
            batch.InsertOrReplace(new TypedEntity(registration.GetKey(), version, PackageType));
            await table.ExecuteBatchAsync(batch);
        }
 public async Task AddOwner(OwnershipRegistration registration, OwnershipOwner owner)
 {
     CloudTableClient client = _account.CreateCloudTableClient();
     CloudTable table = client.GetTableReference(OwnershipTableName);
     TableOperation operation = TableOperation.InsertOrReplace(new TypedEntity(registration.GetKey(), owner.GetKey(), OwnerType));
     await table.ExecuteAsync(operation);
 }
示例#4
0
 public Task <bool> HasVersion(OwnershipRegistration registration, string version)
 {
     return(ExistsAsync(_account, registration.GetKey(), version));
 }
示例#5
0
 public Task <bool> HasRegistration(OwnershipRegistration registration)
 {
     return(ExistsAsync(_account, registration.GetKey()));
 }
示例#6
0
 public Task <bool> HasOwner(OwnershipRegistration registration, OwnershipOwner owner)
 {
     return(ExistsAsync(_account, registration.GetKey(), owner.GetKey()));
 }
示例#7
0
 public async Task AddOwner(OwnershipRegistration registration, OwnershipOwner owner)
 {
     CloudTableClient client    = _account.CreateCloudTableClient();
     CloudTable       table     = client.GetTableReference(OwnershipTableName);
     TableOperation   operation = TableOperation.InsertOrReplace(new TypedEntity(registration.GetKey(), owner.GetKey(), OwnerType));
     await table.ExecuteAsync(operation);
 }
 public Task<bool> HasVersion(OwnershipRegistration registration, string version)
 {
     return ExistsAsync(_account, registration.GetKey(), version);
 }
 public Task<bool> HasRegistration(OwnershipRegistration registration)
 {
     return ExistsAsync(_account, registration.GetKey());
 }
 public Task<bool> HasOwner(OwnershipRegistration registration, OwnershipOwner owner)
 {
     return ExistsAsync(_account, registration.GetKey(), owner.GetKey());
 }