ngetter

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2019 License: MIT Imports: 3 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Booler

type Booler interface {
	Bool() bool
}

Booler is an interface to get a bool value

type Floater64

type Floater64 interface {
	Float64() float64
}

Floater64 is an interface to get a Float64 value

type Getter

type Getter interface {
	Get() interface{}
}

Getter is a generic interface to get a value

type GetterTyped

type GetterTyped interface {
	Getter
	Inter
	Inter64
	Floater64
	Booler
	Stringer
}

GetterTyped is a getter with methods to cast

type GetterTypedFunc

type GetterTypedFunc func() interface{}

GetterTypedFunc is a function implementing the GetterTyped interface

func (GetterTypedFunc) Bool

func (f GetterTypedFunc) Bool() bool

Bool returns the bool value

func (GetterTypedFunc) Float64

func (f GetterTypedFunc) Float64() float64

Float64 returns the float64 value

func (GetterTypedFunc) Get

func (f GetterTypedFunc) Get() interface{}

Get returns the interface{} value

func (GetterTypedFunc) Int

func (f GetterTypedFunc) Int() int

Int returns the int value

func (GetterTypedFunc) Int64

func (f GetterTypedFunc) Int64() int64

Int64 returns the int64 value

func (GetterTypedFunc) String

func (f GetterTypedFunc) String() string

String returns the string value

type Inter

type Inter interface {
	Int() int
}

Inter is an interface to get an int value

type Inter64

type Inter64 interface {
	Int64() int64
}

Inter64 is an interface to get an int64 value

type Provider added in v0.0.4

type Provider interface {
	Getter
	Replace(interface{})
}

Provider is an interface to provide a value in a thread safe manner And be able to replace this value in a thread safe manner.

func NewProvider added in v0.0.4

func NewProvider(x interface{}) Provider

NewProvider returns a new Provider from the given value x

type Stringer

type Stringer fmt.Stringer

Stringer is an alias to fmt.Stringer

Jump to

Keyboard shortcuts

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