errutil

package
v0.0.1-test Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2022 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Group

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

func GroupWithContext

func GroupWithContext(ctx context.Context) (*Group, context.Context)

func (*Group) Cancel

func (g *Group) Cancel()

Cancel cancels the associated context.

func (*Group) Go

func (g *Group) Go(f func() error)

Go wraps the provided function and executes it in a goroutine.

func (*Group) Wait

func (g *Group) Wait() error

Wait waits for any wrapped goroutines to finish and returns any error having occurred in one of them.

func (*Group) Wrap

func (g *Group) Wrap(f func() error) func()

Wrap wraps a function to be executed in a goroutine.

Jump to

Keyboard shortcuts

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