![]() |
libzmq master
The Intelligent Transport Layer
|
00001 /* 00002 Copyright (c) 2010-2011 250bpm s.r.o. 00003 Copyright (c) 2007-2009 iMatix Corporation 00004 Copyright (c) 2007-2011 Other contributors as noted in the AUTHORS file 00005 00006 This file is part of 0MQ. 00007 00008 0MQ is free software; you can redistribute it and/or modify it under 00009 the terms of the GNU Lesser General Public License as published by 00010 the Free Software Foundation; either version 3 of the License, or 00011 (at your option) any later version. 00012 00013 0MQ is distributed in the hope that it will be useful, 00014 but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00016 GNU Lesser General Public License for more details. 00017 00018 You should have received a copy of the GNU Lesser General Public License 00019 along with this program. If not, see <http://www.gnu.org/licenses/>. 00020 */ 00021 00022 #ifndef __ZMQ_I_POLL_EVENTS_HPP_INCLUDED__ 00023 #define __ZMQ_I_POLL_EVENTS_HPP_INCLUDED__ 00024 00025 namespace zmq 00026 { 00027 00028 // Virtual interface to be exposed by object that want to be notified 00029 // about events on file descriptors. 00030 00031 struct i_poll_events 00032 { 00033 virtual ~i_poll_events () {} 00034 00035 // Called by I/O thread when file descriptor is ready for reading. 00036 virtual void in_event () = 0; 00037 00038 // Called by I/O thread when file descriptor is ready for writing. 00039 virtual void out_event () = 0; 00040 00041 // Called when timer expires. 00042 virtual void timer_event (int id_) = 0; 00043 }; 00044 00045 } 00046 00047 #endif