Package com.google.cloud.firestore
Class FirestoreOptions.Builder
java.lang.Object
com.google.cloud.ServiceOptions.Builder<Firestore,FirestoreOptions,FirestoreOptions.Builder>
com.google.cloud.firestore.FirestoreOptions.Builder
- Enclosing class:
- FirestoreOptions
public static class FirestoreOptions.Builder
extends com.google.cloud.ServiceOptions.Builder<Firestore,FirestoreOptions,FirestoreOptions.Builder>
-
Field Summary
Fields inherited from class com.google.cloud.ServiceOptions.Builder
credentials -
Method Summary
Modifier and TypeMethodDescriptionbuild()setChannelProvider(com.google.api.gax.rpc.TransportChannelProvider channelProvider) Sets theTransportChannelProviderto use with this Firestore client.setCredentialsProvider(com.google.api.gax.core.CredentialsProvider credentialsProvider) Sets theCredentialsProviderto use with this Firestore client.setDatabaseId(String databaseId) Sets the database ID to use with this Firestore client.setEmulatorHost(String emulatorHost) Sets the emulator host to use with this Firestore client.setTransportOptions(com.google.cloud.TransportOptions transportOptions) Sets theTransportOptionsto use with this Firestore client.Methods inherited from class com.google.cloud.ServiceOptions.Builder
getAllowedClientLibTokens, self, setClientLibToken, setClock, setCredentials, setHeaderProvider, setHost, setProjectId, setQuotaProjectId, setRetrySettings, setServiceFactory, setServiceRpcFactory, setUniverseDomain
-
Method Details
-
setTransportOptions
@Nonnull public FirestoreOptions.Builder setTransportOptions(@Nonnull com.google.cloud.TransportOptions transportOptions) Sets theTransportOptionsto use with this Firestore client.- Overrides:
setTransportOptionsin classcom.google.cloud.ServiceOptions.Builder<Firestore,FirestoreOptions, FirestoreOptions.Builder> - Parameters:
transportOptions- A GrpcTransportOptions object that defines the transport options for this client.
-
setChannelProvider
@Nonnull public FirestoreOptions.Builder setChannelProvider(@Nonnull com.google.api.gax.rpc.TransportChannelProvider channelProvider) Sets theTransportChannelProviderto use with this Firestore client.- Parameters:
channelProvider- A InstantiatingGrpcChannelProvider object that defines the transport provider for this client.
-
setCredentialsProvider
@Nonnull public FirestoreOptions.Builder setCredentialsProvider(@Nonnull com.google.api.gax.core.CredentialsProvider credentialsProvider) Sets theCredentialsProviderto use with this Firestore client.- Parameters:
credentialsProvider- A CredentialsProvider object that defines the credential provider for this client.
-
setEmulatorHost
Sets the emulator host to use with this Firestore client. The value passed to this method will take precedent if theFIRESTORE_EMULATOR_HOSTenvironment variable is also set.- Parameters:
emulatorHost- The Firestore emulator host to use with this client.
-
setDatabaseId
Sets the database ID to use with this Firestore client.- Parameters:
databaseId- The Firestore database ID to use with this client.
-
build
- Specified by:
buildin classcom.google.cloud.ServiceOptions.Builder<Firestore,FirestoreOptions, FirestoreOptions.Builder>
-