tag

package
v0.0.0-...-5012a73 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2019 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DChTag

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

DChTag is a demand channel

func MakeDemandTagBuff

func MakeDemandTagBuff(cap int) *DChTag

MakeDemandTagBuff returns a (pointer to a) fresh buffered (with capacity cap) demand channel

func MakeDemandTagChan

func MakeDemandTagChan() *DChTag

MakeDemandTagChan returns a (pointer to a) fresh unbuffered demand channel

func (*DChTag) ProvideTag

func (c *DChTag) ProvideTag(dat *tag.TagAny)

ProvideTag is the send function - aka "MyKind <- some Tag"

func (*DChTag) RequestTag

func (c *DChTag) RequestTag() (dat *tag.TagAny)

RequestTag is the receive function - aka "some Tag <- MyKind"

func (*DChTag) TryTag

func (c *DChTag) TryTag() (dat *tag.TagAny, open bool)

TryTag is the comma-ok multi-valued form of RequestTag and reports whether a received value was sent before the Tag channel was closed.

type SChTag

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

SChTag is a supply channel

func MakeSupplyTagBuff

func MakeSupplyTagBuff(cap int) *SChTag

MakeSupplyTagBuff returns a (pointer to a) fresh buffered (with capacity cap) supply channel

func MakeSupplyTagChan

func MakeSupplyTagChan() *SChTag

MakeSupplyTagChan returns a (pointer to a) fresh unbuffered supply channel

func (*SChTag) ProvideTag

func (c *SChTag) ProvideTag(dat *tag.TagAny)

ProvideTag is the send function - aka "MyKind <- some Tag"

func (*SChTag) RequestTag

func (c *SChTag) RequestTag() (dat *tag.TagAny)

RequestTag is the receive function - aka "some Tag <- MyKind"

func (*SChTag) TryTag

func (c *SChTag) TryTag() (dat *tag.TagAny, open bool)

TryTag is the comma-ok multi-valued form of RequestTag and reports whether a received value was sent before the Tag channel was closed.

type TagChan

type TagChan interface {
	TagROnlyChan // aka "<-chan" - receive only
	TagSOnlyChan // aka "chan<-" - send only
}

TagChan represents a bidirectional channel

type TagROnlyChan

type TagROnlyChan interface {
	RequestTag() (dat *tag.TagAny)        // the receive function - aka "MyTag := <-MyTagROnlyChan"
	TryTag() (dat *tag.TagAny, open bool) // the multi-valued comma-ok receive function - aka "MyTag, ok := <-MyTagROnlyChan"
}

TagROnlyChan represents a receive-only channel

type TagSOnlyChan

type TagSOnlyChan interface {
	ProvideTag(dat *tag.TagAny) // the send function - aka "MyKind <- some Tag"
}

TagSOnlyChan represents a send-only channel

Jump to

Keyboard shortcuts

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