ioc

package
v0.0.0-...-6b9a538 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package ioc

Package ioc

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Config

func Config(key string) (interface{}, error)

func GetNameAndType

func GetNameAndType(anyThing interface{}) (string, string)

func GetNameAndTypeByRfType

func GetNameAndTypeByRfType(t reflect.Type) (string, string)

func SetConfig

func SetConfig(key string, value interface{})

Types

type IoC

type IoC struct {
	Name string
	// contains filtered or unexported fields
}

func Get

func Get(name string) *IoC

func New

func New(name string) *IoC

func (*IoC) Clear

func (i *IoC) Clear()

ClearIoC

func (*IoC) GetValue

func (i *IoC) GetValue(iocId string) (reflect.Value, error)

GetIoCValue

func (*IoC) Inject

func (i *IoC) Inject(anyThing interface{}) (interface{}, error)

Inject

func (*IoC) Provide

func (i *IoC) Provide(anyThing interface{}) error

Provide

func (*IoC) ProvideByName

func (i *IoC) ProvideByName(provideName string, anyThing interface{}) error

type IoCError

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

func (*IoCError) Error

func (ioCError *IoCError) Error() string

Jump to

Keyboard shortcuts

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