Package com.google.cloud.compute.v1
Interface CorsPolicyOrBuilder
-
- All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
- All Known Implementing Classes:
CorsPolicy
,CorsPolicy.Builder
public interface CorsPolicyOrBuilder extends com.google.protobuf.MessageOrBuilder
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
getAllowCredentials()
In response to a preflight request, setting this to true indicates that the actual request can include user credentials.String
getAllowHeaders(int index)
Specifies the content for the Access-Control-Allow-Headers header.com.google.protobuf.ByteString
getAllowHeadersBytes(int index)
Specifies the content for the Access-Control-Allow-Headers header.int
getAllowHeadersCount()
Specifies the content for the Access-Control-Allow-Headers header.List<String>
getAllowHeadersList()
Specifies the content for the Access-Control-Allow-Headers header.String
getAllowMethods(int index)
Specifies the content for the Access-Control-Allow-Methods header.com.google.protobuf.ByteString
getAllowMethodsBytes(int index)
Specifies the content for the Access-Control-Allow-Methods header.int
getAllowMethodsCount()
Specifies the content for the Access-Control-Allow-Methods header.List<String>
getAllowMethodsList()
Specifies the content for the Access-Control-Allow-Methods header.String
getAllowOriginRegexes(int index)
Specifies a regular expression that matches allowed origins.com.google.protobuf.ByteString
getAllowOriginRegexesBytes(int index)
Specifies a regular expression that matches allowed origins.int
getAllowOriginRegexesCount()
Specifies a regular expression that matches allowed origins.List<String>
getAllowOriginRegexesList()
Specifies a regular expression that matches allowed origins.String
getAllowOrigins(int index)
Specifies the list of origins that is allowed to do CORS requests.com.google.protobuf.ByteString
getAllowOriginsBytes(int index)
Specifies the list of origins that is allowed to do CORS requests.int
getAllowOriginsCount()
Specifies the list of origins that is allowed to do CORS requests.List<String>
getAllowOriginsList()
Specifies the list of origins that is allowed to do CORS requests.boolean
getDisabled()
If true, the setting specifies the CORS policy is disabled.String
getExposeHeaders(int index)
Specifies the content for the Access-Control-Expose-Headers header.com.google.protobuf.ByteString
getExposeHeadersBytes(int index)
Specifies the content for the Access-Control-Expose-Headers header.int
getExposeHeadersCount()
Specifies the content for the Access-Control-Expose-Headers header.List<String>
getExposeHeadersList()
Specifies the content for the Access-Control-Expose-Headers header.int
getMaxAge()
Specifies how long results of a preflight request can be cached in seconds.boolean
hasAllowCredentials()
In response to a preflight request, setting this to true indicates that the actual request can include user credentials.boolean
hasDisabled()
If true, the setting specifies the CORS policy is disabled.boolean
hasMaxAge()
Specifies how long results of a preflight request can be cached in seconds.-
Methods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
-
-
-
Method Detail
-
hasAllowCredentials
boolean hasAllowCredentials()
In response to a preflight request, setting this to true indicates that the actual request can include user credentials. This field translates to the Access-Control-Allow-Credentials header. Default is false.
optional bool allow_credentials = 481263366;
- Returns:
- Whether the allowCredentials field is set.
-
getAllowCredentials
boolean getAllowCredentials()
In response to a preflight request, setting this to true indicates that the actual request can include user credentials. This field translates to the Access-Control-Allow-Credentials header. Default is false.
optional bool allow_credentials = 481263366;
- Returns:
- The allowCredentials.
-
getAllowHeadersList
List<String> getAllowHeadersList()
Specifies the content for the Access-Control-Allow-Headers header.
repeated string allow_headers = 45179024;
- Returns:
- A list containing the allowHeaders.
-
getAllowHeadersCount
int getAllowHeadersCount()
Specifies the content for the Access-Control-Allow-Headers header.
repeated string allow_headers = 45179024;
- Returns:
- The count of allowHeaders.
-
getAllowHeaders
String getAllowHeaders(int index)
Specifies the content for the Access-Control-Allow-Headers header.
repeated string allow_headers = 45179024;
- Parameters:
index
- The index of the element to return.- Returns:
- The allowHeaders at the given index.
-
getAllowHeadersBytes
com.google.protobuf.ByteString getAllowHeadersBytes(int index)
Specifies the content for the Access-Control-Allow-Headers header.
repeated string allow_headers = 45179024;
- Parameters:
index
- The index of the value to return.- Returns:
- The bytes of the allowHeaders at the given index.
-
getAllowMethodsList
List<String> getAllowMethodsList()
Specifies the content for the Access-Control-Allow-Methods header.
repeated string allow_methods = 205405372;
- Returns:
- A list containing the allowMethods.
-
getAllowMethodsCount
int getAllowMethodsCount()
Specifies the content for the Access-Control-Allow-Methods header.
repeated string allow_methods = 205405372;
- Returns:
- The count of allowMethods.
-
getAllowMethods
String getAllowMethods(int index)
Specifies the content for the Access-Control-Allow-Methods header.
repeated string allow_methods = 205405372;
- Parameters:
index
- The index of the element to return.- Returns:
- The allowMethods at the given index.
-
getAllowMethodsBytes
com.google.protobuf.ByteString getAllowMethodsBytes(int index)
Specifies the content for the Access-Control-Allow-Methods header.
repeated string allow_methods = 205405372;
- Parameters:
index
- The index of the value to return.- Returns:
- The bytes of the allowMethods at the given index.
-
getAllowOriginRegexesList
List<String> getAllowOriginRegexesList()
Specifies a regular expression that matches allowed origins. For more information about the regular expression syntax, see Syntax. An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes. Regular expressions can only be used when the loadBalancingScheme is set to INTERNAL_SELF_MANAGED.
repeated string allow_origin_regexes = 215385810;
- Returns:
- A list containing the allowOriginRegexes.
-
getAllowOriginRegexesCount
int getAllowOriginRegexesCount()
Specifies a regular expression that matches allowed origins. For more information about the regular expression syntax, see Syntax. An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes. Regular expressions can only be used when the loadBalancingScheme is set to INTERNAL_SELF_MANAGED.
repeated string allow_origin_regexes = 215385810;
- Returns:
- The count of allowOriginRegexes.
-
getAllowOriginRegexes
String getAllowOriginRegexes(int index)
Specifies a regular expression that matches allowed origins. For more information about the regular expression syntax, see Syntax. An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes. Regular expressions can only be used when the loadBalancingScheme is set to INTERNAL_SELF_MANAGED.
repeated string allow_origin_regexes = 215385810;
- Parameters:
index
- The index of the element to return.- Returns:
- The allowOriginRegexes at the given index.
-
getAllowOriginRegexesBytes
com.google.protobuf.ByteString getAllowOriginRegexesBytes(int index)
Specifies a regular expression that matches allowed origins. For more information about the regular expression syntax, see Syntax. An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes. Regular expressions can only be used when the loadBalancingScheme is set to INTERNAL_SELF_MANAGED.
repeated string allow_origin_regexes = 215385810;
- Parameters:
index
- The index of the value to return.- Returns:
- The bytes of the allowOriginRegexes at the given index.
-
getAllowOriginsList
List<String> getAllowOriginsList()
Specifies the list of origins that is allowed to do CORS requests. An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes.
repeated string allow_origins = 194914071;
- Returns:
- A list containing the allowOrigins.
-
getAllowOriginsCount
int getAllowOriginsCount()
Specifies the list of origins that is allowed to do CORS requests. An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes.
repeated string allow_origins = 194914071;
- Returns:
- The count of allowOrigins.
-
getAllowOrigins
String getAllowOrigins(int index)
Specifies the list of origins that is allowed to do CORS requests. An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes.
repeated string allow_origins = 194914071;
- Parameters:
index
- The index of the element to return.- Returns:
- The allowOrigins at the given index.
-
getAllowOriginsBytes
com.google.protobuf.ByteString getAllowOriginsBytes(int index)
Specifies the list of origins that is allowed to do CORS requests. An origin is allowed if it matches either an item in allowOrigins or an item in allowOriginRegexes.
repeated string allow_origins = 194914071;
- Parameters:
index
- The index of the value to return.- Returns:
- The bytes of the allowOrigins at the given index.
-
hasDisabled
boolean hasDisabled()
If true, the setting specifies the CORS policy is disabled. The default value of false, which indicates that the CORS policy is in effect.
optional bool disabled = 270940796;
- Returns:
- Whether the disabled field is set.
-
getDisabled
boolean getDisabled()
If true, the setting specifies the CORS policy is disabled. The default value of false, which indicates that the CORS policy is in effect.
optional bool disabled = 270940796;
- Returns:
- The disabled.
-
getExposeHeadersList
List<String> getExposeHeadersList()
Specifies the content for the Access-Control-Expose-Headers header.
repeated string expose_headers = 247604747;
- Returns:
- A list containing the exposeHeaders.
-
getExposeHeadersCount
int getExposeHeadersCount()
Specifies the content for the Access-Control-Expose-Headers header.
repeated string expose_headers = 247604747;
- Returns:
- The count of exposeHeaders.
-
getExposeHeaders
String getExposeHeaders(int index)
Specifies the content for the Access-Control-Expose-Headers header.
repeated string expose_headers = 247604747;
- Parameters:
index
- The index of the element to return.- Returns:
- The exposeHeaders at the given index.
-
getExposeHeadersBytes
com.google.protobuf.ByteString getExposeHeadersBytes(int index)
Specifies the content for the Access-Control-Expose-Headers header.
repeated string expose_headers = 247604747;
- Parameters:
index
- The index of the value to return.- Returns:
- The bytes of the exposeHeaders at the given index.
-
hasMaxAge
boolean hasMaxAge()
Specifies how long results of a preflight request can be cached in seconds. This field translates to the Access-Control-Max-Age header.
optional int32 max_age = 307559332;
- Returns:
- Whether the maxAge field is set.
-
getMaxAge
int getMaxAge()
Specifies how long results of a preflight request can be cached in seconds. This field translates to the Access-Control-Max-Age header.
optional int32 max_age = 307559332;
- Returns:
- The maxAge.
-
-