FCF 2.0 development in progress...
> > > >
[News] [Packages API] [Downloads] [Donate to the project] [Contacts]

fcf.getEventChannel() function

fcf.EventChannel fcf.getEventChannel()

Package: fcf-framework-core

File: fcf-framework-core:fcf.js

Available from version: 2.0.2

Returns the message channel used by the default framework.

Result
fcf.EventChannel
- The default message channel used by the framework

Example: Function application

fcf.getEventChannel().on("test_event", (a_eventData, a_eventHeader)=>{ console.log("Event data: ", a_eventData); console.log("Event header:", a_eventHeader); }); fcf.getEventChannel().send("test_event", {field1: "value1"});

Output:

Event data: { field1: 'value1' } Event header: { name: 'test_event' }