Documentation ¶
Overview ¶
Package cmdq provides command queue implementations
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CommandQueue ¶
type CommandQueue interface { GetCommandToIssue() *signal.Command CanAccept(command *signal.Command) bool Accept(command *signal.Command) }
A CommandQueue is a queue of command that needs to be executed by a rank or a bank.
type CommandQueueImpl ¶
type CommandQueueImpl struct { Queues []Queue CapacityPerQueue int Channel org.Channel // contains filtered or unexported fields }
CommandQueueImpl implements a command queue.
func (*CommandQueueImpl) Accept ¶
func (q *CommandQueueImpl) Accept(cmd *signal.Command)
Accept adds a new command in the command queue.
func (*CommandQueueImpl) CanAccept ¶
func (q *CommandQueueImpl) CanAccept(cmd *signal.Command) bool
CanAccept returns true is there is empty space in the command queue.
func (*CommandQueueImpl) GetCommandToIssue ¶
func (q *CommandQueueImpl) GetCommandToIssue() *signal.Command
GetCommandToIssue returns the next command ready to issue. It returns nil if there if no command ready.
Click to show internal directories.
Click to hide internal directories.