Class GitConfig.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<GitConfig.Builder>
com.google.cloud.gkehub.configmanagement.v1beta.GitConfig.Builder
All Implemented Interfaces:
GitConfigOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
GitConfig

public static final class GitConfig.Builder extends com.google.protobuf.GeneratedMessage.Builder<GitConfig.Builder> implements GitConfigOrBuilder
 Git repo configuration for a single cluster.
 
Protobuf type google.cloud.gkehub.configmanagement.v1beta.GitConfig
  • 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<GitConfig.Builder>
    • clear

      public GitConfig.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<GitConfig.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<GitConfig.Builder>
    • getDefaultInstanceForType

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

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

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

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

      public GitConfig.Builder mergeFrom(GitConfig other)
    • isInitialized

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

      public GitConfig.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<GitConfig.Builder>
      Throws:
      IOException
    • getSyncRepo

      public String getSyncRepo()
       Required. The URL of the Git repository to use as the source of truth.
       
      string sync_repo = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getSyncRepo in interface GitConfigOrBuilder
      Returns:
      The syncRepo.
    • getSyncRepoBytes

      public com.google.protobuf.ByteString getSyncRepoBytes()
       Required. The URL of the Git repository to use as the source of truth.
       
      string sync_repo = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getSyncRepoBytes in interface GitConfigOrBuilder
      Returns:
      The bytes for syncRepo.
    • setSyncRepo

      public GitConfig.Builder setSyncRepo(String value)
       Required. The URL of the Git repository to use as the source of truth.
       
      string sync_repo = 1 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The syncRepo to set.
      Returns:
      This builder for chaining.
    • clearSyncRepo

      public GitConfig.Builder clearSyncRepo()
       Required. The URL of the Git repository to use as the source of truth.
       
      string sync_repo = 1 [(.google.api.field_behavior) = REQUIRED];
      Returns:
      This builder for chaining.
    • setSyncRepoBytes

      public GitConfig.Builder setSyncRepoBytes(com.google.protobuf.ByteString value)
       Required. The URL of the Git repository to use as the source of truth.
       
      string sync_repo = 1 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The bytes for syncRepo to set.
      Returns:
      This builder for chaining.
    • getSyncBranch

      public String getSyncBranch()
       Optional. The branch of the repository to sync from. Default: master.
       
      string sync_branch = 2 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getSyncBranch in interface GitConfigOrBuilder
      Returns:
      The syncBranch.
    • getSyncBranchBytes

      public com.google.protobuf.ByteString getSyncBranchBytes()
       Optional. The branch of the repository to sync from. Default: master.
       
      string sync_branch = 2 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getSyncBranchBytes in interface GitConfigOrBuilder
      Returns:
      The bytes for syncBranch.
    • setSyncBranch

      public GitConfig.Builder setSyncBranch(String value)
       Optional. The branch of the repository to sync from. Default: master.
       
      string sync_branch = 2 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The syncBranch to set.
      Returns:
      This builder for chaining.
    • clearSyncBranch

      public GitConfig.Builder clearSyncBranch()
       Optional. The branch of the repository to sync from. Default: master.
       
      string sync_branch = 2 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • setSyncBranchBytes

      public GitConfig.Builder setSyncBranchBytes(com.google.protobuf.ByteString value)
       Optional. The branch of the repository to sync from. Default: master.
       
      string sync_branch = 2 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The bytes for syncBranch to set.
      Returns:
      This builder for chaining.
    • getPolicyDir

      public String getPolicyDir()
       Optional. The path within the Git repository that represents the top level
       of the repo to sync. Default: the root directory of the repository.
       
      string policy_dir = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getPolicyDir in interface GitConfigOrBuilder
      Returns:
      The policyDir.
    • getPolicyDirBytes

      public com.google.protobuf.ByteString getPolicyDirBytes()
       Optional. The path within the Git repository that represents the top level
       of the repo to sync. Default: the root directory of the repository.
       
      string policy_dir = 3 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getPolicyDirBytes in interface GitConfigOrBuilder
      Returns:
      The bytes for policyDir.
    • setPolicyDir

      public GitConfig.Builder setPolicyDir(String value)
       Optional. The path within the Git repository that represents the top level
       of the repo to sync. Default: the root directory of the repository.
       
      string policy_dir = 3 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The policyDir to set.
      Returns:
      This builder for chaining.
    • clearPolicyDir

      public GitConfig.Builder clearPolicyDir()
       Optional. The path within the Git repository that represents the top level
       of the repo to sync. Default: the root directory of the repository.
       
      string policy_dir = 3 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • setPolicyDirBytes

      public GitConfig.Builder setPolicyDirBytes(com.google.protobuf.ByteString value)
       Optional. The path within the Git repository that represents the top level
       of the repo to sync. Default: the root directory of the repository.
       
      string policy_dir = 3 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The bytes for policyDir to set.
      Returns:
      This builder for chaining.
    • getSyncWaitSecs

      public long getSyncWaitSecs()
       Optional. Period in seconds between consecutive syncs. Default: 15.
       
      int64 sync_wait_secs = 4 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getSyncWaitSecs in interface GitConfigOrBuilder
      Returns:
      The syncWaitSecs.
    • setSyncWaitSecs

      public GitConfig.Builder setSyncWaitSecs(long value)
       Optional. Period in seconds between consecutive syncs. Default: 15.
       
      int64 sync_wait_secs = 4 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The syncWaitSecs to set.
      Returns:
      This builder for chaining.
    • clearSyncWaitSecs

      public GitConfig.Builder clearSyncWaitSecs()
       Optional. Period in seconds between consecutive syncs. Default: 15.
       
      int64 sync_wait_secs = 4 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • getSyncRev

      public String getSyncRev()
       Optional. Git revision (tag or hash) to check out. Default HEAD.
       
      string sync_rev = 5 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getSyncRev in interface GitConfigOrBuilder
      Returns:
      The syncRev.
    • getSyncRevBytes

      public com.google.protobuf.ByteString getSyncRevBytes()
       Optional. Git revision (tag or hash) to check out. Default HEAD.
       
      string sync_rev = 5 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getSyncRevBytes in interface GitConfigOrBuilder
      Returns:
      The bytes for syncRev.
    • setSyncRev

      public GitConfig.Builder setSyncRev(String value)
       Optional. Git revision (tag or hash) to check out. Default HEAD.
       
      string sync_rev = 5 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The syncRev to set.
      Returns:
      This builder for chaining.
    • clearSyncRev

      public GitConfig.Builder clearSyncRev()
       Optional. Git revision (tag or hash) to check out. Default HEAD.
       
      string sync_rev = 5 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • setSyncRevBytes

      public GitConfig.Builder setSyncRevBytes(com.google.protobuf.ByteString value)
       Optional. Git revision (tag or hash) to check out. Default HEAD.
       
      string sync_rev = 5 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The bytes for syncRev to set.
      Returns:
      This builder for chaining.
    • getSecretType

      public String getSecretType()
       Required. Type of secret configured for access to the Git repo.
       Must be one of `ssh`, `cookiefile`, `gcenode`, `token`,
       `gcpserviceaccount`, `githubapp` or `none`.
       The validation of this is case-sensitive.
       
      string secret_type = 6 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getSecretType in interface GitConfigOrBuilder
      Returns:
      The secretType.
    • getSecretTypeBytes

      public com.google.protobuf.ByteString getSecretTypeBytes()
       Required. Type of secret configured for access to the Git repo.
       Must be one of `ssh`, `cookiefile`, `gcenode`, `token`,
       `gcpserviceaccount`, `githubapp` or `none`.
       The validation of this is case-sensitive.
       
      string secret_type = 6 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getSecretTypeBytes in interface GitConfigOrBuilder
      Returns:
      The bytes for secretType.
    • setSecretType

      public GitConfig.Builder setSecretType(String value)
       Required. Type of secret configured for access to the Git repo.
       Must be one of `ssh`, `cookiefile`, `gcenode`, `token`,
       `gcpserviceaccount`, `githubapp` or `none`.
       The validation of this is case-sensitive.
       
      string secret_type = 6 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The secretType to set.
      Returns:
      This builder for chaining.
    • clearSecretType

      public GitConfig.Builder clearSecretType()
       Required. Type of secret configured for access to the Git repo.
       Must be one of `ssh`, `cookiefile`, `gcenode`, `token`,
       `gcpserviceaccount`, `githubapp` or `none`.
       The validation of this is case-sensitive.
       
      string secret_type = 6 [(.google.api.field_behavior) = REQUIRED];
      Returns:
      This builder for chaining.
    • setSecretTypeBytes

      public GitConfig.Builder setSecretTypeBytes(com.google.protobuf.ByteString value)
       Required. Type of secret configured for access to the Git repo.
       Must be one of `ssh`, `cookiefile`, `gcenode`, `token`,
       `gcpserviceaccount`, `githubapp` or `none`.
       The validation of this is case-sensitive.
       
      string secret_type = 6 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The bytes for secretType to set.
      Returns:
      This builder for chaining.
    • getHttpsProxy

      public String getHttpsProxy()
       Optional. URL for the HTTPS proxy to be used when communicating with the
       Git repo. Only specify when secret_type is `cookiefile`, `token`, or
       `none`.
       
      string https_proxy = 7 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getHttpsProxy in interface GitConfigOrBuilder
      Returns:
      The httpsProxy.
    • getHttpsProxyBytes

      public com.google.protobuf.ByteString getHttpsProxyBytes()
       Optional. URL for the HTTPS proxy to be used when communicating with the
       Git repo. Only specify when secret_type is `cookiefile`, `token`, or
       `none`.
       
      string https_proxy = 7 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getHttpsProxyBytes in interface GitConfigOrBuilder
      Returns:
      The bytes for httpsProxy.
    • setHttpsProxy

      public GitConfig.Builder setHttpsProxy(String value)
       Optional. URL for the HTTPS proxy to be used when communicating with the
       Git repo. Only specify when secret_type is `cookiefile`, `token`, or
       `none`.
       
      string https_proxy = 7 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The httpsProxy to set.
      Returns:
      This builder for chaining.
    • clearHttpsProxy

      public GitConfig.Builder clearHttpsProxy()
       Optional. URL for the HTTPS proxy to be used when communicating with the
       Git repo. Only specify when secret_type is `cookiefile`, `token`, or
       `none`.
       
      string https_proxy = 7 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • setHttpsProxyBytes

      public GitConfig.Builder setHttpsProxyBytes(com.google.protobuf.ByteString value)
       Optional. URL for the HTTPS proxy to be used when communicating with the
       Git repo. Only specify when secret_type is `cookiefile`, `token`, or
       `none`.
       
      string https_proxy = 7 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The bytes for httpsProxy to set.
      Returns:
      This builder for chaining.
    • getGcpServiceAccountEmail

      public String getGcpServiceAccountEmail()
       Optional. The Google Cloud Service Account Email used for auth when
       secret_type is `gcpserviceaccount`.
       
      string gcp_service_account_email = 8 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getGcpServiceAccountEmail in interface GitConfigOrBuilder
      Returns:
      The gcpServiceAccountEmail.
    • getGcpServiceAccountEmailBytes

      public com.google.protobuf.ByteString getGcpServiceAccountEmailBytes()
       Optional. The Google Cloud Service Account Email used for auth when
       secret_type is `gcpserviceaccount`.
       
      string gcp_service_account_email = 8 [(.google.api.field_behavior) = OPTIONAL];
      Specified by:
      getGcpServiceAccountEmailBytes in interface GitConfigOrBuilder
      Returns:
      The bytes for gcpServiceAccountEmail.
    • setGcpServiceAccountEmail

      public GitConfig.Builder setGcpServiceAccountEmail(String value)
       Optional. The Google Cloud Service Account Email used for auth when
       secret_type is `gcpserviceaccount`.
       
      string gcp_service_account_email = 8 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The gcpServiceAccountEmail to set.
      Returns:
      This builder for chaining.
    • clearGcpServiceAccountEmail

      public GitConfig.Builder clearGcpServiceAccountEmail()
       Optional. The Google Cloud Service Account Email used for auth when
       secret_type is `gcpserviceaccount`.
       
      string gcp_service_account_email = 8 [(.google.api.field_behavior) = OPTIONAL];
      Returns:
      This builder for chaining.
    • setGcpServiceAccountEmailBytes

      public GitConfig.Builder setGcpServiceAccountEmailBytes(com.google.protobuf.ByteString value)
       Optional. The Google Cloud Service Account Email used for auth when
       secret_type is `gcpserviceaccount`.
       
      string gcp_service_account_email = 8 [(.google.api.field_behavior) = OPTIONAL];
      Parameters:
      value - The bytes for gcpServiceAccountEmail to set.
      Returns:
      This builder for chaining.