Help us shape the future of Go! Take the 2026 Go Developer Survey

singlewait

package
v0.9.4 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2023 License: MIT Imports: 0 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SingleWait

type SingleWait[T any] struct {
	// contains filtered or unexported fields
}

func New

func New[T any](fn func() T) *SingleWait[T]

New creates a new instance of SingleWait struct and initiates the Done channel.

func (*SingleWait[T]) GetData

func (s *SingleWait[T]) GetData() T

func (*SingleWait[T]) Process

func (s *SingleWait[T]) Process(fn func() T)

Process simulates a long running process and closes the Done channel when finished.

Jump to

Keyboard shortcuts

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