Documentation ¶
Index ¶
- func BuildResource(nodeID, namespace, resourceType, resourceID string) (resource string, err error)
- func BuildResourceForRouter(resourceType, resourceID string) (string, error)
- func GetNamespace(msg model.Message) (string, error)
- func GetNodeID(msg model.Message) (string, error)
- func GetResourceName(msg model.Message) (string, error)
- func GetResourceType(msg model.Message) (string, error)
- type ContextMessageLayer
- type MessageLayer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildResource ¶
BuildResource return a string as "beehive/pkg/core/model".Message.Router.Resource
func BuildResourceForRouter ¶
BuildResourceForRouter return a string as "beehive/pkg/core/model".Message.Router.Resource
func GetNamespace ¶
GetNamespace from "beehive/pkg/core/model".Model.Router.Resource
func GetResourceName ¶
GetResourceName from "beehive/pkg/core/model".Model.Router.Resource
Types ¶
type ContextMessageLayer ¶
type ContextMessageLayer struct { SendModuleName string SendRouterModuleName string ReceiveModuleName string ResponseModuleName string }
ContextMessageLayer build on context
func (*ContextMessageLayer) Receive ¶
func (cml *ContextMessageLayer) Receive() (model.Message, error)
Receive message
type MessageLayer ¶
type MessageLayer interface { Send(message model.Message) error Receive() (model.Message, error) Response(message model.Message) error }
MessageLayer define all functions that message layer must implement
func NewContextMessageLayer ¶
func NewContextMessageLayer() MessageLayer
NewContextMessageLayer create a ContextMessageLayer
Click to show internal directories.
Click to hide internal directories.