Documentation ¶
Index ¶
- type LoggerInterface
- type ServiceLocator
- func (sl *ServiceLocator) AddConfigPath(path string)
- func (sl *ServiceLocator) Get(name string) (service interface{}, err error)
- func (sl *ServiceLocator) SetConfig(serviceName string, constructorName string, arguments []interface{})
- func (sl *ServiceLocator) SetConfigType(configType string)
- func (sl *ServiceLocator) SetConstructor(name string, constructor interface{}) (err error)
- func (sl *ServiceLocator) SetLogger(logger LoggerInterface)
- func (sl *ServiceLocator) SetPanicMode(mode bool)
- func (sl *ServiceLocator) SetService(name string, service interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LoggerInterface ¶
type LoggerInterface interface { Debug(args ...interface{}) Error(args ...interface{}) Fatal(args ...interface{}) Warn(args ...interface{}) }
type ServiceLocator ¶
type ServiceLocator struct {
// contains filtered or unexported fields
}
func New ¶
func New(fileName string) *ServiceLocator
func (*ServiceLocator) AddConfigPath ¶
func (sl *ServiceLocator) AddConfigPath(path string)
func (*ServiceLocator) Get ¶
func (sl *ServiceLocator) Get(name string) (service interface{}, err error)
func (*ServiceLocator) SetConfig ¶
func (sl *ServiceLocator) SetConfig(serviceName string, constructorName string, arguments []interface{})
func (*ServiceLocator) SetConfigType ¶
func (sl *ServiceLocator) SetConfigType(configType string)
func (*ServiceLocator) SetConstructor ¶
func (sl *ServiceLocator) SetConstructor(name string, constructor interface{}) (err error)
func (*ServiceLocator) SetLogger ¶
func (sl *ServiceLocator) SetLogger(logger LoggerInterface)
func (*ServiceLocator) SetPanicMode ¶
func (sl *ServiceLocator) SetPanicMode(mode bool)
func (*ServiceLocator) SetService ¶
func (sl *ServiceLocator) SetService(name string, service interface{})
Click to show internal directories.
Click to hide internal directories.