Class WebKeySettings.Builder
java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<WebKeySettings.Builder>
com.google.recaptchaenterprise.v1.WebKeySettings.Builder
- All Implemented Interfaces:
com.google.protobuf.Message.Builder,com.google.protobuf.MessageLite.Builder,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,WebKeySettingsOrBuilder,Cloneable
- Enclosing class:
- WebKeySettings
public static final class WebKeySettings.Builder
extends com.google.protobuf.GeneratedMessage.Builder<WebKeySettings.Builder>
implements WebKeySettingsOrBuilder
Settings specific to keys that can be used by websites.Protobuf type
google.cloud.recaptchaenterprise.v1.WebKeySettings-
Method Summary
Modifier and TypeMethodDescriptionaddAllAllowedDomains(Iterable<String> values) Optional.addAllowedDomains(String value) Optional.addAllowedDomainsBytes(com.google.protobuf.ByteString value) Optional.build()clear()Optional.Optional.Optional.Optional.Optional.Required.booleanOptional.booleanOptional.getAllowedDomains(int index) Optional.com.google.protobuf.ByteStringgetAllowedDomainsBytes(int index) Optional.intOptional.com.google.protobuf.ProtocolStringListOptional.Optional.intOptional.Optional.Optional.Optional.static final com.google.protobuf.Descriptors.Descriptorcom.google.protobuf.Descriptors.DescriptorRequired.intRequired.booleanOptional.protected com.google.protobuf.GeneratedMessage.FieldAccessorTablefinal booleanOptional.mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) mergeFrom(com.google.protobuf.Message other) mergeFrom(WebKeySettings other) setAllowAllDomains(boolean value) Optional.setAllowAmpTraffic(boolean value) Optional.setAllowedDomains(int index, String value) Optional.Optional.setChallengeSecurityPreferenceValue(int value) Optional.Optional.setChallengeSettings(WebKeySettings.ChallengeSettings.Builder builderForValue) Optional.Required.setIntegrationTypeValue(int value) Required.Methods inherited from class com.google.protobuf.GeneratedMessage.Builder
addRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, internalGetMutableMapField, internalGetMutableMapFieldReflection, isClean, markClean, mergeUnknownFields, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFields, setUnknownFieldSetBuilder, setUnknownFieldsProto3Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.Message.Builder
mergeDelimitedFrom, mergeDelimitedFromMethods inherited from interface com.google.protobuf.MessageLite.Builder
mergeFromMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Method Details
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessage.Builder<WebKeySettings.Builder>
-
clear
- Specified by:
clearin interfacecom.google.protobuf.Message.Builder- Specified by:
clearin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
clearin classcom.google.protobuf.GeneratedMessage.Builder<WebKeySettings.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.Message.Builder- Specified by:
getDescriptorForTypein interfacecom.google.protobuf.MessageOrBuilder- Overrides:
getDescriptorForTypein classcom.google.protobuf.GeneratedMessage.Builder<WebKeySettings.Builder>
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-
build
- Specified by:
buildin interfacecom.google.protobuf.Message.Builder- Specified by:
buildin interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
- Specified by:
buildPartialin interfacecom.google.protobuf.Message.Builder- Specified by:
buildPartialin interfacecom.google.protobuf.MessageLite.Builder
-
mergeFrom
- Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<WebKeySettings.Builder>
-
mergeFrom
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessage.Builder<WebKeySettings.Builder>
-
mergeFrom
public WebKeySettings.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Specified by:
mergeFromin interfacecom.google.protobuf.Message.Builder- Specified by:
mergeFromin interfacecom.google.protobuf.MessageLite.Builder- Overrides:
mergeFromin classcom.google.protobuf.AbstractMessage.Builder<WebKeySettings.Builder>- Throws:
IOException
-
getAllowAllDomains
public boolean getAllowAllDomains()Optional. If set to true, it means allowed_domains are not enforced.
bool allow_all_domains = 3 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getAllowAllDomainsin interfaceWebKeySettingsOrBuilder- Returns:
- The allowAllDomains.
-
setAllowAllDomains
Optional. If set to true, it means allowed_domains are not enforced.
bool allow_all_domains = 3 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The allowAllDomains to set.- Returns:
- This builder for chaining.
-
clearAllowAllDomains
Optional. If set to true, it means allowed_domains are not enforced.
bool allow_all_domains = 3 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
getAllowedDomainsList
public com.google.protobuf.ProtocolStringList getAllowedDomainsList()Optional. Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: 'example.com' or 'subdomain.example.com' Each key supports a maximum of 250 domains. To use a key on more domains, set `allow_all_domains` to true. When this is set, you are responsible for validating the hostname by checking the `token_properties.hostname` field in each assessment response against your list of allowed domains.
repeated string allowed_domains = 1 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getAllowedDomainsListin interfaceWebKeySettingsOrBuilder- Returns:
- A list containing the allowedDomains.
-
getAllowedDomainsCount
public int getAllowedDomainsCount()Optional. Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: 'example.com' or 'subdomain.example.com' Each key supports a maximum of 250 domains. To use a key on more domains, set `allow_all_domains` to true. When this is set, you are responsible for validating the hostname by checking the `token_properties.hostname` field in each assessment response against your list of allowed domains.
repeated string allowed_domains = 1 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getAllowedDomainsCountin interfaceWebKeySettingsOrBuilder- Returns:
- The count of allowedDomains.
-
getAllowedDomains
Optional. Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: 'example.com' or 'subdomain.example.com' Each key supports a maximum of 250 domains. To use a key on more domains, set `allow_all_domains` to true. When this is set, you are responsible for validating the hostname by checking the `token_properties.hostname` field in each assessment response against your list of allowed domains.
repeated string allowed_domains = 1 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getAllowedDomainsin interfaceWebKeySettingsOrBuilder- Parameters:
index- The index of the element to return.- Returns:
- The allowedDomains at the given index.
-
getAllowedDomainsBytes
public com.google.protobuf.ByteString getAllowedDomainsBytes(int index) Optional. Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: 'example.com' or 'subdomain.example.com' Each key supports a maximum of 250 domains. To use a key on more domains, set `allow_all_domains` to true. When this is set, you are responsible for validating the hostname by checking the `token_properties.hostname` field in each assessment response against your list of allowed domains.
repeated string allowed_domains = 1 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getAllowedDomainsBytesin interfaceWebKeySettingsOrBuilder- Parameters:
index- The index of the value to return.- Returns:
- The bytes of the allowedDomains at the given index.
-
setAllowedDomains
Optional. Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: 'example.com' or 'subdomain.example.com' Each key supports a maximum of 250 domains. To use a key on more domains, set `allow_all_domains` to true. When this is set, you are responsible for validating the hostname by checking the `token_properties.hostname` field in each assessment response against your list of allowed domains.
repeated string allowed_domains = 1 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
index- The index to set the value at.value- The allowedDomains to set.- Returns:
- This builder for chaining.
-
addAllowedDomains
Optional. Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: 'example.com' or 'subdomain.example.com' Each key supports a maximum of 250 domains. To use a key on more domains, set `allow_all_domains` to true. When this is set, you are responsible for validating the hostname by checking the `token_properties.hostname` field in each assessment response against your list of allowed domains.
repeated string allowed_domains = 1 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The allowedDomains to add.- Returns:
- This builder for chaining.
-
addAllAllowedDomains
Optional. Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: 'example.com' or 'subdomain.example.com' Each key supports a maximum of 250 domains. To use a key on more domains, set `allow_all_domains` to true. When this is set, you are responsible for validating the hostname by checking the `token_properties.hostname` field in each assessment response against your list of allowed domains.
repeated string allowed_domains = 1 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
values- The allowedDomains to add.- Returns:
- This builder for chaining.
-
clearAllowedDomains
Optional. Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: 'example.com' or 'subdomain.example.com' Each key supports a maximum of 250 domains. To use a key on more domains, set `allow_all_domains` to true. When this is set, you are responsible for validating the hostname by checking the `token_properties.hostname` field in each assessment response against your list of allowed domains.
repeated string allowed_domains = 1 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
addAllowedDomainsBytes
Optional. Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: 'example.com' or 'subdomain.example.com' Each key supports a maximum of 250 domains. To use a key on more domains, set `allow_all_domains` to true. When this is set, you are responsible for validating the hostname by checking the `token_properties.hostname` field in each assessment response against your list of allowed domains.
repeated string allowed_domains = 1 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The bytes of the allowedDomains to add.- Returns:
- This builder for chaining.
-
getAllowAmpTraffic
public boolean getAllowAmpTraffic()Optional. If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
bool allow_amp_traffic = 2 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getAllowAmpTrafficin interfaceWebKeySettingsOrBuilder- Returns:
- The allowAmpTraffic.
-
setAllowAmpTraffic
Optional. If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
bool allow_amp_traffic = 2 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The allowAmpTraffic to set.- Returns:
- This builder for chaining.
-
clearAllowAmpTraffic
Optional. If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
bool allow_amp_traffic = 2 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
getIntegrationTypeValue
public int getIntegrationTypeValue()Required. Describes how this key is integrated with the website.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.IntegrationType integration_type = 4 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getIntegrationTypeValuein interfaceWebKeySettingsOrBuilder- Returns:
- The enum numeric value on the wire for integrationType.
-
setIntegrationTypeValue
Required. Describes how this key is integrated with the website.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.IntegrationType integration_type = 4 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The enum numeric value on the wire for integrationType to set.- Returns:
- This builder for chaining.
-
getIntegrationType
Required. Describes how this key is integrated with the website.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.IntegrationType integration_type = 4 [(.google.api.field_behavior) = REQUIRED];- Specified by:
getIntegrationTypein interfaceWebKeySettingsOrBuilder- Returns:
- The integrationType.
-
setIntegrationType
Required. Describes how this key is integrated with the website.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.IntegrationType integration_type = 4 [(.google.api.field_behavior) = REQUIRED];- Parameters:
value- The integrationType to set.- Returns:
- This builder for chaining.
-
clearIntegrationType
Required. Describes how this key is integrated with the website.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.IntegrationType integration_type = 4 [(.google.api.field_behavior) = REQUIRED];- Returns:
- This builder for chaining.
-
getChallengeSecurityPreferenceValue
public int getChallengeSecurityPreferenceValue()Optional. Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for `IntegrationType` CHECKBOX, INVISIBLE or POLICY_BASED_CHALLENGE.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getChallengeSecurityPreferenceValuein interfaceWebKeySettingsOrBuilder- Returns:
- The enum numeric value on the wire for challengeSecurityPreference.
-
setChallengeSecurityPreferenceValue
Optional. Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for `IntegrationType` CHECKBOX, INVISIBLE or POLICY_BASED_CHALLENGE.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The enum numeric value on the wire for challengeSecurityPreference to set.- Returns:
- This builder for chaining.
-
getChallengeSecurityPreference
Optional. Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for `IntegrationType` CHECKBOX, INVISIBLE or POLICY_BASED_CHALLENGE.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getChallengeSecurityPreferencein interfaceWebKeySettingsOrBuilder- Returns:
- The challengeSecurityPreference.
-
setChallengeSecurityPreference
public WebKeySettings.Builder setChallengeSecurityPreference(WebKeySettings.ChallengeSecurityPreference value) Optional. Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for `IntegrationType` CHECKBOX, INVISIBLE or POLICY_BASED_CHALLENGE.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5 [(.google.api.field_behavior) = OPTIONAL];- Parameters:
value- The challengeSecurityPreference to set.- Returns:
- This builder for chaining.
-
clearChallengeSecurityPreference
Optional. Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for `IntegrationType` CHECKBOX, INVISIBLE or POLICY_BASED_CHALLENGE.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5 [(.google.api.field_behavior) = OPTIONAL];- Returns:
- This builder for chaining.
-
hasChallengeSettings
public boolean hasChallengeSettings()Optional. Challenge settings.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSettings challenge_settings = 6 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
hasChallengeSettingsin interfaceWebKeySettingsOrBuilder- Returns:
- Whether the challengeSettings field is set.
-
getChallengeSettings
Optional. Challenge settings.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSettings challenge_settings = 6 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getChallengeSettingsin interfaceWebKeySettingsOrBuilder- Returns:
- The challengeSettings.
-
setChallengeSettings
Optional. Challenge settings.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSettings challenge_settings = 6 [(.google.api.field_behavior) = OPTIONAL]; -
setChallengeSettings
public WebKeySettings.Builder setChallengeSettings(WebKeySettings.ChallengeSettings.Builder builderForValue) Optional. Challenge settings.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSettings challenge_settings = 6 [(.google.api.field_behavior) = OPTIONAL]; -
mergeChallengeSettings
Optional. Challenge settings.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSettings challenge_settings = 6 [(.google.api.field_behavior) = OPTIONAL]; -
clearChallengeSettings
Optional. Challenge settings.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSettings challenge_settings = 6 [(.google.api.field_behavior) = OPTIONAL]; -
getChallengeSettingsBuilder
Optional. Challenge settings.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSettings challenge_settings = 6 [(.google.api.field_behavior) = OPTIONAL]; -
getChallengeSettingsOrBuilder
Optional. Challenge settings.
.google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSettings challenge_settings = 6 [(.google.api.field_behavior) = OPTIONAL];- Specified by:
getChallengeSettingsOrBuilderin interfaceWebKeySettingsOrBuilder
-