atomic

package
v1.0.8 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Cas

func Cas(p *unsafe.Pointer, old, new *boot.Node) bool

func Get

func Get(p *unsafe.Pointer) (n *boot.Node)

func Set

func Set(p *unsafe.Pointer, node *boot.Node)

func SetValue

func SetValue(p *unsafe.Pointer, value interface{})

Types

type Acquire

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

func (*Acquire) Acquire

func (a *Acquire) Acquire() (acquired bool)

func (*Acquire) IsRelease

func (a *Acquire) IsRelease() (release bool)

func (*Acquire) Release

func (a *Acquire) Release()

type Bool

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

func (*Bool) Get

func (b *Bool) Get() (val bool)

func (*Bool) Set

func (b *Bool) Set(value bool)

type Int32

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

func (*Int32) Cas

func (i32 *Int32) Cas(old, new int32) bool

func (*Int32) Get

func (i32 *Int32) Get() (value int32)

func (*Int32) Incr

func (i32 *Int32) Incr(value int32) (newValue int32)

func (*Int32) Set

func (i32 *Int32) Set(value int32)

type Int64

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

func (*Int64) Cas

func (i64 *Int64) Cas(old, new int64) bool

func (*Int64) Get

func (i64 *Int64) Get() (value int64)

func (*Int64) Incr

func (i64 *Int64) Incr(value int64) (newValue int64)

func (*Int64) Set

func (i64 *Int64) Set(value int64)

type Uint32

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

func (*Uint32) Cas

func (u32 *Uint32) Cas(old, new uint32) bool

func (*Uint32) Get

func (u32 *Uint32) Get() (value uint32)

func (*Uint32) Incr

func (u32 *Uint32) Incr(value uint32) (newValue uint32)

func (*Uint32) Set

func (u32 *Uint32) Set(value uint32)

type Uint64

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

func (*Uint64) Cas

func (u64 *Uint64) Cas(old, new uint64) bool

func (*Uint64) Get

func (u64 *Uint64) Get() (value uint64)

func (*Uint64) Incr

func (u64 *Uint64) Incr(value uint64) (newValue uint64)

func (*Uint64) Set

func (u64 *Uint64) Set(value uint64)

Jump to

Keyboard shortcuts

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