Documentation ¶
Index ¶
- Constants
- Variables
- type Queue
- func (q Queue[T]) Dequeue(ctx context.Context) (elem T, err error)
- func (q Queue[T]) Enqueue(ctx context.Context, elem T) error
- func (q Queue[T]) Front(ctx context.Context) (uint64, error)
- func (q Queue[T]) Get(ctx context.Context, index uint64) (elem T, err error)
- func (q Queue[T]) Initialize(ctx context.Context) error
- func (q Queue[T]) IsEmpty(ctx context.Context) bool
- func (q Queue[T]) Iterate(ctx context.Context) (collections.Iterator[uint64, T], error)
- func (q Queue[T]) Len(ctx context.Context) uint64
- func (q Queue[T]) Peek(ctx context.Context) (elem T, err error)
- func (q Queue[T]) Rear(ctx context.Context) (uint64, error)
Constants ¶
View Source
const ( QueueElementsNameSuffix = "_elements" QueueFrontNameSuffix = "_front" QueueRearNameSuffix = "_rear" QueueElementsPrefixSuffix = 0x0 QueueFrontPrefixSuffix = 0x1 QueueRearPrefixSuffix = 0x2 )
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Queue ¶
type Queue[T any] struct { // contains filtered or unexported fields }
func NewQueue ¶
func NewQueue[T any](sb *collections.SchemaBuilder, prefix collections.Prefix, name string, vc codec.ValueCodec[T]) Queue[T]
Click to show internal directories.
Click to hide internal directories.