concurrent

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlockingQueue

type BlockingQueue struct {
	Queue
	// contains filtered or unexported fields
}

func (*BlockingQueue) Pop

func (q *BlockingQueue) Pop() interface{}

func (*BlockingQueue) Push

func (q *BlockingQueue) Push(obj interface{})

func (*BlockingQueue) Reset

func (q *BlockingQueue) Reset() *BlockingQueue

type BurstWaitGroup

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

func (*BurstWaitGroup) Add

func (w *BurstWaitGroup) Add(delta int)

func (*BurstWaitGroup) Burst

func (w *BurstWaitGroup) Burst()

func (*BurstWaitGroup) Done

func (w *BurstWaitGroup) Done()

func (*BurstWaitGroup) Remain

func (w *BurstWaitGroup) Remain() int

func (*BurstWaitGroup) Wait

func (w *BurstWaitGroup) Wait()

type CarrierFuture

type CarrierFuture interface {
	Payload() interface{}
}

type CompletableFuture

type CompletableFuture interface {
	Complete(obj interface{})
	Cancel()
	Fail(err error)
	// contains filtered or unexported methods
}

type DefaultFuture

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

func (*DefaultFuture) AddListener

func (f *DefaultFuture) AddListener(listener FutureListener) Future

func (*DefaultFuture) Await

func (f *DefaultFuture) Await() Future

func (*DefaultFuture) Cancel

func (f *DefaultFuture) Cancel()

func (*DefaultFuture) Complete

func (f *DefaultFuture) Complete(obj interface{})

func (*DefaultFuture) Ctx

func (f *DefaultFuture) Ctx() context.Context

func (*DefaultFuture) Error

func (f *DefaultFuture) Error() error

func (*DefaultFuture) Fail

func (f *DefaultFuture) Fail(err error)

func (*DefaultFuture) Get

func (f *DefaultFuture) Get() interface{}

func (*DefaultFuture) IsCancelled

func (f *DefaultFuture) IsCancelled() bool

func (*DefaultFuture) IsDone

func (f *DefaultFuture) IsDone() bool

func (*DefaultFuture) IsError

func (f *DefaultFuture) IsError() bool

func (*DefaultFuture) IsSuccess

func (f *DefaultFuture) IsSuccess() bool

func (*DefaultFuture) Payload

func (f *DefaultFuture) Payload() interface{}

type Future

type Future interface {
	Get() interface{}
	Await() Future
	IsDone() bool
	IsSuccess() bool
	IsCancelled() bool
	IsError() bool
	Error() error
	Ctx() context.Context
	AddListener(listener FutureListener) Future
}

func NewCancelledFuture

func NewCancelledFuture() Future

func NewCarrierFuture

func NewCarrierFuture(obj interface{}) Future

func NewFailedFuture

func NewFailedFuture(err error) Future

func NewFuture

func NewFuture(ctx context.Context) Future

func NewSucceededFuture

func NewSucceededFuture(obj interface{}) Future

type FutureListener

type FutureListener interface {
	Future
	OperationCompleted(f Future)
}

func NewFutureListener

func NewFutureListener(f func(f Future)) FutureListener

type Queue

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

func (*Queue) Len

func (q *Queue) Len() int

func (*Queue) Pop

func (q *Queue) Pop() interface{}

func (*Queue) Push

func (q *Queue) Push(obj interface{})

func (*Queue) Reset

func (q *Queue) Reset() *Queue

Jump to

Keyboard shortcuts

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