Class 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.GeneratedMessageV3.Builder<WebKeySettings.Builder>
    implements WebKeySettingsOrBuilder
     Settings specific to keys that can be used by websites.
     
    Protobuf type google.cloud.recaptchaenterprise.v1.WebKeySettings
    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • clear

        public WebKeySettings.Builder clear()
        Specified by:
        clear in interface com.google.protobuf.Message.Builder
        Specified by:
        clear in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clear in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • getDefaultInstanceForType

        public WebKeySettings getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public WebKeySettings build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public WebKeySettings buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • clone

        public WebKeySettings.Builder clone()
        Specified by:
        clone in interface com.google.protobuf.Message.Builder
        Specified by:
        clone in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clone in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • setField

        public WebKeySettings.Builder setField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                               Object value)
        Specified by:
        setField in interface com.google.protobuf.Message.Builder
        Overrides:
        setField in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • clearField

        public WebKeySettings.Builder clearField​(com.google.protobuf.Descriptors.FieldDescriptor field)
        Specified by:
        clearField in interface com.google.protobuf.Message.Builder
        Overrides:
        clearField in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • clearOneof

        public WebKeySettings.Builder clearOneof​(com.google.protobuf.Descriptors.OneofDescriptor oneof)
        Specified by:
        clearOneof in interface com.google.protobuf.Message.Builder
        Overrides:
        clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • setRepeatedField

        public WebKeySettings.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                       int index,
                                                       Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • addRepeatedField

        public WebKeySettings.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                       Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • mergeFrom

        public WebKeySettings.Builder mergeFrom​(com.google.protobuf.Message other)
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<WebKeySettings.Builder>
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • mergeFrom

        public WebKeySettings.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                         throws IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<WebKeySettings.Builder>
        Throws:
        IOException
      • getAllowAllDomains

        public boolean getAllowAllDomains()
         If set to true, it means allowed_domains will not be enforced.
         
        bool allow_all_domains = 3;
        Specified by:
        getAllowAllDomains in interface WebKeySettingsOrBuilder
        Returns:
        The allowAllDomains.
      • setAllowAllDomains

        public WebKeySettings.Builder setAllowAllDomains​(boolean value)
         If set to true, it means allowed_domains will not be enforced.
         
        bool allow_all_domains = 3;
        Parameters:
        value - The allowAllDomains to set.
        Returns:
        This builder for chaining.
      • clearAllowAllDomains

        public WebKeySettings.Builder clearAllowAllDomains()
         If set to true, it means allowed_domains will not be enforced.
         
        bool allow_all_domains = 3;
        Returns:
        This builder for chaining.
      • getAllowedDomainsList

        public com.google.protobuf.ProtocolStringList getAllowedDomainsList()
         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'
         
        repeated string allowed_domains = 1;
        Specified by:
        getAllowedDomainsList in interface WebKeySettingsOrBuilder
        Returns:
        A list containing the allowedDomains.
      • getAllowedDomainsCount

        public int getAllowedDomainsCount()
         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'
         
        repeated string allowed_domains = 1;
        Specified by:
        getAllowedDomainsCount in interface WebKeySettingsOrBuilder
        Returns:
        The count of allowedDomains.
      • getAllowedDomains

        public String getAllowedDomains​(int index)
         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'
         
        repeated string allowed_domains = 1;
        Specified by:
        getAllowedDomains in interface WebKeySettingsOrBuilder
        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)
         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'
         
        repeated string allowed_domains = 1;
        Specified by:
        getAllowedDomainsBytes in interface WebKeySettingsOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the allowedDomains at the given index.
      • setAllowedDomains

        public WebKeySettings.Builder setAllowedDomains​(int index,
                                                        String value)
         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'
         
        repeated string allowed_domains = 1;
        Parameters:
        index - The index to set the value at.
        value - The allowedDomains to set.
        Returns:
        This builder for chaining.
      • addAllowedDomains

        public WebKeySettings.Builder addAllowedDomains​(String value)
         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'
         
        repeated string allowed_domains = 1;
        Parameters:
        value - The allowedDomains to add.
        Returns:
        This builder for chaining.
      • addAllAllowedDomains

        public WebKeySettings.Builder addAllAllowedDomains​(Iterable<String> values)
         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'
         
        repeated string allowed_domains = 1;
        Parameters:
        values - The allowedDomains to add.
        Returns:
        This builder for chaining.
      • clearAllowedDomains

        public WebKeySettings.Builder clearAllowedDomains()
         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'
         
        repeated string allowed_domains = 1;
        Returns:
        This builder for chaining.
      • addAllowedDomainsBytes

        public WebKeySettings.Builder addAllowedDomainsBytes​(com.google.protobuf.ByteString value)
         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'
         
        repeated string allowed_domains = 1;
        Parameters:
        value - The bytes of the allowedDomains to add.
        Returns:
        This builder for chaining.
      • getAllowAmpTraffic

        public boolean getAllowAmpTraffic()
         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;
        Specified by:
        getAllowAmpTraffic in interface WebKeySettingsOrBuilder
        Returns:
        The allowAmpTraffic.
      • setAllowAmpTraffic

        public WebKeySettings.Builder setAllowAmpTraffic​(boolean value)
         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;
        Parameters:
        value - The allowAmpTraffic to set.
        Returns:
        This builder for chaining.
      • clearAllowAmpTraffic

        public WebKeySettings.Builder clearAllowAmpTraffic()
         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;
        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:
        getIntegrationTypeValue in interface WebKeySettingsOrBuilder
        Returns:
        The enum numeric value on the wire for integrationType.
      • setIntegrationTypeValue

        public WebKeySettings.Builder setIntegrationTypeValue​(int value)
         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

        public WebKeySettings.IntegrationType 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:
        getIntegrationType in interface WebKeySettingsOrBuilder
        Returns:
        The integrationType.
      • setIntegrationType

        public WebKeySettings.Builder setIntegrationType​(WebKeySettings.IntegrationType value)
         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

        public WebKeySettings.Builder 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()
         Settings for the frequency and difficulty at which this key triggers
         captcha challenges. This should only be specified for IntegrationTypes
         CHECKBOX and INVISIBLE.
         
        .google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5;
        Specified by:
        getChallengeSecurityPreferenceValue in interface WebKeySettingsOrBuilder
        Returns:
        The enum numeric value on the wire for challengeSecurityPreference.
      • setChallengeSecurityPreferenceValue

        public WebKeySettings.Builder setChallengeSecurityPreferenceValue​(int value)
         Settings for the frequency and difficulty at which this key triggers
         captcha challenges. This should only be specified for IntegrationTypes
         CHECKBOX and INVISIBLE.
         
        .google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5;
        Parameters:
        value - The enum numeric value on the wire for challengeSecurityPreference to set.
        Returns:
        This builder for chaining.
      • getChallengeSecurityPreference

        public WebKeySettings.ChallengeSecurityPreference getChallengeSecurityPreference()
         Settings for the frequency and difficulty at which this key triggers
         captcha challenges. This should only be specified for IntegrationTypes
         CHECKBOX and INVISIBLE.
         
        .google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5;
        Specified by:
        getChallengeSecurityPreference in interface WebKeySettingsOrBuilder
        Returns:
        The challengeSecurityPreference.
      • setChallengeSecurityPreference

        public WebKeySettings.Builder setChallengeSecurityPreference​(WebKeySettings.ChallengeSecurityPreference value)
         Settings for the frequency and difficulty at which this key triggers
         captcha challenges. This should only be specified for IntegrationTypes
         CHECKBOX and INVISIBLE.
         
        .google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5;
        Parameters:
        value - The challengeSecurityPreference to set.
        Returns:
        This builder for chaining.
      • clearChallengeSecurityPreference

        public WebKeySettings.Builder clearChallengeSecurityPreference()
         Settings for the frequency and difficulty at which this key triggers
         captcha challenges. This should only be specified for IntegrationTypes
         CHECKBOX and INVISIBLE.
         
        .google.cloud.recaptchaenterprise.v1.WebKeySettings.ChallengeSecurityPreference challenge_security_preference = 5;
        Returns:
        This builder for chaining.
      • setUnknownFields

        public final WebKeySettings.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>
      • mergeUnknownFields

        public final WebKeySettings.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<WebKeySettings.Builder>