Skip to main content

NativeSyncularClient

Struct NativeSyncularClient 

Source
pub struct NativeSyncularClient { /* private fields */ }

Implementations§

Source§

impl NativeSyncularClient

Source

pub fn builder(config: NativeClientConfig) -> NativeSyncularClientBuilder

Source

pub fn open(config: SyncularClientConfig) -> Result<Self>

Source

pub fn open_native(config: NativeClientConfig) -> Result<Self>

Source

pub fn open_native_with_options( config: NativeClientConfig, options: NativeClientOptions, ) -> Result<Self>

Source

pub fn open_native_async_with_options( config: NativeClientConfig, options: NativeClientOptions, ) -> NativeClientOpenTask

Source

pub fn open_with_options( config: SyncularClientConfig, options: NativeClientOptions, ) -> Result<Self>

Source

pub fn open_with_options_and_schema( config: SyncularClientConfig, options: NativeClientOptions, app_schema: AppSchema, ) -> Result<Self>

Source

pub fn trigger_sync(&self) -> Result<()>

Source

pub fn trigger_sync_websocket(&self) -> Result<()>

Source

pub fn enqueue_sync_now(&self) -> Result<String>

Source

pub fn enqueue_sync_websocket(&self) -> Result<String>

Source

pub fn enqueue_mutation_json( &self, mutation_json: &str, local_row_json: Option<&str>, ) -> Result<String>

Source

pub fn enqueue_leased_mutation_json( &self, mutation_json: &str, local_row_json: Option<&str>, ) -> Result<String>

Source

pub fn enqueue_yjs_update_json(&self, update_json: &str) -> Result<String>

Source

pub fn enqueue_crdt_field_yjs_update_json( &self, request_json: &str, ) -> Result<String>

Source

pub fn enqueue_crdt_field_text_json(&self, request_json: &str) -> Result<String>

Source

pub fn enqueue_crdt_field_compaction_json( &self, request_json: &str, ) -> Result<String>

Source

pub fn enqueue_encrypted_crdt_update_json( &self, request_json: &str, ) -> Result<String>

Source

pub fn enqueue_encrypted_crdt_checkpoint_json( &self, request_json: &str, ) -> Result<String>

Source

pub fn enqueue_resolve_conflict( &self, id: &str, resolution: &str, ) -> Result<String>

Source

pub fn enqueue_refresh_snapshot_json( &self, request_json: &str, ) -> Result<String>

Source

pub fn enqueue_compact_storage_json( &self, options_json: Option<&str>, ) -> Result<String>

Source

pub fn enqueue_store_blob_file_json( &self, path: &str, options_json: Option<&str>, ) -> Result<String>

Source

pub fn enqueue_retrieve_blob_file_json( &self, ref_json: &str, path: &str, options_json: Option<&str>, ) -> Result<String>

Source

pub fn enqueue_process_blob_upload_queue(&self) -> Result<String>

Source

pub fn enqueue_prune_blob_cache(&self, max_bytes: i64) -> Result<String>

Source

pub fn enqueue_clear_blob_cache(&self) -> Result<String>

Source

pub fn set_auth_headers(&mut self, headers: SyncAuthHeaders) -> Result<()>

Source

pub fn set_auth_headers_json(&mut self, headers_json: &str) -> Result<()>

Source

pub fn set_subscriptions( &mut self, subscriptions: Vec<SubscriptionSpec>, ) -> Result<()>

Source

pub fn set_subscriptions_json(&mut self, subscriptions_json: &str) -> Result<()>

Source

pub fn force_subscriptions_bootstrap( &mut self, subscription_ids: Vec<String>, ) -> Result<usize>

Source

pub fn force_subscriptions_bootstrap_json( &mut self, subscription_ids_json: &str, ) -> Result<String>

Source

pub fn set_field_encryption( &mut self, encryption: Option<FieldEncryption>, ) -> Result<()>

Source

pub fn set_field_encryption_json(&mut self, config_json: &str) -> Result<()>

Source

pub fn set_encrypted_crdt( &mut self, encryption: Option<EncryptedCrdt>, ) -> Result<()>

Source

pub fn set_encrypted_crdt_json(&mut self, config_json: &str) -> Result<()>

Source

pub fn set_blob_encryption( &mut self, encryption: Option<BlobEncryption>, ) -> Result<()>

Source

pub fn set_blob_encryption_json(&mut self, config_json: &str) -> Result<()>

Source

pub fn encryption_helper_json( &self, method: &str, args_json: &str, ) -> Result<String>

Source

pub fn pause_sync_worker(&mut self) -> Result<()>

Source

pub fn resume_sync_worker(&mut self) -> Result<()>

Source

pub fn resume_from_background(&mut self) -> Result<String>

Source

pub fn shutdown(&mut self) -> Result<()>

Source

pub fn start_realtime_worker(&mut self) -> Result<()>

Source

pub fn stop_realtime_worker(&mut self) -> Result<()>

Source

pub fn sync_worker_running(&self) -> bool

Source

pub fn join_presence( &mut self, scope_key: &str, metadata: Option<Value>, ) -> Result<()>

Source

pub fn join_presence_handle( &mut self, scope_key: &str, metadata: Option<Value>, ) -> Result<NativePresenceHandle<'_>>

Source

pub fn leave_presence(&mut self, scope_key: &str) -> Result<()>

Source

pub fn update_presence_metadata( &mut self, scope_key: &str, metadata: Value, ) -> Result<()>

Source

pub fn presence_json(&self, scope_key: &str) -> Result<String>

Source

pub fn subscribe_events(&self, capacity: usize) -> NativeEventSubscription

Source

pub fn event_receiver(&self, capacity: usize) -> NativeEventSubscription

Source

pub fn next_event(&self) -> Option<NativeEvent>

Source

pub fn next_event_timeout(&self, timeout: Duration) -> Option<NativeEvent>

Source

pub fn next_event_json(&self) -> Option<Result<String>>

Source

pub fn next_event_json_timeout( &self, timeout: Duration, ) -> Option<Result<String>>

Source

pub fn apply_mutation_json( &mut self, mutation_json: &str, local_row_json: Option<&str>, ) -> Result<String>

Source

pub fn apply_leased_mutation_json( &mut self, mutation_json: &str, local_row_json: Option<&str>, ) -> Result<String>

Source

pub fn open_crdt_field_json(&self, request_json: &str) -> Result<String>

Source

pub fn apply_crdt_field_text_json( &mut self, request_json: &str, ) -> Result<String>

Source

pub fn apply_crdt_field_yjs_update_json( &mut self, request_json: &str, ) -> Result<String>

Source

pub fn materialize_crdt_field_json( &mut self, request_json: &str, ) -> Result<String>

Source

pub fn crdt_document_snapshot_json( &mut self, request_json: &str, ) -> Result<String>

Source

pub fn crdt_update_log_json(&mut self, request_json: &str) -> Result<String>

Source

pub fn snapshot_crdt_field_state_vector_json( &mut self, request_json: &str, ) -> Result<String>

Source

pub fn compact_crdt_field_json(&mut self, request_json: &str) -> Result<String>

Source

pub fn apply_encrypted_crdt_update_json( &mut self, request_json: &str, ) -> Result<String>

Source

pub fn apply_encrypted_crdt_checkpoint_json( &mut self, request_json: &str, ) -> Result<String>

Source

pub fn list_table_json(&mut self, table: &str) -> Result<String>

Source

pub fn query_json(&self, request_json: &str) -> Result<String>

Source

pub fn store_blob_file_json( &mut self, path: &str, options_json: Option<&str>, ) -> Result<String>

Source

pub fn retrieve_blob_file(&mut self, ref_json: &str, path: &str) -> Result<()>

Source

pub fn retrieve_blob_file_with_options( &mut self, ref_json: &str, path: &str, options_json: Option<&str>, ) -> Result<()>

Source

pub fn is_blob_local(&mut self, hash: &str) -> Result<bool>

Source

pub fn process_blob_upload_queue_json(&mut self) -> Result<String>

Source

pub fn blob_upload_queue_stats_json(&mut self) -> Result<String>

Source

pub fn blob_cache_stats_json(&mut self) -> Result<String>

Source

pub fn prune_blob_cache(&mut self, max_bytes: i64) -> Result<i64>

Source

pub fn clear_blob_cache(&mut self) -> Result<()>

Source

pub fn compact_storage_json( &mut self, options_json: Option<&str>, ) -> Result<String>

Source

pub fn app_tables(&self) -> Vec<String>

Source

pub fn app_tables_json(&self) -> Result<String>

Source

pub fn app_table_metadata_json(&self) -> Result<String>

Source

pub fn app_schema_state_json(&mut self) -> Result<String>

Source

pub fn local_health_check_json(&mut self) -> Result<String>

Source

pub fn export_local_support_bundle_json(&mut self) -> Result<String>

Source

pub fn import_local_support_bundle_json( &mut self, bundle_json: &str, ) -> Result<String>

Source

pub fn repair_local_health_json(&mut self, request_json: &str) -> Result<String>

Source

pub fn reset_local_sync_state_json( &mut self, request_json: &str, ) -> Result<String>

Source

pub fn register_query_json(&self, query_json: &str) -> Result<String>

Source

pub fn unregister_query(&self, id: &str) -> Result<()>

Source

pub fn observed_queries(&self) -> Result<Vec<NativeObservedQuery>>

Source

pub fn observed_queries_json(&self) -> Result<String>

Source

pub fn diagnostic_snapshot(&mut self) -> Result<NativeDiagnosticSnapshot>

Source

pub fn diagnostic_snapshot_json(&mut self) -> Result<String>

Source

pub fn outbox_summaries(&mut self) -> Result<Vec<OutboxSummary>>

Source

pub fn outbox_summaries_json(&mut self) -> Result<String>

Source

pub fn upsert_auth_lease_json(&mut self, lease_json: &str) -> Result<()>

Source

pub fn issue_auth_lease_json(&mut self, request_json: &str) -> Result<String>

Source

pub fn auth_lease_json(&mut self, lease_id: &str) -> Result<String>

Source

pub fn active_auth_leases_json( &mut self, actor_id: Option<&str>, now_ms_value: i64, ) -> Result<String>

Source

pub fn set_outbox_auth_lease_json( &mut self, client_commit_id: &str, provenance_json: Option<&str>, ) -> Result<()>

Source

pub fn conflict_summaries(&mut self) -> Result<Vec<ConflictSummary>>

Source

pub fn conflict_summaries_json(&mut self) -> Result<String>

Source

pub fn resolve_conflict(&mut self, id: &str, resolution: &str) -> Result<()>

Source

pub fn retry_conflict_keep_local(&mut self, id: &str) -> Result<String>

Source

pub fn close(&mut self) -> Result<()>

Trait Implementations§

Source§

impl Drop for NativeSyncularClient

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more
Source§

fn pin_drop(self: Pin<&mut Self>)

🔬This is a nightly-only experimental API. (pin_ergonomics)
Execute the destructor for this type, but different to Drop::drop, it requires self to be pinned. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> AggregateExpressionMethods for T

Source§

fn aggregate_distinct(self) -> Self::Output
where Self: DistinctDsl,

DISTINCT modifier for aggregate functions Read more
Source§

fn aggregate_all(self) -> Self::Output
where Self: AllDsl,

ALL modifier for aggregate functions Read more
Source§

fn aggregate_filter<P>(self, f: P) -> Self::Output
where P: AsExpression<Bool>, Self: FilterDsl<<P as AsExpression<Bool>>::Expression>,

Add an aggregate function filter Read more
Source§

fn aggregate_order<O>(self, o: O) -> Self::Output
where Self: OrderAggregateDsl<O>,

Add an aggregate function order Read more
Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> Downcast for T
where T: Any,

Source§

fn into_any(self: Box<T>) -> Box<dyn Any>

Converts Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.
Source§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

Converts Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further downcast into Rc<ConcreteType> where ConcreteType implements Trait.
Source§

fn as_any(&self) -> &(dyn Any + 'static)

Converts &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &Any’s vtable from &Trait’s.
Source§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

Converts &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &mut Any’s vtable from &mut Trait’s.
Source§

impl<T> DowncastSend for T
where T: Any + Send,

Source§

fn into_any_send(self: Box<T>) -> Box<dyn Any + Send>

Converts Box<Trait> (where Trait: DowncastSend) to Box<dyn Any + Send>, which can then be downcast into Box<ConcreteType> where ConcreteType implements Trait.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoSql for T

Source§

fn into_sql<T>(self) -> Self::Expression

Convert self to an expression for Diesel’s query builder. Read more
Source§

fn as_sql<'a, T>(&'a self) -> <&'a Self as AsExpression<T>>::Expression
where &'a Self: AsExpression<T>, T: SqlType + TypedExpressionType,

Convert &self to an expression for Diesel’s query builder. Read more
Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WindowExpressionMethods for T

Source§

fn over(self) -> Self::Output
where Self: OverDsl,

Turn a function call into a window function call Read more
Source§

fn window_filter<P>(self, f: P) -> Self::Output
where P: AsExpression<Bool>, Self: FilterDsl<<P as AsExpression<Bool>>::Expression>,

Add a filter to the current window function Read more
Source§

fn partition_by<E>(self, expr: E) -> Self::Output
where Self: PartitionByDsl<E>,

Add a partition clause to the current window function Read more
Source§

fn window_order<E>(self, expr: E) -> Self::Output
where Self: OrderWindowDsl<E>,

Add a order clause to the current window function Read more
Source§

fn frame_by<E>(self, expr: E) -> Self::Output
where Self: FrameDsl<E>,

Add a frame clause to the current window function Read more
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more