atomic

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2015 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 1 more Imports: 2 Imported by: 0

Documentation

Overview

Package atomic implements higher level constructs on top of the stdlib atomic package

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IncreasingInt64

type IncreasingInt64 struct {
	// contains filtered or unexported fields
}

IncreasingInt64 is an int64 that can only strictly increase, and does so safely

func NewIncreasingInt64

func NewIncreasingInt64(initial int64) *IncreasingInt64

func (*IncreasingInt64) Get

func (ai64 *IncreasingInt64) Get() int64

func (*IncreasingInt64) MarshalJSON

func (ai64 *IncreasingInt64) MarshalJSON() ([]byte, error)

func (*IncreasingInt64) Set

func (ai64 *IncreasingInt64) Set(val int64)

func (*IncreasingInt64) UnmarshalJSON

func (ai64 *IncreasingInt64) UnmarshalJSON(data []byte) error

Jump to

Keyboard shortcuts

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