Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LevelDBProcessDB ¶ added in v0.14.0
type LevelDBProcessDB struct {
// contains filtered or unexported fields
}
LevelDBProcessDB is a database for storing processes definition.
func NewProcessDB ¶ added in v0.14.0
func NewProcessDB(path string) (*LevelDBProcessDB, error)
NewProcessDB returns the database which is located under given path.
func (*LevelDBProcessDB) All ¶ added in v0.14.0
func (d *LevelDBProcessDB) All() ([]*process.Process, error)
All returns every process in database.
func (*LevelDBProcessDB) Close ¶ added in v0.14.0
func (d *LevelDBProcessDB) Close() error
Close closes database.
func (*LevelDBProcessDB) Delete ¶ added in v0.14.0
func (d *LevelDBProcessDB) Delete(hash hash.Hash) error
Delete deletes process from database.
type ProcessDB ¶ added in v0.14.0
type ProcessDB interface { // Save saves a process to database. Save(s *process.Process) error // Get gets a process from database by its unique hash. Get(hash hash.Hash) (*process.Process, error) // Delete deletes a process from database by its unique hash. Delete(hash hash.Hash) error // All returns all processes from database. All() ([]*process.Process, error) // Close closes underlying database connection. Close() error }
ProcessDB describes the API of database package.
Click to show internal directories.
Click to hide internal directories.