Exportar (0) Imprimir
Expandir Tudo

Método CloudTableClient.EndDeleteTableIfExist

[Este tópico é uma documentação de pré-lançamento e está sujeito a alterações em versões futuras. Os tópicos em branco são incluídos como espaços reservados.]

Ends an asynchronous operation to delete the tables if it exists.

Namespace: Microsoft.WindowsAzure.StorageClient
Assembly: Microsoft.WindowsAzure.StorageClient (em microsoft.windowsazure.storageclient.dll)

'Uso
Dim instance As CloudTableClient
Dim asyncResult As IAsyncResult
Dim returnValue As Boolean

returnValue = instance.EndDeleteTableIfExist(asyncResult)

public bool EndDeleteTableIfExist (
	IAsyncResult asyncResult
)
public boolean EndDeleteTableIfExist (
	IAsyncResult asyncResult
)
public function EndDeleteTableIfExist (
	asyncResult : IAsyncResult
) : boolean

Parâmetros

asyncResult

An IAsyncResult that references the pending asynchronous operation.

Valor retornado

true if the table was deleted; otherwise, false.

The following code example deletes a table asynchronously if it exists.

public static void DeleteTableIfExistsAsync(CloudStorageAccount storageAccount)
{
    // Create service client for credentialed access to the Table service.
    CloudTableClient tableClient = new CloudTableClient(storageAccount.TableEndpoint.ToString(),
        storageAccount.Credentials);

    tableClient.BeginDeleteTable("Categories", DeleteTableIfExistsAsyncCallback, tableClient);
}

public static void DeleteTableIfExistsAsyncCallback(IAsyncResult result)
{
    CloudTableClient tableClient = (CloudTableClient)result.AsyncState;

    // End the operation.
    if (tableClient.EndDeleteTableIfExist(result))
    {
        Console.WriteLine("Table deleted.");
    }
    else
    {
        Console.WriteLine("Table does not exist and so could not be deleted.");
    }
}


Todos os membros estáticos públicos (Compartilhados no Visual Basic) desse tipo são thread-safe. Quaisquer membros de instância não têm garantia de ser thread-safe.

Plataformas de desenvolvimento

Windows XP Professional com Service Pack 2 (SP2)

Plataformas de destino

Contribuições da comunidade

Mostrar:
© 2014 Microsoft