Apama  9.10.0.4.289795
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Friends | List of all members
com::apama::event::Event Class Referenceabstract

An Event object represents an event instance. More...

#include <engine_client_cpp.hpp>

Public Member Functions

virtual const char * getText () const =0
 Retrieve the event's type and its contents as a string. More...
 
virtual const char * getChannel () const =0
 Retrieve the event's channel. More...
 
virtual double getTime () const =0
 Retrieve the event's timestamp. More...
 

Friends

AP_ENGINE_CLIENT_API EventcreateEvent (const char *eventString, const char *channelString)
 This function allows creation of an Event object. More...
 
AP_ENGINE_CLIENT_API void deleteEvent (Event *ev)
 This function allows deletion of an Event object. More...
 
std::ostream & operator<< (std::ostream &stream, const Event &obj)
 Output to an ostream from a reference. More...
 
std::ostream & operator<< (std::ostream &stream, const Event *obj)
 Output to an ostream from a pointer. More...
 

Detailed Description

An Event object represents an event instance.

Must be created using com::apama::event::createEvent Must be destroyed using com::apama::event::deleteEvent

Event is not copiable

Member Function Documentation

virtual const char* com::apama::event::Event::getChannel ( ) const
pure virtual

Retrieve the event's channel.

This currently only has meaning for events which have been sourced from the correlator, in which case it is set to the name of the channel the event was emitted from, or "" (the empty string) for the wildcard channel.

Returns
The channel of the event, encoded in UTF-8.
virtual const char* com::apama::event::Event::getText ( ) const
pure virtual

Retrieve the event's type and its contents as a string.

Returns
C style string with the event's textual representation. Note that these strings should be encoded in UTF-8.
virtual double com::apama::event::Event::getTime ( ) const
pure virtual

Retrieve the event's timestamp.

This timestamp currently only has meaning for events which have been sourced from the correlator, in which case it is set to the correlator time at which it was created, or the value it was set to explicitly by code running within the correlator.

Returns
the timestamp of the event, in floating point seconds since the Unix epoch.

Friends And Related Function Documentation

AP_ENGINE_CLIENT_API Event* createEvent ( const char *  eventString,
const char *  channelString 
)
friend

This function allows creation of an Event object.

Parameters
eventStringC style string representing the event instance in MonitorScript. Note that this string should be encoded in UTF-8.
channelStringC style string representing the channel
Returns
A reference to an Event object.
AP_ENGINE_CLIENT_API void deleteEvent ( Event ev)
friend

This function allows deletion of an Event object.

Parameters
evA reference to an Event object.
std::ostream& operator<< ( std::ostream &  stream,
const Event obj 
)
friend

Output to an ostream from a reference.

std::ostream& operator<< ( std::ostream &  stream,
const Event obj 
)
friend

Output to an ostream from a pointer.


The documentation for this class was generated from the following file: