Skip to content

Commit a60a736

Browse files
authored
Added C4PeerSync::setProgressLevel() [API] (#2286)
1 parent 84af54e commit a60a736

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

C/Cpp_include/c4PeerSync.hh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,9 @@ struct C4PeerSync
8888
/// @note This function is thread-safe.
8989
C4PeerID thisPeerID() const noexcept;
9090

91+
/// Sets the level of progress notifications.
92+
void setProgressLevel(C4ReplicatorProgressLevel) noexcept;
93+
9194
/// Starts a C4PeerSync, beginning peer discovery and replication.
9295
/// This call is asynchronous and returns immediately.
9396
/// When it succeeds or fails, the delegate's \ref peerSyncStatus method will be called.
@@ -118,7 +121,7 @@ struct C4PeerSync
118121
PeerInfo getPeerInfo(C4PeerID const&);
119122

120123
// Version number of c4PeerSync.hh API. Incremented on incompatible changes.
121-
static constexpr int kAPIVersion = 4;
124+
static constexpr int kAPIVersion = 5;
122125

123126
private:
124127
class Impl;

C/include/c4PeerSync.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ CBL_CORE_API C4PeerSync* C4NULLABLE c4peersync_new(const C4PeerSyncParameters*,
2727
@note This function is thread-safe. */
2828
CBL_CORE_API C4PeerID c4peersync_getMyID(C4PeerSync*) C4API;
2929

30+
/** Sets a C4PeerSync's progress-notification level. */
31+
CBL_CORE_API void c4peersync_setProgressLevel(C4PeerSync*, C4ReplicatorProgressLevel) C4API;
32+
3033
/** Starts a C4PeerSync, beginning peer discovery and replication.
3134
This call is **asynchronous** and returns immediately. When it succeeds or fails, the
3235
`C4PeerSync_StatusCallback` will be called.

0 commit comments

Comments
 (0)