28 #ifndef INCLUDED_BLPAPI_EVENT 29 #define INCLUDED_BLPAPI_EVENT 306 const
Message *operator->() const noexcept;
405 virtual Event nextEvent(
int timeout = 0);
414 virtual int tryNextEvent(
Event *event);
422 virtual void purge();
485 Message message(
bool createClonable =
false)
const;
522 : d_impl_p(original.d_impl_p)
541 swap(tmp.d_impl_p, d_impl_p);
579 *
event =
Event(impl);
594 , d_current_p(nullptr)
611 return d_current_p ? true :
false;
616 if (createClonable) {
619 return Message(d_current_p, createClonable);
628 , d_currentMessage(nullptr)
642 : d_impl_p(original.d_impl_p)
643 , d_currentMessage(original.d_currentMessage)
664 return d_currentMessage;
669 return &d_currentMessage;
674 d_currentMessage =
Message(
nullptr);
678 d_currentMessage =
Message(nextMessage);
693 swap(d_impl_p, other.d_impl_p);
694 swap(d_currentMessage, other.d_currentMessage);
706 if (lhs.d_impl_p == rhs.d_impl_p
707 && lhs.d_currentMessage.impl() == rhs.d_currentMessage.impl()) {
711 const bool lend = !lhs.d_impl_p || !lhs.d_currentMessage.impl();
712 const bool rend = !rhs.d_impl_p || !rhs.d_currentMessage.impl();
720 return !(lhs == rhs);
730 #endif // #ifdef __cplusplus 731 #endif // #ifndef INCLUDED_BLPAPI_EVENT #define BLPAPI_EVENTTYPE_TOKEN_STATUS
Definition: blpapi_defs.h:93
Status updates for a request.
Definition: blpapi_event.h:209
struct blpapi_Message blpapi_Message_t
Definition: blpapi_dispatchtbl.h:78
Definition: blpapi_message.h:160
#define BLPAPI_EVENTTYPE_RESOLUTION_STATUS
Definition: blpapi_defs.h:91
iterator end() const
Definition: blpapi_event.h:557
Status updates for user authorization.
Definition: blpapi_event.h:221
bool operator!=(const CorrelationId &lhs, const CorrelationId &rhs)
Definition: blpapi_correlationid.h:582
const Message & operator *() const noexcept
Definition: blpapi_event.h:662
Status updates for a subscription.
Definition: blpapi_event.h:207
int blpapi_Event_eventType(const blpapi_Event_t *event)
int blpapi_EventQueue_purge(blpapi_EventQueue_t *eventQueue)
#define BLPAPI_EVENTTYPE_RESPONSE
Definition: blpapi_defs.h:85
Common definitions used by the library.
bool operator==(const CorrelationId &lhs, const CorrelationId &rhs)
Definition: blpapi_correlationid.h:562
void swap(Event::iterator &lhs, Event::iterator &rhs)
Swap the contents of the lhs and rhs iterators.
Definition: blpapi_event.h:723
struct blpapi_Event blpapi_Event_t
Definition: blpapi_types.h:139
blpapi_EventQueue_t * handle() const
Definition: blpapi_event.h:586
blpapi_EventQueue_t * blpapi_EventQueue_create(void)
void blpapi_MessageIterator_destroy(blpapi_MessageIterator_t *iterator)
Status updates about topics for service providers.
Definition: blpapi_event.h:225
#define BLPAPI_EVENTTYPE_SESSION_STATUS
Definition: blpapi_defs.h:82
Definition: blpapi_abstractsession.h:220
std::ptrdiff_t difference_type
Definition: blpapi_event.h:250
#define BLPAPI_EVENTTYPE_TIMEOUT
Definition: blpapi_defs.h:89
const Message * operator->() const noexcept
Definition: blpapi_event.h:667
#define BLPAPI_CALL(FUNCNAME)
Definition: blpapi_call.h:353
Event & operator=(const Event &rhs)
Definition: blpapi_event.h:536
iterator & operator=(const iterator &original)
Definition: blpapi_event.h:655
Data updates resulting from a subscription.
Definition: blpapi_event.h:215
#define BLPAPI_EVENTTYPE_ADMIN
Definition: blpapi_defs.h:81
The final (possibly only) response to a request.
Definition: blpapi_event.h:211
virtual Event nextEvent(int timeout=0)
Definition: blpapi_event.h:567
Definition: blpapi_event.h:243
bool isValid() const
Definition: blpapi_event.h:609
#define BLPAPI_EVENTTYPE_AUTHORIZATION_STATUS
Definition: blpapi_defs.h:90
Definition: blpapi_event.h:386
Status updates for a generate token request.
Definition: blpapi_event.h:227
Status updates for a service.
Definition: blpapi_event.h:217
virtual int tryNextEvent(Event *event)
Definition: blpapi_event.h:572
struct blpapi_EventQueue blpapi_EventQueue_t
Definition: blpapi_types.h:148
EventType
The possible types of event.
Definition: blpapi_event.h:202
EventQueue()
Definition: blpapi_event.h:563
#define BLPAPI_EVENTTYPE_SUBSCRIPTION_DATA
Definition: blpapi_defs.h:87
Status updates for a resolution operation.
Definition: blpapi_event.h:223
bool next()
Definition: blpapi_event.h:604
int blpapi_MessageIterator_addRef(const blpapi_MessageIterator_t *iterator)
iterator & operator++()
Definition: blpapi_event.h:672
EventType eventType() const
Definition: blpapi_event.h:546
#define BLPAPI_EVENTTYPE_TOPIC_STATUS
Definition: blpapi_defs.h:92
~MessageIterator()
Definition: blpapi_event.h:599
struct blpapi_MessageIterator blpapi_MessageIterator_t
Definition: blpapi_types.h:151
~Event()
Definition: blpapi_event.h:529
int blpapi_MessageIterator_next(blpapi_MessageIterator_t *iterator, blpapi_Message_t **result)
Admin event.
Definition: blpapi_event.h:203
Defines a message containing elements.
#define BLPAPI_EVENTTYPE_PARTIAL_RESPONSE
Definition: blpapi_defs.h:86
Event()
Definition: blpapi_event.h:511
iterator()
Definition: blpapi_event.h:626
void swap(iterator &other)
Definition: blpapi_event.h:690
iterator begin() const
Definition: blpapi_event.h:555
#define BLPAPI_EVENTTYPE_REQUEST_STATUS
Definition: blpapi_defs.h:84
virtual void purge()
Definition: blpapi_event.h:584
A partial response to a request.
Definition: blpapi_event.h:213
Request event. Provided to ProviderSession only.
Definition: blpapi_event.h:229
bool isValid() const
Definition: blpapi_event.h:551
Definition: blpapi_event.h:196
#define BLPAPI_EVENTTYPE_SERVICE_STATUS
Definition: blpapi_defs.h:88
blpapi_MessageIterator_t * blpapi_MessageIterator_create(const blpapi_Event_t *event)
Definition: blpapi_event.h:448
#define BLPAPI_EXPORT
Definition: blpapi_defs.h:171
std::input_iterator_tag iterator_category
Definition: blpapi_event.h:254
Provide functions for dispatchtbl.
blpapi_Event_t * blpapi_EventQueue_nextEvent(blpapi_EventQueue_t *eventQueue, int timeout)
int blpapi_EventQueue_destroy(blpapi_EventQueue_t *eventQueue)
#define BLPAPI_CALL_MESSAGE_ADDREF(a1)
Definition: blpapi_call.h:360
blpapi_Event_t * impl() const
Definition: blpapi_event.h:553
~iterator()
Definition: blpapi_event.h:650
int blpapi_EventQueue_tryNextEvent(blpapi_EventQueue_t *eventQueue, blpapi_Event_t **eventPointer)
#define BLPAPI_EVENTTYPE_SUBSCRIPTION_STATUS
Definition: blpapi_defs.h:83
An Event returned from Session::nextEvent() if it timed out.
Definition: blpapi_event.h:219
#define BLPAPI_EVENTTYPE_REQUEST
Definition: blpapi_defs.h:94
int blpapi_Event_addRef(const blpapi_Event_t *event)
Message message(bool createClonable=false) const
Definition: blpapi_event.h:614
MessageIterator(const MessageIterator &)=delete
virtual ~EventQueue()
Definition: blpapi_event.h:565
Status updates for a session.
Definition: blpapi_event.h:205
Definition: blpapi_event.h:231
int blpapi_Event_release(const blpapi_Event_t *event)