// **********************************************************************
//
// Generated by the ORBacus IDL-to-C++ Translator
//
// Copyright (c) 2003
// IONA Technologies, Inc.
// Waltham, MA, USA
//
// All Rights Reserved
//
// **********************************************************************

// Version: 4.1.3

#ifndef __OB_Reactor_h__
#define __OB_Reactor_h__

#ifndef OB_IMPORT
#   ifdef OB_DLL
#      define OB_IMPORT __declspec(dllimport)
#   else
#      define OB_IMPORT /**/
#   endif
#endif


#include <OB/Reactor_fwd.h>

#ifndef OB_INTEGER_VERSION
#   error No ORBacus version defined! Is <OB/CORBA.h> included?
#endif

#ifndef OB_NO_VERSION_CHECK
#   if (OB_INTEGER_VERSION != 4010300L)
#       error ORBacus version mismatch!
#   endif
#endif

namespace OBStubImpl_OB
{

} // End of namespace OBStubImpl_OB

namespace OBStubImpl_OB
{

} // End of namespace OBStubImpl_OB

//
// IDL:ooc.com/OB:1.0
//
namespace OB
{

//
// IDL:ooc.com/OB/EventHandler:1.0
//
typedef OBNative_OB::EventHandler EventHandler;

//
// IDL:ooc.com/OB/Handle:1.0
//
typedef ::CORBA::Long Handle;
typedef ::CORBA::Long_out Handle_out;

//
// IDL:ooc.com/OB/Mask:1.0
//
typedef ::CORBA::Long Mask;
typedef ::CORBA::Long_out Mask_out;

//
// IDL:ooc.com/OB/EventRead:1.0
//
const Mask EventRead = 1L;

//
// IDL:ooc.com/OB/EventWrite:1.0
//
const Mask EventWrite = 2L;

//
// IDL:ooc.com/OB/TypeMask:1.0
//
typedef ::CORBA::Long TypeMask;
typedef ::CORBA::Long_out TypeMask_out;

//
// IDL:ooc.com/OB/TypeClient:1.0
//
const TypeMask TypeClient = 1L;

//
// IDL:ooc.com/OB/TypeServer:1.0
//
const TypeMask TypeServer = 2L;

//
// IDL:ooc.com/OB/Reactor:1.0
//
class Reactor : virtual public ::CORBA::Object
{
    Reactor(const Reactor&);
    void operator=(const Reactor&);

protected:

    static OB_IMPORT const char* ids_[];

public:

    Reactor() { }
    virtual ~Reactor() { }

    typedef Reactor_ptr _ptr_type;
    typedef Reactor_var _var_type;

    static inline Reactor_ptr
    _duplicate(Reactor_ptr p)
    {
        if(p)
            p -> _add_ref();
        return p;
    }

    static inline Reactor_ptr
    _nil()
    {
        return 0;
    }

    static Reactor_ptr _narrow(::CORBA::Object_ptr);

    static Reactor_ptr _narrow(::CORBA::AbstractBase_ptr);


    //
    // IDL:ooc.com/OB/Reactor/register_handler:1.0
    //
    virtual void register_handler(EventHandler handler,
                                  Mask handler_mask,
                                  TypeMask type_mask,
                                  Handle h) = 0;

    //
    // IDL:ooc.com/OB/Reactor/unregister_handler:1.0
    //
    virtual void unregister_handler(EventHandler handler) = 0;

    //
    // IDL:ooc.com/OB/Reactor/dispatch:1.0
    //
    virtual ::CORBA::Boolean dispatch(TypeMask type_mask) = 0;

    //
    // IDL:ooc.com/OB/Reactor/interrupt_dispatch:1.0
    //
    virtual void interrupt_dispatch() = 0;

    //
    // IDL:ooc.com/OB/Reactor/dispatch_one_event:1.0
    //
    virtual ::CORBA::Boolean dispatch_one_event(::CORBA::Long timeout) = 0;

    //
    // IDL:ooc.com/OB/Reactor/event_ready:1.0
    //
    virtual ::CORBA::Boolean event_ready() = 0;
};

} // End of namespace OB

//
// IDL:ooc.com/OB:1.0
//
namespace OBProxy_OB
{

} // End of namespace OBProxy_OB

//
// IDL:ooc.com/OB:1.0
//
namespace OBStubImpl_OB
{

} // End of namespace OBStubImpl_OB

//
// IDL:ooc.com/OB:1.0
//
namespace OBMarshalStubImpl_OB
{

} // End of namespace OBMarshalStubImpl_OB

//
// IDL:ooc.com/OB:1.0
//
namespace OBV_OB
{

} // End of namespace OBV_OB

//
// IDL:ooc.com/OB/Reactor:1.0
//
namespace CORBA
{

inline void
release(::OB::Reactor_ptr p)
{
    if(p)
        p -> _remove_ref();
}

inline Boolean
is_nil(::OB::Reactor_ptr p)
{
    return p == 0;
}

} // End of namespace CORBA

#endif
