Documentation ¶
Index ¶
- type Application
- func (a *Application) All() []interfaces.IComponent
- func (a *Application) Find(name string) interfaces.IComponent
- func (a *Application) Handlers() *handler.Component
- func (a *Application) LoadConnector(_ interfaces.IComponent)
- func (a *Application) NodeId() string
- func (*Application) NodeRoute(nodeType string, routeFunc interfaces.RouteFunction)
- func (a *Application) NodeType() string
- func (a *Application) OnShutdown(shutdownFunc ...func())
- func (a *Application) PostEvent(e interfaces.IEvent)
- func (a *Application) Register(components ...interfaces.IComponent)
- func (a *Application) Remove(name string) interfaces.IComponent
- func (*Application) RpcFilter() interfaces.RpcFilter
- func (a *Application) Startup(startupFunc ...func())
- func (a *Application) ThisNode() interfaces.INode
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Application ¶
type Application struct {
// contains filtered or unexported fields
}
Application
func CreateApp ¶
func CreateApp(configPath, profile, nodeId string) *Application
func New ¶
func New(configPath, profileName, nodeId string) *Application
New create new application instance
func (*Application) All ¶
func (a *Application) All() []interfaces.IComponent
func (*Application) Find ¶
func (a *Application) Find(name string) interfaces.IComponent
func (*Application) Handlers ¶
func (a *Application) Handlers() *handler.Component
func (*Application) LoadConnector ¶
func (a *Application) LoadConnector(_ interfaces.IComponent)
func (*Application) NodeId ¶
func (a *Application) NodeId() string
func (*Application) NodeRoute ¶
func (*Application) NodeRoute(nodeType string, routeFunc interfaces.RouteFunction)
NodeRoute 结点路由规则 nodeType:结点类型,routeFunc 路由规则
func (*Application) NodeType ¶
func (a *Application) NodeType() string
func (*Application) OnShutdown ¶
func (a *Application) OnShutdown(shutdownFunc ...func())
func (*Application) Register ¶
func (a *Application) Register(components ...interfaces.IComponent)
func (*Application) Remove ¶
func (a *Application) Remove(name string) interfaces.IComponent
Remove remove component by name
func (*Application) RpcFilter ¶
func (*Application) RpcFilter() interfaces.RpcFilter
RpcFilter rpc全局过滤器
func (*Application) ThisNode ¶
func (a *Application) ThisNode() interfaces.INode
Click to show internal directories.
Click to hide internal directories.