DataConnectorImplementations
The DataConnectorImplementations type lists the async functions required to read and write Atoms.
{
connect?: (syncChangedAtoms: (...address: AtomAddress<Depth>[]) => Promise<void>) => Promise<void>;
disconnect?: () => Promise<void>;
readAtom: (address: AtomAddress<Depth>) => Promise<Atom | undefined>;
writeAtom: (address: AtomAddress<Depth>, atom: Atom) => Promise<void>;
removeAtom: (address: AtomAddress<Depth>) => Promise<void>;
readChildIds: (address: AnyParentAddress<Depth>) => Promise<string[]>;
}| Type | Description | |
|---|---|---|
connect? | (syncChangedAtoms: (...address: AtomAddress<Depth>[]) => Promise<void>) => Promise<void> | The connect callback is invoked when the |
disconnect? | () => Promise<void> | The disconnect callback is invoked when the |
readAtom | (address: AtomAddress<Depth>) => Promise<Atom | undefined> | The readAtom callback must retrieve the |
writeAtom | (address: AtomAddress<Depth>, atom: Atom) => Promise<void> | The writeAtom callback must persist the provided |
removeAtom | (address: AtomAddress<Depth>) => Promise<void> | The removeAtom callback must delete the |
readChildIds | (address: AnyParentAddress<Depth>) => Promise<string[]> | The readChildIds callback must return an array of child ID strings that exist under the specified parent address. For |
Since
v0.0.0