Documentation ¶
Index ¶
- type DB
- func (db *DB) Delete(ctx context.Context, segID common.RawBytes) (int, error)
- func (db *DB) DeleteWithIntf(ctx context.Context, intf query.IntfSpec) (int, error)
- func (db *DB) Get(ctx context.Context, params *query.Params) ([]*query.Result, error)
- func (db *DB) Insert(ctx context.Context, pseg *seg.PathSegment, segTypes []proto.PathSegType) (int, error)
- func (db *DB) InsertWithHPCfgIDs(ctx context.Context, pseg *seg.PathSegment, segTypes []proto.PathSegType, ...) (int, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
func (*DB) Delete ¶
Delete deletes a path segment with a given ID. Returns the number of deleted path segments (0 or 1).
func (*DB) DeleteWithIntf ¶
DeleteWithIntf deletes all path segments that contain a given interface. Returns the number of path segments deleted.
func (*DB) Insert ¶
func (db *DB) Insert(ctx context.Context, pseg *seg.PathSegment, segTypes []proto.PathSegType) (int, error)
Insert inserts or updates a path segment. It returns the number of path segments that have been inserted/updated.
func (*DB) InsertWithHPCfgIDs ¶
func (db *DB) InsertWithHPCfgIDs(ctx context.Context, pseg *seg.PathSegment, segTypes []proto.PathSegType, hpCfgIDs []*query.HPCfgID) (int, error)
InsertWithHPCfgIDs inserts or updates a path segment with a set of HPCfgIDs. It returns the number of path segments that have been inserted/updated.
Click to show internal directories.
Click to hide internal directories.