FirebaseFirestoreSettings

public final class FirebaseFirestoreSettings


Settings used to configure a FirebaseFirestore instance.

Summary

Nested types

A Builder for creating FirebaseFirestoreSettings.

Constants

static final long

Constant to use with setCacheSizeBytes to disable garbage collection.

static final int

Public methods

boolean
@Nullable LocalCacheSettings

Returns the cache settings configured for the SDK.

long

This method is deprecated.

Instead, use getCacheSettings to check cache size.

int

Returns the gRPC flow control window size.

@NonNull String

Returns the host of the Cloud Firestore backend.

int
boolean

This method is deprecated.

Instead, use getCacheSettings to check which cache is used.

boolean

Returns whether or not to use SSL for communication.

@NonNull String

Constants

CACHE_SIZE_UNLIMITED

public static final long CACHE_SIZE_UNLIMITED = -1

Constant to use with setCacheSizeBytes to disable garbage collection.

DEFAULT_GRPC_FLOW_CONTROL_WINDOW

public static final int DEFAULT_GRPC_FLOW_CONTROL_WINDOW = 262144

Public fields

cacheSettings

public LocalCacheSettings cacheSettings

cacheSizeBytes

public final long cacheSizeBytes

grpcFlowControlWindow

public final int grpcFlowControlWindow

host

public final String host

Public methods

equals

public boolean equals(Object o)

getCacheSettings

public @Nullable LocalCacheSettings getCacheSettings()

Returns the cache settings configured for the SDK. Returns null if it is not configured, in which case a default PersistentCacheSettings instance is used.

getCacheSizeBytes

public long getCacheSizeBytes()

Returns the threshold for the cache size above which the SDK will attempt to collect the least recently used documents.

getGrpcFlowControlWindow

public int getGrpcFlowControlWindow()

Returns the gRPC flow control window size.

getHost

public @NonNull String getHost()

Returns the host of the Cloud Firestore backend.

hashCode

public int hashCode()

isPersistenceEnabled

public boolean isPersistenceEnabled()

Returns whether or not to use local persistent storage.

isSslEnabled

public boolean isSslEnabled()

Returns whether or not to use SSL for communication.

toString

public @NonNull String toString()