Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion sync-client.md
Original file line number Diff line number Diff line change
Expand Up @@ -1210,7 +1210,24 @@ syncClient.setSyncChangeListener(null)
{% endtab %}

{% tab title="Swift" %}
_Coming soon!_
```swift
import ObjectBox

class MyChangeListener: SyncChangeListener {
func changed(_ changes: [obx_schema_id : SyncChange]) {
for (schemaId, change) in changes {
// schemaId identifies the entity for which the changes were recorded
// change.puts is an [Id] containing the ids of objects
// that were created/updated
// change.removals is an [Id] containing the ids of objects
// that were removed/deleted
}
}
}

// set the listener when building the client
client.changeListener = MyChangeListener()
```
{% endtab %}

{% tab title="Dart/Flutter" %}
Expand Down