types

package
v0.0.0-...-25ef478 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2023 License: Apache-2.0, BSD-2-Clause Imports: 3 Imported by: 9

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Void = Empty{}

Functions

This section is empty.

Types

type Empty

type Empty struct{}

type TriBool

type TriBool uint8

TriBool represents a boolean value that can have an additional Maybe state.

const (
	// False represents the equivalent of the boolean false value.
	False TriBool = iota

	// True represents the equivalent of the boolean true value.
	True

	// Maybe represents an indeterminate where we are not entirely sure if the value is True or False.
	Maybe
)

func TriBoolFromBytes

func TriBoolFromBytes(bytes []byte) (triBool TriBool, consumedBytes int, err error)

TriBoolFromBytes unmarshals a TriBool from a sequence of bytes.

func TriBoolFromMarshalUtil

func TriBoolFromMarshalUtil(marshalUtil *marshalutil.MarshalUtil) (triBool TriBool, err error)

TriBoolFromMarshalUtil unmarshals a TriBool using a MarshalUtil (for easier unmarshaling).

func (TriBool) Bytes

func (t TriBool) Bytes() (marshaledTriBool []byte)

Bytes returns a marshaled version of the TriBool.

func (TriBool) String

func (t TriBool) String() (humanReadableTriBool string)

String returns a human readable version of the TriBool.

Jump to

Keyboard shortcuts

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