azure-docs-sdk-java/docs-ref-autogen/com.microsoft.azure.functio...

136 строки
8.5 KiB
YAML

### YamlMime:JavaType
uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput"
name: "CosmosDBOutput"
nameWithType: "CosmosDBOutput"
summary: "Place this on a parameter whose value would be written to CosmosDB."
syntax: "public interface **CosmosDBOutput**</br> implements <xref href=\"java.lang.annotation.Annotation?alt=java.lang.annotation.Annotation&text=Annotation\" data-throw-if-not-resolved=\"False\" />"
methods:
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.collectionName()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.collectionName()"
name: "collectionName()"
nameWithType: "CosmosDBOutput.collectionName()"
summary: "Defines the collection name of the CosmosDB to which to write."
modifiers:
- "abstract"
syntax: "public abstract String collectionName()"
desc: "Defines the collection name of the CosmosDB to which to write."
returns:
description: "The collection name string."
type: "<xref href=\"java.lang.String?alt=java.lang.String&text=String\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.collectionThroughput()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.collectionThroughput()"
name: "collectionThroughput()"
nameWithType: "CosmosDBOutput.collectionThroughput()"
summary: "If Create<wbr>IfNot<wbr>Exists is true, defines the throughput of the created collection."
modifiers:
- "abstract"
syntax: "public abstract int collectionThroughput()"
desc: "If CreateIfNotExists is true, defines the throughput of the created collection."
returns:
description: "Throughput of the created collection."
type: "<xref href=\"int?alt=int&text=int\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.connectionStringSetting()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.connectionStringSetting()"
name: "connectionStringSetting()"
nameWithType: "CosmosDBOutput.connectionStringSetting()"
summary: "Defines the app setting name that contains the CosmosDB connection string."
modifiers:
- "abstract"
syntax: "public abstract String connectionStringSetting()"
desc: "Defines the app setting name that contains the CosmosDB connection string."
returns:
description: "The app setting name of the connection string."
type: "<xref href=\"java.lang.String?alt=java.lang.String&text=String\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.createIfNotExists()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.createIfNotExists()"
name: "createIfNotExists()"
nameWithType: "CosmosDBOutput.createIfNotExists()"
summary: "Defines the ID of the CosmosDB to which to write."
modifiers:
- "abstract"
syntax: "public abstract boolean createIfNotExists()"
desc: "Defines the ID of the CosmosDB to which to write."
returns:
description: "The ID string."
type: "<xref href=\"boolean?alt=boolean&text=boolean\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.dataType()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.dataType()"
name: "dataType()"
nameWithType: "CosmosDBOutput.dataType()"
summary: "Defines how Functions runtime should treat the parameter value."
modifiers:
- "abstract"
syntax: "public abstract String dataType()"
desc: "Defines how Functions runtime should treat the parameter value. Possible values are:\n\n * \"\" or string: treat it as a string whose value is serialized from the parameter\n * binary: treat it as a binary data whose value comes from for example OutputBinding<byte\\[\\]>"
returns:
description: "The dataType which will be used by the Functions runtime."
type: "<xref href=\"java.lang.String?alt=java.lang.String&text=String\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.databaseName()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.databaseName()"
name: "databaseName()"
nameWithType: "CosmosDBOutput.databaseName()"
summary: "Defines the database name of the CosmosDB to which to write."
modifiers:
- "abstract"
syntax: "public abstract String databaseName()"
desc: "Defines the database name of the CosmosDB to which to write."
returns:
description: "The database name string."
type: "<xref href=\"java.lang.String?alt=java.lang.String&text=String\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.name()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.name()"
name: "name()"
nameWithType: "CosmosDBOutput.name()"
summary: "The variable name used in function.<wbr>json."
modifiers:
- "abstract"
syntax: "public abstract String name()"
desc: "The variable name used in function.json."
returns:
description: "The variable name used in function.json."
type: "<xref href=\"java.lang.String?alt=java.lang.String&text=String\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.partitionKey()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.partitionKey()"
name: "partitionKey()"
nameWithType: "CosmosDBOutput.partitionKey()"
summary: "Defines the partition key path for the created collection when create<wbr>IfNot<wbr>Exists is set to true."
modifiers:
- "abstract"
syntax: "public abstract String partitionKey()"
desc: "Defines the partition key path for the created collection when createIfNotExists is set to true. May include binding parameters."
returns:
description: "partitionKey of the created collection."
type: "<xref href=\"java.lang.String?alt=java.lang.String&text=String\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.preferredLocations()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.preferredLocations()"
name: "preferredLocations()"
nameWithType: "CosmosDBOutput.preferredLocations()"
summary: "Defines preferred locations (regions) for geo-replicated database accounts in the Azure Cosmos DB service."
modifiers:
- "abstract"
syntax: "public abstract String preferredLocations()"
desc: "Defines preferred locations (regions) for geo-replicated database accounts in the Azure Cosmos DB service. Values should be comma-separated. example, PreferredLocations = \"East US,South Central US,North Europe\""
returns:
description: "PreferredLocations for geo-replicated database accounts"
type: "<xref href=\"java.lang.String?alt=java.lang.String&text=String\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.functions.annotation.CosmosDBOutput.useMultipleWriteLocations()"
fullName: "com.microsoft.azure.functions.annotation.CosmosDBOutput.useMultipleWriteLocations()"
name: "useMultipleWriteLocations()"
nameWithType: "CosmosDBOutput.useMultipleWriteLocations()"
summary: "Enable to use with Multi Master accounts."
modifiers:
- "abstract"
syntax: "public abstract boolean useMultipleWriteLocations()"
desc: "Enable to use with Multi Master accounts."
returns:
description: "whether to Multi Master accounts"
type: "<xref href=\"boolean?alt=boolean&text=boolean\" data-throw-if-not-resolved=\"False\" />"
type: "interface"
desc: "Place this on a parameter whose value would be written to CosmosDB. The parameter type should be OutputBinding<T>, where T could be one of:\n\n * Some native Java types such as String\n * Any POJO type\n\nThe following example shows a Java function that adds a document to a database, using data provided in the body of an HTTP Post request.\n\n```java\n@FunctionName(\"addItem\")\n\n public String cosmosDbAddItem(\n @HttpTrigger(name = \"request\", methods = {HttpMethod.POST}, authLevel = AuthorizationLevel.ANONYMOUS)\n final String message,\n @CosmosDBOutput(name = \"database\", databaseName = \"ToDoList\", collectionName = \"Items\", \n connectionStringSetting = \"AzureCosmosDBConnection\")\n ) {\n return \"{ \\\"id\\\": \\\"\" + System.currentTimeMillis() + \"\\\", \\\"description\\\": \\\"\" + message + \"\\\" }\";\n }\n```"
implements:
- "<xref href=\"java.lang.annotation.Annotation?alt=java.lang.annotation.Annotation&text=Annotation\" data-throw-if-not-resolved=\"False\" />"
metadata: {}
package: "com.microsoft.azure.functions.annotation"
artifact: com.microsoft.azure.functions:azure-functions-java-library:1.3.1