Skip to main content

Crate ashlar_store

Crate ashlar_store 

Source
Expand description

Documents: Arc snapshots, revisions, undo history, versioned formats with migrations, autosave.

  • Store: the document as an Arc<D>, edited copy-on-write, with a Revision per state, undo/redo, merged gestures, compound edits (Transaction) and dirty tracking.
  • History: the undo stacks on their own (labels, extra state, merge keys, step and byte limits, optional branches).
  • Tracked and Memo: per-part revisions and small revision-keyed caches for views.
  • SnapshotCell: the latest snapshot for real-time and worker threads, lock-free.
  • Format: the file envelope, migrations, refusal of newer and foreign files, durable saves.
  • Autosave: an autosave ring with crash detection and RecoveryCandidates.

Headless and wasm32-clean (the background autosave writer is native only).

Re-exports§

pub use autosave::BackgroundWriter;
pub use autosave::Autosave;
pub use autosave::AutosaveConfig;
pub use autosave::RecoveryCandidate;
pub use autosave::SessionMeta;
pub use autosave::SlotWrite;
pub use format::Envelope;
pub use format::Format;
pub use format::FormatError;
pub use format::JsonError;
pub use format::Loaded;
pub use format::Migration;
pub use history::Branch;
pub use history::Entry;
pub use history::History;
pub use revision::Memo;
pub use revision::Revision;
pub use revision::Tracked;
pub use revision::Versioned;
pub use snapshot::Published;
pub use snapshot::SnapshotCell;
pub use store::Store;
pub use store::Transaction;

Modules§

autosave
Autosave ring and crash recovery.
format
Versioned document files: an envelope, a migration chain, and durable saves.
history
Undo history of labelled document snapshots.
revision
Revision numbers, revision-tracked values and a small revision-keyed cache.
snapshot
Lock-free publishing of the latest document snapshot to other threads.
store
Store: a document as an Arc snapshot, edited copy-on-write, with revisions and undo.