reflection

package
v0.5.6 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package reflection implements helpers for reflection code.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComponentName

func ComponentName[T any]() string

ComponentName returns the name of the component of type T. Note that T must be the interface type of the component, not its implementation type.

func Type

func Type[T any]() reflect.Type

Type returns the reflect.Type for T.

This function is particularly useful when T is an interface and it is impossible to get a value with concrete type T.

Types

This section is empty.

Jump to

Keyboard shortcuts

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