Documentation ¶
Index ¶
- func Back(list string) (data interface{}, seq int, err error)
- func Drop(list string) (err error)
- func Front(list string) (data interface{}, seq int, err error)
- func Get(list string, n int) (data interface{}, err error)
- func GetByID(list string, _id string) (data interface{}, n int, err error)
- func Init(file string)
- func Len(list string) (l uint64)
- func Next(list string, _n int) (data interface{}, n int, err error)
- func Prev(list string, _n int) (data interface{}, n int, err error)
- func PushBack(list string, data interface{}) (n int, err error)
- func PushFront(list string, data interface{}) (n int, err error)
- func Remove(list string, n int) (err error)
- func RemoveByID(list string, _id string) (err error)
- func UpdateByID(list string, data interface{}) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Front ¶
Front moves cursor to the front of the list, returns first element and it's sequence number Returns error if list is empty
func Get ¶ added in v0.0.20
Get returns element by provided sequence number Returns error if list is empty or element was not found
func GetByID ¶ added in v0.0.20
GetByID returns element by provided _id property of the stored map Returns error if list is empty or element was not found
func PushBack ¶
PushBack adds element to the back of the list and returns it's sequence number Returns error if it can't add element
func PushFront ¶
PushFront adds element to the front of the list and returns it's sequence number Returns error if it can't add element
func Remove ¶
Remove removes element by provided sequence number Returns error if queue is not exists or it can't write changes
func RemoveByID ¶
RemoveByID removes element by provided _id property of the stored map Returns error if queue is not exists or it can't write changes
func UpdateByID ¶ added in v0.0.21
UpdateByID updates element by provided _id property of the passed element Returns error if queue is not exists or if item was not found it can't write changes
Types ¶
This section is empty.