1 /* $Id: thread_pool_observer.hpp,v 1.6 2005-11-04 11:06:52 adam Exp $
2 Copyright (c) 2005, Index Data.
7 #ifndef YP2_THREAD_POOL_OBSERVER_HPP
8 #define YP2_THREAD_POOL_OBSERVER_HPP
10 #include <boost/scoped_ptr.hpp>
15 #include <yaz++/socket-observer.h>
16 #include <yaz/yconfig.h>
19 class IThreadPoolMsg {
21 virtual IThreadPoolMsg *handle() = 0;
22 virtual void result() = 0;
23 virtual ~IThreadPoolMsg();
26 class ThreadPoolSocketObserver : public yazpp_1::ISocketObserver {
30 ThreadPoolSocketObserver(yazpp_1::ISocketObservable *obs,
32 virtual ~ThreadPoolSocketObserver();
33 void put(IThreadPoolMsg *m);
34 IThreadPoolMsg *get();
37 void socketNotify(int event);
38 boost::scoped_ptr<Rep> m_p;
46 * indent-tabs-mode: nil
47 * c-file-style: "stroustrup"
49 * vim: shiftwidth=4 tabstop=8 expandtab