Class AndroidKeySettings.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<AndroidKeySettings.Builder>
com.google.recaptchaenterprise.v1.AndroidKeySettings.Builder
All Implemented Interfaces:
com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, AndroidKeySettingsOrBuilder, Cloneable
Enclosing class:
AndroidKeySettings

public static final class AndroidKeySettings.Builder extends com.google.protobuf.GeneratedMessage.Builder<AndroidKeySettings.Builder> implements AndroidKeySettingsOrBuilder
 Settings specific to keys that can be used by Android apps.
 
Protobuf type google.cloud.recaptchaenterprise.v1.AndroidKeySettings
  • Method Details

    • getDescriptor

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

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<AndroidKeySettings.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.GeneratedMessage.Builder<AndroidKeySettings.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.GeneratedMessage.Builder<AndroidKeySettings.Builder>
    • getDefaultInstanceForType

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

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

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

      public AndroidKeySettings.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<AndroidKeySettings.Builder>
    • mergeFrom

    • isInitialized

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

      public AndroidKeySettings.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<AndroidKeySettings.Builder>
      Throws:
      IOException
    • getAllowAllPackageNames

      public boolean getAllowAllPackageNames()
       Optional. If set to true, allowed_package_names are not enforced.
       
      bool allow_all_package_names = 2 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getAllowAllPackageNames in interface AndroidKeySettingsOrBuilder
      Returns:
      The allowAllPackageNames.
    • setAllowAllPackageNames

      public AndroidKeySettings.Builder setAllowAllPackageNames(boolean value)
       Optional. If set to true, allowed_package_names are not enforced.
       
      bool allow_all_package_names = 2 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The allowAllPackageNames to set.
      Returns:
      This builder for chaining.
    • clearAllowAllPackageNames

      public AndroidKeySettings.Builder clearAllowAllPackageNames()
       Optional. If set to true, allowed_package_names are not enforced.
       
      bool allow_all_package_names = 2 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • getAllowedPackageNamesList

      public com.google.protobuf.ProtocolStringList getAllowedPackageNamesList()
       Optional. Android package names of apps allowed to use the key.
       Example: 'com.companyname.appname'
       Each key supports a maximum of 250 package names. To use a key on more
       apps, set `allow_all_package_names` to true. When this is set, you
       are responsible for validating the package name by checking the
       `token_properties.android_package_name` field in each assessment response
       against your list of allowed package names.
       
      repeated string allowed_package_names = 1 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getAllowedPackageNamesList in interface AndroidKeySettingsOrBuilder
      Returns:
      A list containing the allowedPackageNames.
    • getAllowedPackageNamesCount

      public int getAllowedPackageNamesCount()
       Optional. Android package names of apps allowed to use the key.
       Example: 'com.companyname.appname'
       Each key supports a maximum of 250 package names. To use a key on more
       apps, set `allow_all_package_names` to true. When this is set, you
       are responsible for validating the package name by checking the
       `token_properties.android_package_name` field in each assessment response
       against your list of allowed package names.
       
      repeated string allowed_package_names = 1 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getAllowedPackageNamesCount in interface AndroidKeySettingsOrBuilder
      Returns:
      The count of allowedPackageNames.
    • getAllowedPackageNames

      public String getAllowedPackageNames(int index)
       Optional. Android package names of apps allowed to use the key.
       Example: 'com.companyname.appname'
       Each key supports a maximum of 250 package names. To use a key on more
       apps, set `allow_all_package_names` to true. When this is set, you
       are responsible for validating the package name by checking the
       `token_properties.android_package_name` field in each assessment response
       against your list of allowed package names.
       
      repeated string allowed_package_names = 1 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getAllowedPackageNames in interface AndroidKeySettingsOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The allowedPackageNames at the given index.
    • getAllowedPackageNamesBytes

      public com.google.protobuf.ByteString getAllowedPackageNamesBytes(int index)
       Optional. Android package names of apps allowed to use the key.
       Example: 'com.companyname.appname'
       Each key supports a maximum of 250 package names. To use a key on more
       apps, set `allow_all_package_names` to true. When this is set, you
       are responsible for validating the package name by checking the
       `token_properties.android_package_name` field in each assessment response
       against your list of allowed package names.
       
      repeated string allowed_package_names = 1 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getAllowedPackageNamesBytes in interface AndroidKeySettingsOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the allowedPackageNames at the given index.
    • setAllowedPackageNames

      public AndroidKeySettings.Builder setAllowedPackageNames(int index, String value)
       Optional. Android package names of apps allowed to use the key.
       Example: 'com.companyname.appname'
       Each key supports a maximum of 250 package names. To use a key on more
       apps, set `allow_all_package_names` to true. When this is set, you
       are responsible for validating the package name by checking the
       `token_properties.android_package_name` field in each assessment response
       against your list of allowed package names.
       
      repeated string allowed_package_names = 1 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      index - The index to set the value at.
      value - The allowedPackageNames to set.
      Returns:
      This builder for chaining.
    • addAllowedPackageNames

      public AndroidKeySettings.Builder addAllowedPackageNames(String value)
       Optional. Android package names of apps allowed to use the key.
       Example: 'com.companyname.appname'
       Each key supports a maximum of 250 package names. To use a key on more
       apps, set `allow_all_package_names` to true. When this is set, you
       are responsible for validating the package name by checking the
       `token_properties.android_package_name` field in each assessment response
       against your list of allowed package names.
       
      repeated string allowed_package_names = 1 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The allowedPackageNames to add.
      Returns:
      This builder for chaining.
    • addAllAllowedPackageNames

      public AndroidKeySettings.Builder addAllAllowedPackageNames(Iterable<String> values)
       Optional. Android package names of apps allowed to use the key.
       Example: 'com.companyname.appname'
       Each key supports a maximum of 250 package names. To use a key on more
       apps, set `allow_all_package_names` to true. When this is set, you
       are responsible for validating the package name by checking the
       `token_properties.android_package_name` field in each assessment response
       against your list of allowed package names.
       
      repeated string allowed_package_names = 1 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      values - The allowedPackageNames to add.
      Returns:
      This builder for chaining.
    • clearAllowedPackageNames

      public AndroidKeySettings.Builder clearAllowedPackageNames()
       Optional. Android package names of apps allowed to use the key.
       Example: 'com.companyname.appname'
       Each key supports a maximum of 250 package names. To use a key on more
       apps, set `allow_all_package_names` to true. When this is set, you
       are responsible for validating the package name by checking the
       `token_properties.android_package_name` field in each assessment response
       against your list of allowed package names.
       
      repeated string allowed_package_names = 1 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • addAllowedPackageNamesBytes

      public AndroidKeySettings.Builder addAllowedPackageNamesBytes(com.google.protobuf.ByteString value)
       Optional. Android package names of apps allowed to use the key.
       Example: 'com.companyname.appname'
       Each key supports a maximum of 250 package names. To use a key on more
       apps, set `allow_all_package_names` to true. When this is set, you
       are responsible for validating the package name by checking the
       `token_properties.android_package_name` field in each assessment response
       against your list of allowed package names.
       
      repeated string allowed_package_names = 1 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The bytes of the allowedPackageNames to add.
      Returns:
      This builder for chaining.
    • getSupportNonGoogleAppStoreDistribution

      public boolean getSupportNonGoogleAppStoreDistribution()
       Optional. Set to true for keys that are used in an Android application that
       is available for download in app stores in addition to the Google Play
       Store.
       
      bool support_non_google_app_store_distribution = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getSupportNonGoogleAppStoreDistribution in interface AndroidKeySettingsOrBuilder
      Returns:
      The supportNonGoogleAppStoreDistribution.
    • setSupportNonGoogleAppStoreDistribution

      public AndroidKeySettings.Builder setSupportNonGoogleAppStoreDistribution(boolean value)
       Optional. Set to true for keys that are used in an Android application that
       is available for download in app stores in addition to the Google Play
       Store.
       
      bool support_non_google_app_store_distribution = 3 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The supportNonGoogleAppStoreDistribution to set.
      Returns:
      This builder for chaining.
    • clearSupportNonGoogleAppStoreDistribution

      public AndroidKeySettings.Builder clearSupportNonGoogleAppStoreDistribution()
       Optional. Set to true for keys that are used in an Android application that
       is available for download in app stores in addition to the Google Play
       Store.
       
      bool support_non_google_app_store_distribution = 3 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.