@ParametersAreNonnullByDefault
See: Description
Interface | Description |
---|---|
SyncClient |
ObjectBox sync client.
|
Class | Description |
---|---|
ConnectivityMonitor |
Used by
SyncClient to observe connectivity changes. |
Sync |
ObjectBox Sync makes data available on other devices.
|
SyncBuilder |
A builder to create a
SyncClient ; the builder itself should be created via
Sync.client(BoxStore, String, SyncCredentials) . |
SyncChange |
A collection of changes made to one entity type during a sync transaction.
|
SyncClientImpl |
Internal sync client implementation.
|
SyncCredentials |
Use the static helper methods to build Sync credentials,
for example
SyncCredentials.sharedSecret("secret") . |
SyncCredentialsToken |
Internal credentials implementation.
|
SyncLoginCodes |
Codes used by
SyncLoginListener.onLoginFailed(long) . |
Enum | Description |
---|---|
SyncBuilder.RequestUpdatesMode | |
SyncCredentials.CredentialsType | |
SyncState |
Returned by
SyncClientImpl.getSyncState() . |
These are the typical steps to setup a sync client:
SyncBuilder
using Sync.client(
io.objectbox.BoxStore, java.lang.String, io.objectbox.sync.SyncCredentials)
.
Here you need to pass the BoxStore
, along with an URL to the sync destination (server),
and credentials. For demo set ups, you could start with SyncCredentials.none()
credentials.SyncBuilder
instance from the last step to configure the sync
client and set initial listeners.SyncBuilder.build()
SyncClient
(and hold on to it). Synchronization is now active.
SyncClient