Documentation ¶
Overview ¶
A Memory Mapped List. This list works more like a stack and less like a queue. It is not a good thing to build a job queue on. It is a good thing to build a large set of items which can be efficiently randomly sampled. It uses the same `varchar` system that the B+Tree uses so it can store variably sized items up to 2^31 - 1 bytes long.
Operations ¶
1. `Size` O(1)
2. `Append` O(1)
3. `Pop` O(1)
4. `Get` O(1)
5. `Set` O(1)
6. `Swap` O(1)
7. `SwapDelete` O(1)
Index ¶
- type List
- func (l *List) Append(item []byte) (i uint64, err error)
- func (l *List) Get(i uint64) (item []byte, err error)
- func (l *List) Pop() (item []byte, err error)
- func (l *List) Set(i uint64, item []byte) (err error)
- func (l *List) Size() uint64
- func (l *List) Swap(i, j uint64) (err error)
- func (l *List) SwapDelete(i uint64) (item []byte, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
Click to show internal directories.
Click to hide internal directories.