azure-docs-sdk-java/docs-ref-autogen/com.azure.data.tables.Table...

264 строки
43 KiB
YAML

### YamlMime:JavaType
uid: "com.azure.data.tables.TableServiceAsyncClient"
fullName: "com.azure.data.tables.TableServiceAsyncClient"
name: "TableServiceAsyncClient"
nameWithType: "TableServiceAsyncClient"
summary: "Provides an asynchronous service client for accessing the Azure Tables service."
inheritances:
- "<xref href=\"java.lang.Object?displayProperty=fullName\" data-throw-if-not-resolved=\"False\" />"
inheritedClassMethods:
- classRef: "java.lang.<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html\">Object</a>"
methodsRef:
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#clone--\">clone</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#equals-java.lang.Object-\">equals</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#finalize--\">finalize</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#getClass--\">getClass</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#hashCode--\">hashCode</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#notify--\">notify</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#notifyAll--\">notifyAll</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#toString--\">toString</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#wait--\">wait</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#wait-long-\">wait</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#wait-long-int-\">wait</a>"
syntax: "public final class **TableServiceAsyncClient**"
methods:
- uid: "com.azure.data.tables.TableServiceAsyncClient.createTable(java.lang.String)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.createTable(String tableName)"
name: "createTable(String tableName)"
nameWithType: "TableServiceAsyncClient.createTable(String tableName)"
summary: "Creates a table within the Tables service."
parameters:
- description: "The name of the table to create."
name: "tableName"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public Mono<TableAsyncClient> createTable(String tableName)"
desc: "Creates a table within the Tables service.\n\n**Code Samples**\n\nCreates a table. Prints out the details of the created table.\n\n```java\ntableServiceAsyncClient.createTable(\"myTable\")\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(tableAsyncClient ->\n System.out.printf(\"Table with name '%s' was created.\", tableAsyncClient.getTableName()));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing a <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> for the created table."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.data.tables.TableAsyncClient?alt=com.azure.data.tables.TableAsyncClient&text=TableAsyncClient\" data-throw-if-not-resolved=\"False\" />&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.createTableIfNotExists(java.lang.String)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.createTableIfNotExists(String tableName)"
name: "createTableIfNotExists(String tableName)"
nameWithType: "TableServiceAsyncClient.createTableIfNotExists(String tableName)"
summary: "Creates a table within the Tables service if the table does not already exist."
parameters:
- description: "The name of the table to create."
name: "tableName"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public Mono<TableAsyncClient> createTableIfNotExists(String tableName)"
desc: "Creates a table within the Tables service if the table does not already exist. If the table already exists, a <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> for the existing table is returned.\n\n**Code Samples**\n\nCreates a table if it does not already exist. Prints out the details of the created table.\n\n```java\ntableServiceAsyncClient.createTableIfNotExists(\"myTable\")\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(tableAsyncClient ->\n System.out.printf(\"Table with name '%s' was created.\", tableAsyncClient.getTableName()));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing a <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> for the created table."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.data.tables.TableAsyncClient?alt=com.azure.data.tables.TableAsyncClient&text=TableAsyncClient\" data-throw-if-not-resolved=\"False\" />&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.createTableIfNotExistsWithResponse(java.lang.String)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.createTableIfNotExistsWithResponse(String tableName)"
name: "createTableIfNotExistsWithResponse(String tableName)"
nameWithType: "TableServiceAsyncClient.createTableIfNotExistsWithResponse(String tableName)"
summary: "Creates a table within the Tables service if the table does not already exist."
parameters:
- description: "The name of the table to create."
name: "tableName"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public Mono<Response<TableAsyncClient>> createTableIfNotExistsWithResponse(String tableName)"
desc: "Creates a table within the Tables service if the table does not already exist. If the table already exists, a <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> for the existing table is returned.\n\n**Code Samples**\n\nCreates a table if it does not already exist. Prints out the details of the created table.\n\n```java\ntableServiceAsyncClient.createTableIfNotExistsWithResponse(\"myTable\")\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(response ->\n System.out.printf(\"Response successful with status code: %d. Table with name '%s' was created.\",\n response.getStatusCode(), response.getValue().getTableName()));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref> that in turn contains a\n <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> for the created table."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.core.http.rest.Response?alt=com.azure.core.http.rest.Response&text=Response\" data-throw-if-not-resolved=\"False\" />&lt;<xref href=\"com.azure.data.tables.TableAsyncClient?alt=com.azure.data.tables.TableAsyncClient&text=TableAsyncClient\" data-throw-if-not-resolved=\"False\" />&gt;&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.createTableWithResponse(java.lang.String)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.createTableWithResponse(String tableName)"
name: "createTableWithResponse(String tableName)"
nameWithType: "TableServiceAsyncClient.createTableWithResponse(String tableName)"
summary: "Creates a table within the Tables service."
parameters:
- description: "The name of the table to create."
name: "tableName"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public Mono<Response<TableAsyncClient>> createTableWithResponse(String tableName)"
desc: "Creates a table within the Tables service.\n\n**Code Samples**\n\nCreates a table. Prints out the details of the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref> and the created table.\n\n```java\ntableServiceAsyncClient.createTableWithResponse(\"myTable\")\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(response ->\n System.out.printf(\"Response successful with status code: %d. Table with name '%s' was created.\",\n response.getStatusCode(), response.getValue().getTableName()));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref> that in turn contains a\n <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> for the created table."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.core.http.rest.Response?alt=com.azure.core.http.rest.Response&text=Response\" data-throw-if-not-resolved=\"False\" />&lt;<xref href=\"com.azure.data.tables.TableAsyncClient?alt=com.azure.data.tables.TableAsyncClient&text=TableAsyncClient\" data-throw-if-not-resolved=\"False\" />&gt;&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.deleteTable(java.lang.String)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.deleteTable(String tableName)"
name: "deleteTable(String tableName)"
nameWithType: "TableServiceAsyncClient.deleteTable(String tableName)"
summary: "Deletes a table within the Tables service."
parameters:
- description: "The name of the table to delete."
name: "tableName"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public Mono<Void> deleteTable(String tableName)"
desc: "Deletes a table within the Tables service.\n\n**Code Samples**\n\nDeletes a table.\n\n```java\ntableServiceAsyncClient.deleteTable(\"myTable\")\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(unused ->\n System.out.printf(\"Table with name '%s' was deleted.\", \"myTable\"));\n```"
returns:
description: "An empty <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref>."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Void.html\">Void</a>&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.deleteTableWithResponse(java.lang.String)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.deleteTableWithResponse(String tableName)"
name: "deleteTableWithResponse(String tableName)"
nameWithType: "TableServiceAsyncClient.deleteTableWithResponse(String tableName)"
summary: "Deletes a table within the Tables service."
parameters:
- description: "The name of the table to delete."
name: "tableName"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public Mono<Response<Void>> deleteTableWithResponse(String tableName)"
desc: "Deletes a table within the Tables service.\n\n**Code Samples**\n\nDeletes a table.\n\n```java\ntableServiceAsyncClient.deleteTableWithResponse(\"myTable\")\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(response ->\n System.out.printf(\"Response successful with status code: %d. Table with name '%s' was deleted.\",\n response.getStatusCode(), \"myTable\"));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref>."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.core.http.rest.Response?alt=com.azure.core.http.rest.Response&text=Response\" data-throw-if-not-resolved=\"False\" />&lt;<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Void.html\">Void</a>&gt;&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.generateAccountSas(com.azure.data.tables.sas.TableAccountSasSignatureValues)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.generateAccountSas(TableAccountSasSignatureValues tableAccountSasSignatureValues)"
name: "generateAccountSas(TableAccountSasSignatureValues tableAccountSasSignatureValues)"
nameWithType: "TableServiceAsyncClient.generateAccountSas(TableAccountSasSignatureValues tableAccountSasSignatureValues)"
summary: "Generates an account SAS for the Azure Storage account using the specified <xref uid=\"com.azure.data.tables.sas.TableAccountSasSignatureValues\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAccountSasSignatureValues\"></xref>."
parameters:
- description: "<xref uid=\"com.azure.data.tables.sas.TableAccountSasSignatureValues\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAccountSasSignatureValues\"></xref>."
name: "tableAccountSasSignatureValues"
type: "<xref href=\"com.azure.data.tables.sas.TableAccountSasSignatureValues?alt=com.azure.data.tables.sas.TableAccountSasSignatureValues&text=TableAccountSasSignatureValues\" data-throw-if-not-resolved=\"False\" />"
syntax: "public String generateAccountSas(TableAccountSasSignatureValues tableAccountSasSignatureValues)"
desc: "Generates an account SAS for the Azure Storage account using the specified <xref uid=\"com.azure.data.tables.sas.TableAccountSasSignatureValues\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAccountSasSignatureValues\"></xref>.\n\n**Note:** The client must be authenticated via <xref uid=\"\" data-throw-if-not-resolved=\"false\" data-raw-source=\"AzureNamedKeyCredential\"></xref>.\n\nSee <xref uid=\"com.azure.data.tables.sas.TableAccountSasSignatureValues\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAccountSasSignatureValues\"></xref> for more information on how to construct an account SAS."
returns:
description: "A <code>String</code> representing the SAS query parameters."
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
- uid: "com.azure.data.tables.TableServiceAsyncClient.getAccountName()"
fullName: "com.azure.data.tables.TableServiceAsyncClient.getAccountName()"
name: "getAccountName()"
nameWithType: "TableServiceAsyncClient.getAccountName()"
summary: "Gets the name of the account containing the table."
syntax: "public String getAccountName()"
desc: "Gets the name of the account containing the table."
returns:
description: "The name of the account containing the table."
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
- uid: "com.azure.data.tables.TableServiceAsyncClient.getProperties()"
fullName: "com.azure.data.tables.TableServiceAsyncClient.getProperties()"
name: "getProperties()"
nameWithType: "TableServiceAsyncClient.getProperties()"
summary: "Gets the properties of the account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules."
syntax: "public Mono<TableServiceProperties> getProperties()"
desc: "Gets the properties of the account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules.\n\nThis operation is only supported on Azure Storage endpoints.\n\n**Code Samples**\n\nGets the properties of the account's Table service.\n\n```java\ntableServiceAsyncClient.getProperties()\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(properties -> System.out.print(\"Retrieved service properties successfully.\"));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing the <xref uid=\"com.azure.data.tables.models.TableServiceProperties\" data-throw-if-not-resolved=\"false\" data-raw-source=\"properties\"></xref> of the account's Table service."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.data.tables.models.TableServiceProperties?alt=com.azure.data.tables.models.TableServiceProperties&text=TableServiceProperties\" data-throw-if-not-resolved=\"False\" />&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.getPropertiesWithResponse()"
fullName: "com.azure.data.tables.TableServiceAsyncClient.getPropertiesWithResponse()"
name: "getPropertiesWithResponse()"
nameWithType: "TableServiceAsyncClient.getPropertiesWithResponse()"
summary: "Gets the properties of the account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules."
syntax: "public Mono<Response<TableServiceProperties>> getPropertiesWithResponse()"
desc: "Gets the properties of the account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules.\n\nThis operation is only supported on Azure Storage endpoints.\n\n**Code Samples**\n\nGets the properties of the account's Table service. Prints out the details of the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref>.\n\n```java\ntableServiceAsyncClient.getPropertiesWithResponse()\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(response ->\n System.out.printf(\"Retrieved service properties successfully with status code: %d.\",\n response.getStatusCode()));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref> that in turn contains the\n <xref uid=\"com.azure.data.tables.models.TableServiceProperties\" data-throw-if-not-resolved=\"false\" data-raw-source=\"properties\"></xref> of the account's Table service."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.core.http.rest.Response?alt=com.azure.core.http.rest.Response&text=Response\" data-throw-if-not-resolved=\"False\" />&lt;<xref href=\"com.azure.data.tables.models.TableServiceProperties?alt=com.azure.data.tables.models.TableServiceProperties&text=TableServiceProperties\" data-throw-if-not-resolved=\"False\" />&gt;&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.getServiceEndpoint()"
fullName: "com.azure.data.tables.TableServiceAsyncClient.getServiceEndpoint()"
name: "getServiceEndpoint()"
nameWithType: "TableServiceAsyncClient.getServiceEndpoint()"
summary: "Gets the endpoint for the Tables service."
syntax: "public String getServiceEndpoint()"
desc: "Gets the endpoint for the Tables service."
returns:
description: "The endpoint for the Tables service."
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
- uid: "com.azure.data.tables.TableServiceAsyncClient.getServiceVersion()"
fullName: "com.azure.data.tables.TableServiceAsyncClient.getServiceVersion()"
name: "getServiceVersion()"
nameWithType: "TableServiceAsyncClient.getServiceVersion()"
summary: "Gets the REST API version used by this client."
syntax: "public TableServiceVersion getServiceVersion()"
desc: "Gets the REST API version used by this client."
returns:
description: "The REST API version used by this client."
type: "<xref href=\"com.azure.data.tables.TableServiceVersion?alt=com.azure.data.tables.TableServiceVersion&text=TableServiceVersion\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.azure.data.tables.TableServiceAsyncClient.getStatistics()"
fullName: "com.azure.data.tables.TableServiceAsyncClient.getStatistics()"
name: "getStatistics()"
nameWithType: "TableServiceAsyncClient.getStatistics()"
summary: "Retrieves statistics related to replication for the account's Table service."
syntax: "public Mono<TableServiceStatistics> getStatistics()"
desc: "Retrieves statistics related to replication for the account's Table service. It is only available on the secondary location endpoint when read-access geo-redundant replication is enabled for the account.\n\nThis operation is only supported on Azure Storage endpoints.\n\n**Code Samples**\n\nGets the replication statistics of the account's Table service.\n\n```java\ntableServiceAsyncClient.getStatistics()\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(statistics -> System.out.print(\"Retrieved service statistics successfully.\"));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing <xref uid=\"com.azure.data.tables.models.TableServiceStatistics\" data-throw-if-not-resolved=\"false\" data-raw-source=\"statistics\"></xref> for the account's Table service."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.data.tables.models.TableServiceStatistics?alt=com.azure.data.tables.models.TableServiceStatistics&text=TableServiceStatistics\" data-throw-if-not-resolved=\"False\" />&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.getStatisticsWithResponse()"
fullName: "com.azure.data.tables.TableServiceAsyncClient.getStatisticsWithResponse()"
name: "getStatisticsWithResponse()"
nameWithType: "TableServiceAsyncClient.getStatisticsWithResponse()"
summary: "Retrieves statistics related to replication for the account's Table service."
syntax: "public Mono<Response<TableServiceStatistics>> getStatisticsWithResponse()"
desc: "Retrieves statistics related to replication for the account's Table service. It is only available on the secondary location endpoint when read-access geo-redundant replication is enabled for the account.\n\nThis operation is only supported on Azure Storage endpoints.\n\n**Code Samples**\n\nGets the replication statistics of the account's Table service. Prints out the details of the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref>.\n\n```java\ntableServiceAsyncClient.getStatisticsWithResponse()\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(response ->\n System.out.printf(\"Retrieved service statistics successfully with status code: %d.\",\n response.getStatusCode()));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref> that in turn contains\n <xref uid=\"com.azure.data.tables.models.TableServiceStatistics\" data-throw-if-not-resolved=\"false\" data-raw-source=\"statistics\"></xref> for the account's Table service."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.core.http.rest.Response?alt=com.azure.core.http.rest.Response&text=Response\" data-throw-if-not-resolved=\"False\" />&lt;<xref href=\"com.azure.data.tables.models.TableServiceStatistics?alt=com.azure.data.tables.models.TableServiceStatistics&text=TableServiceStatistics\" data-throw-if-not-resolved=\"False\" />&gt;&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.getTableClient(java.lang.String)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.getTableClient(String tableName)"
name: "getTableClient(String tableName)"
nameWithType: "TableServiceAsyncClient.getTableClient(String tableName)"
summary: "Gets a <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> instance for the table in the account with the provided `tableName`."
parameters:
- description: "The name of the table."
name: "tableName"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public TableAsyncClient getTableClient(String tableName)"
desc: "Gets a <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> instance for the table in the account with the provided `tableName`. The resulting <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> will use the same <xref uid=\"com.azure.core.http.HttpPipeline\" data-throw-if-not-resolved=\"false\" data-raw-source=\"pipeline\"></xref> and <xref uid=\"com.azure.data.tables.TableServiceVersion\" data-throw-if-not-resolved=\"false\" data-raw-source=\"service version\"></xref> as this <xref uid=\"com.azure.data.tables.TableServiceAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableServiceAsyncClient\"></xref>."
returns:
description: "A <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> instance for the table in the account with the provided <code>tableName</code>."
type: "<xref href=\"com.azure.data.tables.TableAsyncClient?alt=com.azure.data.tables.TableAsyncClient&text=TableAsyncClient\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.azure.data.tables.TableServiceAsyncClient.listTables()"
fullName: "com.azure.data.tables.TableServiceAsyncClient.listTables()"
name: "listTables()"
nameWithType: "TableServiceAsyncClient.listTables()"
summary: "Lists all tables within the account."
syntax: "public PagedFlux<TableItem> listTables()"
desc: "Lists all tables within the account.\n\n**Code Samples**\n\nLists all tables. Prints out the details of the retrieved tables.\n\n```java\ntableServiceAsyncClient.listTables().subscribe(tableItem ->\n System.out.printf(\"Retrieved table with name '%s'.%n\", tableItem.getName()));\n```"
returns:
description: "A <xref uid=\"com.azure.core.http.rest.PagedFlux\" data-throw-if-not-resolved=\"false\" data-raw-source=\"PagedFlux\"></xref> containing all tables within the account."
type: "<xref href=\"com.azure.core.http.rest.PagedFlux?alt=com.azure.core.http.rest.PagedFlux&text=PagedFlux\" data-throw-if-not-resolved=\"False\" />&lt;<xref href=\"com.azure.data.tables.models.TableItem?alt=com.azure.data.tables.models.TableItem&text=TableItem\" data-throw-if-not-resolved=\"False\" />&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.listTables(com.azure.data.tables.models.ListTablesOptions)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.listTables(ListTablesOptions options)"
name: "listTables(ListTablesOptions options)"
nameWithType: "TableServiceAsyncClient.listTables(ListTablesOptions options)"
summary: "Lists tables using the parameters in the provided options."
parameters:
- description: "The <code>filter</code> and <code>top</code> OData query options to apply to this operation."
name: "options"
type: "<xref href=\"com.azure.data.tables.models.ListTablesOptions?alt=com.azure.data.tables.models.ListTablesOptions&text=ListTablesOptions\" data-throw-if-not-resolved=\"False\" />"
syntax: "public PagedFlux<TableItem> listTables(ListTablesOptions options)"
desc: "Lists tables using the parameters in the provided options. If the `filter` parameter in the options is set, only tables matching the filter will be returned. If the `top` parameter is set, the maximum number of returned tables per page will be limited to that value.\n\n**Code Samples**\n\nLists all tables that match the filter. Prints out the details of the retrieved tables.\n\n```java\ntableServiceAsyncClient.listTables(new ListTablesOptions().setFilter(\"TableName eq 'myTable'\")).\n subscribe(tableItem -> System.out.printf(\"Retrieved table with name '%s'.%n\", tableItem.getName()));\n```"
returns:
description: "A <xref uid=\"com.azure.core.http.rest.PagedFlux\" data-throw-if-not-resolved=\"false\" data-raw-source=\"PagedFlux\"></xref> containing matching tables within the account."
type: "<xref href=\"com.azure.core.http.rest.PagedFlux?alt=com.azure.core.http.rest.PagedFlux&text=PagedFlux\" data-throw-if-not-resolved=\"False\" />&lt;<xref href=\"com.azure.data.tables.models.TableItem?alt=com.azure.data.tables.models.TableItem&text=TableItem\" data-throw-if-not-resolved=\"False\" />&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.setProperties(com.azure.data.tables.models.TableServiceProperties)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.setProperties(TableServiceProperties tableServiceProperties)"
name: "setProperties(TableServiceProperties tableServiceProperties)"
nameWithType: "TableServiceAsyncClient.setProperties(TableServiceProperties tableServiceProperties)"
summary: "Sets the properties of the account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules."
parameters:
- description: "The <xref uid=\"com.azure.data.tables.models.TableServiceProperties\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableServiceProperties\"></xref> to set."
name: "tableServiceProperties"
type: "<xref href=\"com.azure.data.tables.models.TableServiceProperties?alt=com.azure.data.tables.models.TableServiceProperties&text=TableServiceProperties\" data-throw-if-not-resolved=\"False\" />"
syntax: "public Mono<Void> setProperties(TableServiceProperties tableServiceProperties)"
desc: "Sets the properties of the account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules.\n\nThis operation is only supported on Azure Storage endpoints.\n\n**Code Samples**\n\nSets the properties of the account's Table service.\n\n```java\nTableServiceProperties properties = new TableServiceProperties()\n .setHourMetrics(new TableServiceMetrics()\n .setVersion(\"1.0\")\n .setEnabled(true))\n .setLogging(new TableServiceLogging()\n .setAnalyticsVersion(\"1.0\")\n .setReadLogged(true)\n .setRetentionPolicy(new TableServiceRetentionPolicy()\n .setEnabled(true)\n .setDaysToRetain(5)));\n\n tableServiceAsyncClient.setProperties(properties)\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(unused -> System.out.print(\"Set service properties successfully.\"));\n```"
returns:
description: "An empty <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref>."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Void.html\">Void</a>&gt;"
- uid: "com.azure.data.tables.TableServiceAsyncClient.setPropertiesWithResponse(com.azure.data.tables.models.TableServiceProperties)"
fullName: "com.azure.data.tables.TableServiceAsyncClient.setPropertiesWithResponse(TableServiceProperties tableServiceProperties)"
name: "setPropertiesWithResponse(TableServiceProperties tableServiceProperties)"
nameWithType: "TableServiceAsyncClient.setPropertiesWithResponse(TableServiceProperties tableServiceProperties)"
summary: "Sets the properties of an account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules."
parameters:
- description: "The <xref uid=\"com.azure.data.tables.models.TableServiceProperties\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableServiceProperties\"></xref> to set."
name: "tableServiceProperties"
type: "<xref href=\"com.azure.data.tables.models.TableServiceProperties?alt=com.azure.data.tables.models.TableServiceProperties&text=TableServiceProperties\" data-throw-if-not-resolved=\"False\" />"
syntax: "public Mono<Response<Void>> setPropertiesWithResponse(TableServiceProperties tableServiceProperties)"
desc: "Sets the properties of an account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules.\n\nThis operation is only supported on Azure Storage endpoints.\n\n**Code Samples**\n\nSets the properties of the account's Table service. Prints out the details of the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref>.\n\n```java\nTableServiceProperties myProperties = new TableServiceProperties()\n .setHourMetrics(new TableServiceMetrics()\n .setVersion(\"1.0\")\n .setEnabled(true))\n .setLogging(new TableServiceLogging()\n .setAnalyticsVersion(\"1.0\")\n .setReadLogged(true)\n .setRetentionPolicy(new TableServiceRetentionPolicy()\n .setEnabled(true)\n .setDaysToRetain(5)));\n\n tableServiceAsyncClient.setPropertiesWithResponse(myProperties)\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(response ->\n System.out.printf(\"Retrieved service properties successfully with status code: %d.\",\n response.getStatusCode()));\n```"
returns:
description: "A <xref uid=\"reactor.core.publisher.Mono\" data-throw-if-not-resolved=\"false\" data-raw-source=\"Mono\"></xref> containing the <xref uid=\"com.azure.core.http.rest.Response\" data-throw-if-not-resolved=\"false\" data-raw-source=\"HTTP response\"></xref>."
type: "<a href=\"https://projectreactor.io/docs/core/release/api/reactor/core/publisher/Mono.html\">Mono</a>&lt;<xref href=\"com.azure.core.http.rest.Response?alt=com.azure.core.http.rest.Response&text=Response\" data-throw-if-not-resolved=\"False\" />&lt;<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Void.html\">Void</a>&gt;&gt;"
type: "class"
desc: "Provides an asynchronous service client for accessing the Azure Tables service.\n\n## Overview ##\n\nThe client encapsulates the URL for the Tables service endpoint and the credentials for accessing the storage or CosmosDB table API account. It provides methods to create, delete, and list tables within the account. These methods invoke REST API operations to make the requests and obtain the results that are returned.\n\n## Getting Started ##\n\nThe building and authenticating of instances of this client are handled by <xref uid=\"com.azure.data.tables.TableServiceClientBuilder\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableServiceClientBuilder\"></xref> instances. The sample below shows how to authenticate and build a TableServiceAsyncClient using a connection string.\n\n```java\nTableServiceAsyncClient tableServiceAsyncClient = new TableServiceClientBuilder()\n .connectionString(\"connectionstring\")\n .buildAsyncClient();\n```\n\nSee <xref uid=\"com.azure.data.tables.TableServiceClientBuilder\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableServiceClientBuilder\"></xref> documentation for more information on constructing and authenticating a client.\n\nThe following code samples show the various ways you can interact with the tables service using this client.\n\n--------------------\n\n### Create a Table ###\n\nThe <xref uid=\"com.azure.data.tables.TableServiceAsyncClient.createTable(java.lang.String)\" data-throw-if-not-resolved=\"false\" data-raw-source=\"createTable\"></xref> method can be used to create a new table within an Azure Storage or Azure Cosmos account. It returns a TableClient for the newly created table.\n\nThe following sample creates a table with the name \"myTable\".\n\n```java\ntableServiceAsyncClient.createTable(\"myTable\")\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(tableAsyncClient ->\n System.out.printf(\"Table with name '%s' was created.\", tableAsyncClient.getTableName()));\n```\n\n***Note:** for synchronous sample, refer to <xref uid=\"com.azure.data.tables.TableServiceClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"synchronous client\"></xref>.*\n\n--------------------\n\n### Delete a Table ###\n\nThe <xref uid=\"com.azure.data.tables.TableServiceAsyncClient.deleteTable(java.lang.String)\" data-throw-if-not-resolved=\"false\" data-raw-source=\"deleteTable\"></xref> method can be used to delete a table within an Azure Storage or Azure Cosmos account.\n\nThe following sample deletes the table with the name \"myTable\".\n\n```java\ntableServiceAsyncClient.deleteTable(\"myTable\")\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(unused ->\n System.out.printf(\"Table with name '%s' was deleted.\", \"myTable\"));\n```\n\n***Note:** for synchronous sample, refer to <xref uid=\"com.azure.data.tables.TableServiceClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"synchronous client\"></xref>*\n\n--------------------\n\n### Get a <xref uid=\"com.azure.data.tables.TableServiceAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableServiceAsyncClient\"></xref> ###\n\nThe <xref uid=\"com.azure.data.tables.TableServiceAsyncClient.getTableClient(java.lang.String)\" data-throw-if-not-resolved=\"false\" data-raw-source=\"getTableClient\"></xref> method can be used to retrieve a <xref uid=\"com.azure.data.tables.TableAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableAsyncClient\"></xref> for a table within an Azure Storage or Azure Cosmos account.\n\nThe following sample gets a <xref uid=\"com.azure.data.tables.TableServiceAsyncClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"TableServiceAsyncClient\"></xref> using the table name \"myTable\".\n\n```java\nTableAsyncClient tableAsyncClient = tableServiceAsyncClient.getTableClient(\"myTable\");\n\n System.out.printf(\"Table with name '%s' was retrieved.\", tableAsyncClient.getTableName());\n```\n\n***Note:** for synchronous sample, refer to <xref uid=\"com.azure.data.tables.TableServiceClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"synchronous client\"></xref>*\n\n--------------------\n\n### List Tables ###\n\nThe <xref uid=\"com.azure.data.tables.TableServiceAsyncClient.listTables()\" data-throw-if-not-resolved=\"false\" data-raw-source=\"listTables\"></xref> method can be used to list all the tables in an Azure Storage or Azure Cosmos account.\n\nThe following samples list the tables in the Table service account.\n\nWithout filtering, returning all tables:\n\n```java\ntableServiceAsyncClient.listTables().subscribe(tableItem ->\n System.out.printf(\"Retrieved table with name '%s'.%n\", tableItem.getName()));\n```\n\nWith filtering:\n\n```java\ntableServiceAsyncClient.listTables(new ListTablesOptions().setFilter(\"TableName eq 'myTable'\")).\n subscribe(tableItem -> System.out.printf(\"Retrieved table with name '%s'.%n\", tableItem.getName()));\n```\n\n***Note:** for synchronous sample, refer to <xref uid=\"com.azure.data.tables.TableServiceClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"synchronous client\"></xref>*\n\n--------------------\n\n### Get Table Properties ###\n\nThe <xref uid=\"com.azure.data.tables.TableServiceAsyncClient.getProperties()\" data-throw-if-not-resolved=\"false\" data-raw-source=\"getProperties\"></xref> method can be used to get the properties of the account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules. This operation is only supported on Azure Storage endpoints.\n\nThe following sample gets the properties of the Table service account.\n\n```java\ntableServiceAsyncClient.getProperties()\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(properties -> System.out.print(\"Retrieved service properties successfully.\"));\n```\n\n***Note:** for synchronous sample, refer to <xref uid=\"com.azure.data.tables.TableServiceClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"synchronous client\"></xref>*\n\n--------------------\n\n### Set Table Properties ###\n\nThe <xref uid=\"com.azure.data.tables.TableServiceAsyncClient.setProperties(com.azure.data.tables.models.TableServiceProperties)\" data-throw-if-not-resolved=\"false\" data-raw-source=\"setProperties\"></xref> method can be used to set the properties of the account's Table service, including properties for Analytics and CORS (Cross-Origin Resource Sharing) rules. This operation is only supported on Azure Storage endpoints.\n\nThe following sample sets the properties of the Table service account.\n\n```java\nTableServiceProperties properties = new TableServiceProperties()\n .setHourMetrics(new TableServiceMetrics()\n .setVersion(\"1.0\")\n .setEnabled(true))\n .setLogging(new TableServiceLogging()\n .setAnalyticsVersion(\"1.0\")\n .setReadLogged(true)\n .setRetentionPolicy(new TableServiceRetentionPolicy()\n .setEnabled(true)\n .setDaysToRetain(5)));\n\n tableServiceAsyncClient.setProperties(properties)\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(unused -> System.out.print(\"Set service properties successfully.\"));\n```\n\n***Note:** for synchronous sample, refer to <xref uid=\"com.azure.data.tables.TableServiceClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"synchronous client\"></xref>*\n\n--------------------\n\n### Get Table Statistics ###\n\nThe <xref uid=\"com.azure.data.tables.TableServiceAsyncClient.getStatistics()\" data-throw-if-not-resolved=\"false\" data-raw-source=\"getStatistics\"></xref> method can be used to retrieve statistics related to replication for the account's Table service. It is only available on the secondary location endpoint when read-access geo-redundant replication is enabled for the account. This operation is only supported on Azure Storage endpoints.\n\nThe following sample gets the statistics of the Table service account.\n\n```java\ntableServiceAsyncClient.getStatistics()\n .contextWrite(Context.of(\"key1\", \"value1\", \"key2\", \"value2\"))\n .subscribe(statistics -> System.out.print(\"Retrieved service statistics successfully.\"));\n```\n\n***Note:** for synchronous sample, refer to <xref uid=\"com.azure.data.tables.TableServiceClient\" data-throw-if-not-resolved=\"false\" data-raw-source=\"synchronous client\"></xref>*"
metadata: {}
package: "com.azure.data.tables"
artifact: com.azure:azure-data-tables:12.4.6