numeric_util

package
v0.0.0-...-84ec206 Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2015 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const ShiftStartInt64 byte = 0x20

Variables

This section is empty.

Functions

func Float64ToInt64

func Float64ToInt64(f float64) int64

func Int64ToFloat64

func Int64ToFloat64(i int64) float64

Types

type PrefixCoded

type PrefixCoded []byte

PrefixCoded is a byte array encoding of 64-bit numeric values shifted by 0-63 bits

func MustNewPrefixCodedInt64

func MustNewPrefixCodedInt64(in int64, shift uint) PrefixCoded

func NewPrefixCodedInt64

func NewPrefixCodedInt64(in int64, shift uint) (PrefixCoded, error)

func (PrefixCoded) Int64

func (p PrefixCoded) Int64() (int64, error)

func (PrefixCoded) Shift

func (p PrefixCoded) Shift() (uint, error)

Shift returns the number of bits shifted returns 0 if in uninitialized state

Jump to

Keyboard shortcuts

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