Documentation
¶
Index ¶
- type Package
- type Packages
- type SqliteStore
- func (s *SqliteStore) Close() error
- func (s *SqliteStore) DoneToDo(name string, Continue bool) error
- func (s *SqliteStore) GetForward(lhs string) (Packages, error)
- func (s *SqliteStore) GetReverse(rhs string) (Packages, error)
- func (s *SqliteStore) GetToDo() (Packages, int, int, error)
- func (s *SqliteStore) Open(location string) error
- func (s *SqliteStore) ResetToDo() error
- func (s *SqliteStore) StartToDo(name string) error
- func (s *SqliteStore) Update(i *index.Index) error
- func (s *SqliteStore) WorstToDo(name string) (Packages, error)
- type Store
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Packages ¶
type Packages []Package
Packages is a sortable type for a list of Package struct
type SqliteStore ¶
type SqliteStore struct {
// contains filtered or unexported fields
}
SqliteStore is a backing store built on sqlite
func (*SqliteStore) Close ¶
func (s *SqliteStore) Close() error
Close deinitializes the connection to the backend store
func (*SqliteStore) DoneToDo ¶
func (s *SqliteStore) DoneToDo(name string, Continue bool) error
DoneToDo marks a package as complete and optionally queues its reverse deps
func (*SqliteStore) GetForward ¶
func (s *SqliteStore) GetForward(lhs string) (Packages, error)
GetForward returns: (lhs) -> *
func (*SqliteStore) GetReverse ¶
func (s *SqliteStore) GetReverse(rhs string) (Packages, error)
GetReverse returns: * -> (rhs)
func (*SqliteStore) GetToDo ¶
func (s *SqliteStore) GetToDo() (Packages, int, int, error)
GetToDo gets the currently unblocked packages to rebuild
func (*SqliteStore) Open ¶
func (s *SqliteStore) Open(location string) error
Open initializes a connection to the backend store
func (*SqliteStore) ResetToDo ¶
func (s *SqliteStore) ResetToDo() error
ResetToDo clears the todo list
func (*SqliteStore) StartToDo ¶
func (s *SqliteStore) StartToDo(name string) error
StartToDo adds a new package to the todo list
type Store ¶
type Store interface {
// Open initializes a connection to the backend store
Open(location string) error
// GetForward returns: (left) -> *
GetForward(lhs string) (Packages, error)
// GetReverse returns: * -> (right)
GetReverse(rhs string) (Packages, error)
// GetToDo returns a list of unblocked packages that need to be rebuilt,
// the count of remaining rebuilds, and the count of completed rebuilds
GetToDo() (Packages, int, int, error)
// StartToDo adds a new package to the todo list
StartToDo(name string) error
// DoneToDo marks a package as complete and optionally queues its reverse deps
DoneToDo(name string, Continue bool) error
// ResetToDo clears the todo list
ResetToDo() error
// WorstToDo gets a worst-case list of packages to rebuild
WorstToDo(name string) (Packages, error)
// Update clears the current store and rebuilds the contents from the provided index
Update(i *index.Index) error
// Close deinitializes the connection to the backend store
Close() error
}
Store is a common interface for all kinds of backing store
Click to show internal directories.
Click to hide internal directories.