Aranya
a software development tool for governing access to data and services over a decentralized, zero-trust framework with secure end-to-end encrypted data exchange built-in.
Loading...
Searching...
No Matches
Related Symbols
AranyaSyncPeerConfigBuilder Struct Reference

Builder for a Sync Peer config `AranyaSyncPeerConfig`. More...

#include <aranya-client.h>

Related Symbols

(Note that these are not member symbols.)

AranyaError aranya_sync_peer_config_builder_init (struct AranyaSyncPeerConfigBuilder *out)
 Initializes AranyaSyncPeerConfigBuilder.
 
AranyaError aranya_sync_peer_config_builder_cleanup (struct AranyaSyncPeerConfigBuilder *ptr)
 Releases any resources associated with ptr.
 
AranyaError aranya_sync_peer_config_build (struct AranyaSyncPeerConfigBuilder *cfg, struct AranyaSyncPeerConfig *out)
 Attempts to build a `AranyaSyncPeerConfig`.
 
AranyaError aranya_sync_peer_config_build_ext (struct AranyaSyncPeerConfigBuilder *cfg, struct AranyaSyncPeerConfig *out, struct AranyaExtError *__ext_err)
 Attempts to build a `AranyaSyncPeerConfig`.
 
AranyaError aranya_sync_peer_config_builder_set_interval (struct AranyaSyncPeerConfigBuilder *cfg, AranyaDuration interval)
 Configures how often the peer will be synced with.
 
AranyaError aranya_sync_peer_config_builder_set_interval_ext (struct AranyaSyncPeerConfigBuilder *cfg, AranyaDuration interval, struct AranyaExtError *__ext_err)
 Configures how often the peer will be synced with.
 
AranyaError aranya_sync_peer_config_builder_set_sync_now (struct AranyaSyncPeerConfigBuilder *cfg)
 Updates the config to enable immediate syncing with the peer.
 
AranyaError aranya_sync_peer_config_builder_set_sync_now_ext (struct AranyaSyncPeerConfigBuilder *cfg, struct AranyaExtError *__ext_err)
 Updates the config to enable immediate syncing with the peer.
 
AranyaError aranya_sync_peer_config_builder_set_sync_later (struct AranyaSyncPeerConfigBuilder *cfg)
 Updates the config to disable immediate syncing with the peer.
 
AranyaError aranya_sync_peer_config_builder_set_sync_later_ext (struct AranyaSyncPeerConfigBuilder *cfg, struct AranyaExtError *__ext_err)
 Updates the config to disable immediate syncing with the peer.
 
AranyaError aranya_sync_peer_config_builder_set_sync_on_hello (struct AranyaSyncPeerConfigBuilder *cfg, uint32_t sync_on_hello)
 Sets whether automatic syncing should occur when a hello message is received from this peer indicating they have a head that we don't have.
 
AranyaError aranya_sync_peer_config_builder_set_sync_on_hello_ext (struct AranyaSyncPeerConfigBuilder *cfg, uint32_t sync_on_hello, struct AranyaExtError *__ext_err)
 Sets whether automatic syncing should occur when a hello message is received from this peer indicating they have a head that we don't have.
 

Detailed Description

Builder for a Sync Peer config `AranyaSyncPeerConfig`.

Friends And Related Symbol Documentation

◆ aranya_sync_peer_config_build()

AranyaError aranya_sync_peer_config_build ( struct AranyaSyncPeerConfigBuilder cfg,
struct AranyaSyncPeerConfig out 
)
related

Attempts to build a `AranyaSyncPeerConfig`.

This function consumes and releases any resources associated with the memory pointed to by cfg.

Parameters
[in]cfga pointer to the builder for a sync config
[out]outa pointer to write the sync config to

◆ aranya_sync_peer_config_build_ext()

AranyaError aranya_sync_peer_config_build_ext ( struct AranyaSyncPeerConfigBuilder cfg,
struct AranyaSyncPeerConfig out,
struct AranyaExtError __ext_err 
)
related

Attempts to build a `AranyaSyncPeerConfig`.

This function consumes and releases any resources associated with the memory pointed to by cfg.

Parameters
[in]cfga pointer to the builder for a sync config
[out]outa pointer to write the sync config to

◆ aranya_sync_peer_config_builder_cleanup()

AranyaError aranya_sync_peer_config_builder_cleanup ( struct AranyaSyncPeerConfigBuilder ptr)
related

Releases any resources associated with ptr.

ptr must either be null or initialized by aranya_sync_peer_config_builder_init.

◆ aranya_sync_peer_config_builder_init()

AranyaError aranya_sync_peer_config_builder_init ( struct AranyaSyncPeerConfigBuilder out)
related

Initializes AranyaSyncPeerConfigBuilder.

When no longer needed, out's resources must be released with its cleanup routine.

◆ aranya_sync_peer_config_builder_set_interval()

AranyaError aranya_sync_peer_config_builder_set_interval ( struct AranyaSyncPeerConfigBuilder cfg,
AranyaDuration  interval 
)
related

Configures how often the peer will be synced with.

By default, the interval is not set. It is an error to call `aranya_sync_peer_config_build` before setting the interval with this function

Parameters
[in,out]cfga pointer to the builder for a sync config
[in]intervalSet the interval at which syncing occurs (maximum 1 year)

◆ aranya_sync_peer_config_builder_set_interval_ext()

AranyaError aranya_sync_peer_config_builder_set_interval_ext ( struct AranyaSyncPeerConfigBuilder cfg,
AranyaDuration  interval,
struct AranyaExtError __ext_err 
)
related

Configures how often the peer will be synced with.

By default, the interval is not set. It is an error to call `aranya_sync_peer_config_build` before setting the interval with this function

Parameters
[in,out]cfga pointer to the builder for a sync config
[in]intervalSet the interval at which syncing occurs (maximum 1 year)

◆ aranya_sync_peer_config_builder_set_sync_later()

AranyaError aranya_sync_peer_config_builder_set_sync_later ( struct AranyaSyncPeerConfigBuilder cfg)
related

Updates the config to disable immediate syncing with the peer.

Overrides `aranya_sync_peer_config_builder_set_sync_now` if invoked afterward.

By default, the peer is synced with immediately.

Parameters
[in,out]cfga pointer to the builder for a sync config

◆ aranya_sync_peer_config_builder_set_sync_later_ext()

AranyaError aranya_sync_peer_config_builder_set_sync_later_ext ( struct AranyaSyncPeerConfigBuilder cfg,
struct AranyaExtError __ext_err 
)
related

Updates the config to disable immediate syncing with the peer.

Overrides `aranya_sync_peer_config_builder_set_sync_now` if invoked afterward.

By default, the peer is synced with immediately.

Parameters
[in,out]cfga pointer to the builder for a sync config

◆ aranya_sync_peer_config_builder_set_sync_now()

AranyaError aranya_sync_peer_config_builder_set_sync_now ( struct AranyaSyncPeerConfigBuilder cfg)
related

Updates the config to enable immediate syncing with the peer.

Overrides `aranya_sync_peer_config_builder_set_sync_later` if invoked afterward.

By default, the peer is synced with immediately.

Parameters
[in,out]cfga pointer to the builder for a sync config

◆ aranya_sync_peer_config_builder_set_sync_now_ext()

AranyaError aranya_sync_peer_config_builder_set_sync_now_ext ( struct AranyaSyncPeerConfigBuilder cfg,
struct AranyaExtError __ext_err 
)
related

Updates the config to enable immediate syncing with the peer.

Overrides `aranya_sync_peer_config_builder_set_sync_later` if invoked afterward.

By default, the peer is synced with immediately.

Parameters
[in,out]cfga pointer to the builder for a sync config

◆ aranya_sync_peer_config_builder_set_sync_on_hello()

AranyaError aranya_sync_peer_config_builder_set_sync_on_hello ( struct AranyaSyncPeerConfigBuilder cfg,
uint32_t  sync_on_hello 
)
related

Sets whether automatic syncing should occur when a hello message is received from this peer indicating they have a head that we don't have.

By default, sync on hello is disabled.

Parameters
[in,out]cfga pointer to the builder for a sync config
[in]sync_on_hellowhether to enable or disable sync on hello (0 = false, non-zero = true)

◆ aranya_sync_peer_config_builder_set_sync_on_hello_ext()

AranyaError aranya_sync_peer_config_builder_set_sync_on_hello_ext ( struct AranyaSyncPeerConfigBuilder cfg,
uint32_t  sync_on_hello,
struct AranyaExtError __ext_err 
)
related

Sets whether automatic syncing should occur when a hello message is received from this peer indicating they have a head that we don't have.

By default, sync on hello is disabled.

Parameters
[in,out]cfga pointer to the builder for a sync config
[in]sync_on_hellowhether to enable or disable sync on hello (0 = false, non-zero = true)

The documentation for this struct was generated from the following file: