examples

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TestVariadicOptionsWithGenerics

func TestVariadicOptionsWithGenerics(t *testing.T)

Types

type Bar

type Bar struct{}

func NewBar

func NewBar(_ *Foo) *Bar

func (*Bar) Bar

func (b *Bar) Bar()

type BarI

type BarI interface {
	Bar()
}

type Foo

type Foo struct{}

func NewFoo

func NewFoo() *Foo

type FooBar

type FooBar struct{}

func NewFooBar

func NewFooBar(_ *Foo, _ *Bar) *FooBar

func NewFooBarWithBarI

func NewFooBarWithBarI(_ *Foo, _ BarI) *FooBar

func (*FooBar) Print

func (f *FooBar) Print()

type FooBarGenerics

type FooBarGenerics[FooT any] struct {
	// contains filtered or unexported fields
}

func NewFooBarGenerics

func NewFooBarGenerics[FooT any]() *FooBarGenerics[FooT]

func NewFooBarGenericsWithOptions

func NewFooBarGenericsWithOptions[FooT any](
	opts ...FooBarGenericsOption[FooT],
) (*FooBarGenerics[FooT], error)

func (*FooBarGenerics[FooT]) Print

func (fb *FooBarGenerics[FooT]) Print()

type FooBarGenericsOption

type FooBarGenericsOption[FooT any] func(*FooBarGenerics[FooT])

func WithFoo

func WithFoo[FooT any](foo FooT) FooBarGenericsOption[FooT]

type FooBarI

type FooBarI interface {
	Print()
}

Jump to

Keyboard shortcuts

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