Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store interface {
io.Closer
// Get gets a network configuration
Get(id networkchange.ID) (*networkchange.NetworkChange, error)
// GetByIndex gets a network change by index
GetByIndex(index networkchange.Index) (*networkchange.NetworkChange, error)
// GetPrev gets the previous network change by index
GetPrev(index networkchange.Index) (*networkchange.NetworkChange, error)
// GetNext gets the next network change by index
GetNext(index networkchange.Index) (*networkchange.NetworkChange, error)
// Create creates a new network configuration
Create(config *networkchange.NetworkChange) error
// Update updates an existing network configuration
Update(config *networkchange.NetworkChange) error
// Delete deletes a network configuration
Delete(config *networkchange.NetworkChange) error
// List lists network configurations
List(chan<- *networkchange.NetworkChange) (stream.Context, error)
// Watch watches the network configuration store for changes
Watch(chan<- stream.Event, ...WatchOption) (stream.Context, error)
}
Store stores NetworkConfig changes
func NewAtomixStore ¶
NewAtomixStore returns a new persistent Store
func NewLocalStore ¶
NewLocalStore returns a new local network change store
type WatchOption ¶
type WatchOption interface {
// contains filtered or unexported methods
}
WatchOption is a configuration option for Watch calls
func WithChangeID ¶
func WithChangeID(id networkchange.ID) WatchOption
WithChangeID returns a Watch option that watches for changes to the given change ID
func WithReplay ¶
func WithReplay() WatchOption
WithReplay returns a WatchOption that replays past changes
Click to show internal directories.
Click to hide internal directories.