Class FirestoreOptions.Builder

public static class FirestoreOptions.Builder extends ServiceOptions.Builder<Firestore,FirestoreOptions,FirestoreOptions.Builder>

Inheritance

java.lang.Object > com.google.cloud.ServiceOptions.Builder > FirestoreOptions.Builder

Methods

build()

public FirestoreOptions build()
Returns
TypeDescription
FirestoreOptions
Overrides
com.google.cloud.ServiceOptions.Builder.build()

setChannelProvider(TransportChannelProvider channelProvider)

public FirestoreOptions.Builder setChannelProvider(TransportChannelProvider channelProvider)

Sets the TransportChannelProvider to use with this Firestore client.

Parameter
NameDescription
channelProviderTransportChannelProvider

A InstantiatingGrpcChannelProvider object that defines the transport provider for this client.

Returns
TypeDescription
FirestoreOptions.Builder

setCredentialsProvider(CredentialsProvider credentialsProvider)

public FirestoreOptions.Builder setCredentialsProvider(CredentialsProvider credentialsProvider)

Sets the CredentialsProvider to use with this Firestore client.

Parameter
NameDescription
credentialsProviderCredentialsProvider

A CredentialsProvider object that defines the credential provider for this client.

Returns
TypeDescription
FirestoreOptions.Builder

setDatabaseId(String databaseId)

public FirestoreOptions.Builder setDatabaseId(String databaseId)

Sets the database ID to use with this Firestore client.

Parameter
NameDescription
databaseIdString

The Firestore database ID to use with this client.

Returns
TypeDescription
FirestoreOptions.Builder

setEmulatorHost(String emulatorHost)

public FirestoreOptions.Builder setEmulatorHost(String emulatorHost)

Sets the emulator host to use with this Firestore client. The value passed to this method will take precedent if the FIRESTORE_EMULATOR_HOST environment variable is also set.

Parameter
NameDescription
emulatorHostString

The Firestore emulator host to use with this client.

Returns
TypeDescription
FirestoreOptions.Builder

setTransportOptions(TransportOptions transportOptions)

public FirestoreOptions.Builder setTransportOptions(TransportOptions transportOptions)

Sets the TransportOptions to use with this Firestore client.

Parameter
NameDescription
transportOptionscom.google.cloud.TransportOptions

A GrpcTransportOptions object that defines the transport options for this client.

Returns
TypeDescription
FirestoreOptions.Builder
Overrides
com.google.cloud.ServiceOptions.Builder.setTransportOptions(com.google.cloud.TransportOptions)