Add transaction (a list of deltas) as a primitive for applying sets of changes
... and Fix idomaticness
This commit is contained in:
parent
41f1a2b9a9
commit
7934252fb5
4 changed files with 62 additions and 3 deletions
|
|
@ -72,6 +72,7 @@ type QuadWriter interface {
|
|||
// Add a quad to the store.
|
||||
AddQuad(quad.Quad) error
|
||||
|
||||
// TODO(barakmich): Deprecate in favor of transaction.
|
||||
// Add a set of quads to the store, atomically if possible.
|
||||
AddQuadSet([]quad.Quad) error
|
||||
|
||||
|
|
@ -79,6 +80,9 @@ type QuadWriter interface {
|
|||
// if it exists. Does nothing otherwise.
|
||||
RemoveQuad(quad.Quad) error
|
||||
|
||||
// Apply a set of quad changes
|
||||
ApplyTransaction(*Transaction) error
|
||||
|
||||
// Cleans up replication and closes the writing aspect of the database.
|
||||
Close() error
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue