MCPcopy Create free account
hub / github.com/brimdata/super / DeleteObject

Method DeleteObject

db/commits/patch.go:73–84  ·  view source on GitHub ↗
(id ksuid.KSUID)

Source from the content-addressed store, hash-verified

71}
72
73func (p *Patch) DeleteObject(id ksuid.KSUID) error {
74 if p.diff.Exists(id) {
75 return p.diff.DeleteObject(id)
76 }
77 if !Exists(p.base, id) {
78 return ErrNotFound
79 }
80 // Keep track of the deletions from the base so we can add the
81 // needed delete Actions when building the transaction patch.
82 p.deletedObjects = append(p.deletedObjects, id)
83 return nil
84}
85
86func (p *Patch) AddVector(id ksuid.KSUID) error {
87 if p.HasVector(id) {

Callers 3

DeleteWhereMethod · 0.95
CommitCompactMethod · 0.95
DiffFunction · 0.95

Calls 3

ExistsFunction · 0.70
ExistsMethod · 0.65
DeleteObjectMethod · 0.65

Tested by

no test coverage detected