intarr

package module
v0.0.0-...-e0d9580 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 26, 2017 License: MIT Imports: 7 Imported by: 2 modules, 2 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BytesToUint64

func BytesToUint64(bts []byte) uint64

func Diff

func Diff(oldIds, currentIds []int) (joined, leaved []int)

Diff return removed and new items

func InArray

func InArray(value int64, array []int64) bool

func Pack

func Pack(in []uint64) (r []byte, e error)

func PackGzip

func PackGzip(s Slice) ([]byte, error)

func PackSnappy

func PackSnappy(s Slice) ([]byte, error)

func Sort

func Sort(s Slice)

func Uint64ToBytes

func Uint64ToBytes(i uint64) []byte

func Unpack

func Unpack(data []byte) (arr []uint64, e error)

Types

type Slice

type Slice []uint64

func Decode

func Decode(b []byte) (Slice, error)

func New

func New(arr interface{}) (s Slice)

func UnpackGzip

func UnpackGzip(data []byte) (Slice, error)

func (Slice) AsInt

func (sl Slice) AsInt() (res []int)

func (Slice) Encode

func (sl Slice) Encode() ([]byte, error)

func (Slice) In

func (sl Slice) In(i uint64) bool

func (Slice) Int64

func (sl Slice) Int64() (res []int64)

func (Slice) Remove

func (sl Slice) Remove(num uint64) (res Slice)

func (Slice) Sort

func (s Slice) Sort()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址