azure-docs-sdk-java/legacy/docs-ref-autogen/com.azure.search.models.Cor...

84 строки
5.9 KiB
YAML

### YamlMime:JavaType
uid: "com.azure.search.models.CorsOptions"
fullName: "com.azure.search.models.CorsOptions"
name: "CorsOptions"
nameWithType: "CorsOptions"
summary: "Defines options to control Cross-Origin Resource Sharing (CORS) for an index."
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 **CorsOptions**"
constructors:
- uid: "com.azure.search.models.CorsOptions.CorsOptions()"
fullName: "com.azure.search.models.CorsOptions.CorsOptions()"
name: "CorsOptions()"
nameWithType: "CorsOptions.CorsOptions()"
syntax: "public CorsOptions()"
methods:
- uid: "com.azure.search.models.CorsOptions.getAllowedOrigins()"
fullName: "com.azure.search.models.CorsOptions.getAllowedOrigins()"
name: "getAllowedOrigins()"
nameWithType: "CorsOptions.getAllowedOrigins()"
summary: "Get the allowed<wbr>Origins property: The list of origins from which Java<wbr>Script code will be granted access to your index."
syntax: "public List<String> getAllowedOrigins()"
desc: "Get the allowedOrigins property: The list of origins from which JavaScript code will be granted access to your index. Can contain a list of hosts of the form \\{protocol\\}://\\{fully-qualified-domain-name\\}\\[:\\{port\\#\\}\\], or a single '\\*' to allow all origins (not recommended)."
returns:
description: "the allowedOrigins value."
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/util/List.html\">List</a>&lt;<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>&gt;"
- uid: "com.azure.search.models.CorsOptions.getMaxAgeInSeconds()"
fullName: "com.azure.search.models.CorsOptions.getMaxAgeInSeconds()"
name: "getMaxAgeInSeconds()"
nameWithType: "CorsOptions.getMaxAgeInSeconds()"
summary: "Get the max<wbr>Age<wbr>InSeconds property: The duration for which browsers should cache CORS preflight responses."
syntax: "public Long getMaxAgeInSeconds()"
desc: "Get the maxAgeInSeconds property: The duration for which browsers should cache CORS preflight responses. Defaults to 5 minutes."
returns:
description: "the maxAgeInSeconds value."
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html\">Long</a>"
- uid: "com.azure.search.models.CorsOptions.setAllowedOrigins(java.lang.String...)"
fullName: "com.azure.search.models.CorsOptions.setAllowedOrigins(String[] allowedOrigins)"
name: "setAllowedOrigins(String[] allowedOrigins)"
nameWithType: "CorsOptions.setAllowedOrigins(String[] allowedOrigins)"
summary: "Set the allowed<wbr>Origins property: The list of origins from which Java<wbr>Script code will be granted access to your index."
parameters:
- description: "the allowedOrigins value to set."
name: "allowedOrigins"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>[]"
syntax: "public CorsOptions setAllowedOrigins(String[] allowedOrigins)"
desc: "Set the allowedOrigins property: The list of origins from which JavaScript code will be granted access to your index. Can contain a list of hosts of the form \\{protocol\\}://\\{fully-qualified-domain-name\\}\\[:\\{port\\#\\}\\], or a single '\\*' to allow all origins (not recommended)."
returns:
description: "the CorsOptions object itself."
type: "<xref href=\"com.azure.search.models.CorsOptions?alt=com.azure.search.models.CorsOptions&text=CorsOptions\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.azure.search.models.CorsOptions.setMaxAgeInSeconds(java.lang.Long)"
fullName: "com.azure.search.models.CorsOptions.setMaxAgeInSeconds(Long maxAgeInSeconds)"
name: "setMaxAgeInSeconds(Long maxAgeInSeconds)"
nameWithType: "CorsOptions.setMaxAgeInSeconds(Long maxAgeInSeconds)"
summary: "Set the max<wbr>Age<wbr>InSeconds property: The duration for which browsers should cache CORS preflight responses."
parameters:
- description: "the maxAgeInSeconds value to set."
name: "maxAgeInSeconds"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html\">Long</a>"
syntax: "public CorsOptions setMaxAgeInSeconds(Long maxAgeInSeconds)"
desc: "Set the maxAgeInSeconds property: The duration for which browsers should cache CORS preflight responses. Defaults to 5 minutes."
returns:
description: "the CorsOptions object itself."
type: "<xref href=\"com.azure.search.models.CorsOptions?alt=com.azure.search.models.CorsOptions&text=CorsOptions\" data-throw-if-not-resolved=\"False\" />"
type: "class"
desc: "Defines options to control Cross-Origin Resource Sharing (CORS) for an index."
metadata: {}
package: "com.azure.search.models"
artifact: com.azure:azure-search:11.0.0-beta.1