gloox  1.0
Public Types | Public Member Functions | List of all members
Event Class Reference

#include <event.h>

Public Types

enum  EventType { PingPing, PingPong, PingError }

Public Member Functions

 Event (EventType type)
 Event (EventType type, const Stanza &stanza)
virtual ~Event ()
EventType eventType () const
const Stanzastanza () const

Detailed Description

A base class for events.

Author
Jakob Schroeter js@ca.nosp@m.maya.nosp@m..net
Since
1.0

Definition at line 28 of file event.h.

Member Enumeration Documentation

enum EventType

Event types.

Enumerator:
PingPing 

Incoming Ping (XEP-0199).

PingPong 

Incoming Pong (XEP-0199).

PingError 

Incoming Error Pong (XEP-0199).

Definition at line 35 of file event.h.

Constructor & Destructor Documentation

Event ( EventType  type)
inline

Creates a new Event of the given type.

Parameters
typeThe Event type.

Definition at line 46 of file event.h.

Event ( EventType  type,
const Stanza stanza 
)
inline

Creates a new Event of the given type, referencing the given Stanza.

Parameters
typeThe Event type.
stanzaA Stanza to point at. No copy of the Stanza is taken, just its address.

Definition at line 53 of file event.h.

virtual ~Event ( )
inlinevirtual

Virtual Destructor.

Definition at line 58 of file event.h.

Member Function Documentation

EventType eventType ( ) const
inline

Returns the Event's type.

Returns
The Event's type.

Definition at line 64 of file event.h.

const Stanza* stanza ( ) const
inline

Returns a pointer to a Stanza-derived object.

Returns
A pointer to a Stanza that caused the event. May be 0.
Note
You should not delete the Stanza object.

Definition at line 71 of file event.h.


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