Class Index | File Index

Classes


Class EventDatagramFactory

A class which provides functions for working with events. Use HTTPFabricConnection#getEventDatagramFactory method to get the event datagram factory for the Fabric connection.
Defined in: </home/ubuntu/streamscape/NeeveBuild/stjsapi/src/main/webapp/js/EventDatagramFactory.js>.

Class Summary
Constructor Attributes Constructor Name and Description
 
EventDatagramFactory(fabricConnection)
Creates a factory for creating event datagrams.
Method Summary
Method Attributes Method Name and Description
void 
createAcknowledgement(event, callback)
Calls {@link #createAcknowledgementWithSourceData(event, false, callback)}
void 
createAcknowledgementWithSourceData(event, withSourceData, callback)
Asynchronously creates an instance of an acknowledgement event datagram based on the supplied Source Event Datagram.
void 
createEvent(eventId, callback)
Asynchronously creates an instance of an event datagram based on the supplied event identifier.
Class Detail
EventDatagramFactory(fabricConnection)
Creates a factory for creating event datagrams.
Parameters:
{HTTPFabricConnection} fabricConnection
The connection for which this factory is created.
Method Detail
createAcknowledgement(event, callback)
Calls {@link #createAcknowledgementWithSourceData(event, false, callback)}
Parameters:
{AbstractDataEvent} event
The event to be acknowledged
{Function} callback
The callback function called with the created event object. (See HTTPFabricConnection for a callback description).
Callback object type: Event.AcknowledgementEvent.

createAcknowledgementWithSourceData(event, withSourceData, callback)
Asynchronously creates an instance of an acknowledgement event datagram based on the supplied Source Event Datagram. It is expected that Event Identity Management elements from the header are copied into the acknowledgement to allow correlation between an event and it's acknowledgement. The created Event.AcknowledgementEvent object is passed to the specified callback function when it is returned from server side.
Parameters:
{Event.AbstractDataEvent} event
The event to be acknowledged
{boolean} withSourceData
The flag indicating if the event data will be set to the acknowledgement event
{Function} callback
The callback function called with the created event object. (See HTTPFabricConnection for a callback description).
Callback object type: Event.AcknowledgementEvent.

createEvent(eventId, callback)
Asynchronously creates an instance of an event datagram based on the supplied event identifier. The created Event.AbstractDataEvent object is passed to the specified callback function when it is returned from server side.
Parameters:
{String} eventId
The identifier of the event to be created
{Function} callback
The callback function called with the created event object. (See HTTPFabricConnection for a callback description).
Callback object type: Event.AbstractDataEvent.

Copyright © 2015-2021 StreamScape Technologies. All rights reserved.