Skip to main content

AdapterPositions

Trait AdapterPositions 

Source
pub trait AdapterPositions: Send + Sync {
    // Required methods
    fn record(&self, adapter: &str, key: &str, position: Value);
    fn resumed(&self, adapter: &str, key: &str) -> Option<Value>;
}
Expand description

Where an adapter keeps a resumable position in the session’s own checkpoint log (SRD-117 §9.6). The payload is the adapter’s.

Required Methods§

Source

fn record(&self, adapter: &str, key: &str, position: Value)

Record a position for adapter under key.

Source

fn resumed(&self, adapter: &str, key: &str) -> Option<Value>

The latest position this session recorded for adapter under key, when the session is a resumed one. None otherwise.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§