Class ComputeEngineCredentials.Builder (1.27.0)

publicstaticclass ComputeEngineCredentials.BuilderextendsGoogleCredentials.Builder

Inheritance

java.lang.Object > OAuth2Credentials.Builder > GoogleCredentials.Builder > ComputeEngineCredentials.Builder

Constructors

Builder()

protectedBuilder()

Builder(ComputeEngineCredentials credentials)

protectedBuilder(ComputeEngineCredentialscredentials)
Parameter
Name Description
credentials ComputeEngineCredentials

Methods

build()

publicComputeEngineCredentialsbuild()
Returns
Type Description
ComputeEngineCredentials
Overrides

getDefaultScopes()

publicCollection<String>getDefaultScopes()
Returns
Type Description
Collection<String>

getHttpTransportFactory()

publicHttpTransportFactorygetHttpTransportFactory()
Returns
Type Description
HttpTransportFactory

getScopes()

publicCollection<String>getScopes()
Returns
Type Description
Collection<String>

setDefaultScopes(Collection<String> defaultScopes)

publicComputeEngineCredentials.BuildersetDefaultScopes(Collection<String>defaultScopes)
Parameter
Name Description
defaultScopes Collection<String>
Returns
Type Description
ComputeEngineCredentials.Builder

setHttpTransportFactory(HttpTransportFactory transportFactory)

publicComputeEngineCredentials.BuildersetHttpTransportFactory(HttpTransportFactorytransportFactory)
Parameter
Name Description
transportFactory HttpTransportFactory
Returns
Type Description
ComputeEngineCredentials.Builder

setQuotaProjectId(String quotaProjectId)

publicComputeEngineCredentials.BuildersetQuotaProjectId(StringquotaProjectId)
Parameter
Name Description
quotaProjectId String
Returns
Type Description
ComputeEngineCredentials.Builder
Overrides

setScopes(Collection<String> scopes)

publicComputeEngineCredentials.BuildersetScopes(Collection<String>scopes)
Parameter
Name Description
scopes Collection<String>
Returns
Type Description
ComputeEngineCredentials.Builder

setUniverseDomain(String universeDomain)

publicComputeEngineCredentials.BuildersetUniverseDomain(StringuniverseDomain)
Parameter
Name Description
universeDomain String
Returns
Type Description
ComputeEngineCredentials.Builder
Overrides

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年10月30日 UTC.