// This file is generated by omniidl (C++ backend) - omniORB_4_3. Do not edit.

#include "CosNotification.hh"
#include <omniORB4/IOP_S.h>
#include <omniORB4/IOP_C.h>
#include <omniORB4/callDescriptor.h>
#include <omniORB4/callHandle.h>
#include <omniORB4/objTracker.h>


OMNI_USING_NAMESPACE(omni)

OMNI_MAYBE_UNUSED static const char* _0RL_library_version = omniORB_4_3;



void
CosNotification::Property::operator>>= (cdrStream &_n) const
{
  _n.marshalString(name,0);
  (const PropertyValue&) value >>= _n;

}

void
CosNotification::Property::operator<<= (cdrStream &_n)
{
  name = _n.unmarshalString(0);
  (PropertyValue&)value <<= _n;

}

void
CosNotification::EventType::operator>>= (cdrStream &_n) const
{
  _n.marshalString(domain_name,0);
  _n.marshalString(type_name,0);

}

void
CosNotification::EventType::operator<<= (cdrStream &_n)
{
  domain_name = _n.unmarshalString(0);
  type_name = _n.unmarshalString(0);

}

void
CosNotification::PropertyRange::operator>>= (cdrStream &_n) const
{
  (const PropertyValue&) low_val >>= _n;
  (const PropertyValue&) high_val >>= _n;

}

void
CosNotification::PropertyRange::operator<<= (cdrStream &_n)
{
  (PropertyValue&)low_val <<= _n;
  (PropertyValue&)high_val <<= _n;

}

void
CosNotification::NamedPropertyRange::operator>>= (cdrStream &_n) const
{
  _n.marshalString(name,0);
  (const PropertyRange&) range >>= _n;

}

void
CosNotification::NamedPropertyRange::operator<<= (cdrStream &_n)
{
  name = _n.unmarshalString(0);
  (PropertyRange&)range <<= _n;

}

void
CosNotification::PropertyError::operator>>= (cdrStream &_n) const
{
  code >>= _n;
  _n.marshalString(name,0);
  (const PropertyRange&) available_range >>= _n;

}

void
CosNotification::PropertyError::operator<<= (cdrStream &_n)
{
  (QoSError_code&)code <<= _n;
  name = _n.unmarshalString(0);
  (PropertyRange&)available_range <<= _n;

}

::CORBA::Exception::insertExceptionToAny CosNotification::UnsupportedQoS::insertToAnyFn = 0;
::CORBA::Exception::insertExceptionToAnyNCP CosNotification::UnsupportedQoS::insertToAnyFnNCP = 0;

CosNotification::UnsupportedQoS::UnsupportedQoS(const CosNotification::UnsupportedQoS& _s) : ::CORBA::UserException(_s)
{
  qos_err = _s.qos_err;

}

CosNotification::UnsupportedQoS::UnsupportedQoS(const PropertyErrorSeq _qos_err)
{
  pd_insertToAnyFn    = CosNotification::UnsupportedQoS::insertToAnyFn;
  pd_insertToAnyFnNCP = CosNotification::UnsupportedQoS::insertToAnyFnNCP;
  qos_err = _qos_err;

}



CosNotification::UnsupportedQoS& CosNotification::UnsupportedQoS::operator=(const CosNotification::UnsupportedQoS& _s)
{
  if (&_s != this) {
    ((::CORBA::UserException*) this)->operator=(_s);
    qos_err = _s.qos_err;

  }
  return *this;
}

CosNotification::UnsupportedQoS::~UnsupportedQoS() {}

void CosNotification::UnsupportedQoS::_raise() const { throw *this; }

const char* CosNotification::UnsupportedQoS::_PD_repoId = "IDL:omg.org/CosNotification/UnsupportedQoS:1.0";
const char* CosNotification::UnsupportedQoS::_PD_typeId = "Exception/UserException/CosNotification::UnsupportedQoS";

CosNotification::UnsupportedQoS* CosNotification::UnsupportedQoS::_downcast(::CORBA::Exception* _e) {
  return (UnsupportedQoS*) _NP_is_a(_e, _PD_typeId);
}

const CosNotification::UnsupportedQoS* CosNotification::UnsupportedQoS::_downcast(const ::CORBA::Exception* _e) {
  return (const UnsupportedQoS*) _NP_is_a(_e, _PD_typeId);
}

::CORBA::Exception* CosNotification::UnsupportedQoS::_NP_duplicate() const {
  return new UnsupportedQoS(*this);
}

const char* CosNotification::UnsupportedQoS::_NP_typeId() const {
  return _PD_typeId;
}

const char* CosNotification::UnsupportedQoS::_NP_repoId(int* _size) const {
  *_size = sizeof("IDL:omg.org/CosNotification/UnsupportedQoS:1.0");
  return _PD_repoId;
}
 
void CosNotification::UnsupportedQoS::_NP_marshal(cdrStream& _s) const {
  *this >>= _s;
}

void
CosNotification::UnsupportedQoS::operator>>= (cdrStream& _n) const
{
  (const PropertyErrorSeq&) qos_err >>= _n;

}

void
CosNotification::UnsupportedQoS::operator<<= (cdrStream& _n)
{
  (PropertyErrorSeq&)qos_err <<= _n;

}

::CORBA::Exception::insertExceptionToAny CosNotification::UnsupportedAdmin::insertToAnyFn = 0;
::CORBA::Exception::insertExceptionToAnyNCP CosNotification::UnsupportedAdmin::insertToAnyFnNCP = 0;

CosNotification::UnsupportedAdmin::UnsupportedAdmin(const CosNotification::UnsupportedAdmin& _s) : ::CORBA::UserException(_s)
{
  admin_err = _s.admin_err;

}

CosNotification::UnsupportedAdmin::UnsupportedAdmin(const PropertyErrorSeq _admin_err)
{
  pd_insertToAnyFn    = CosNotification::UnsupportedAdmin::insertToAnyFn;
  pd_insertToAnyFnNCP = CosNotification::UnsupportedAdmin::insertToAnyFnNCP;
  admin_err = _admin_err;

}



CosNotification::UnsupportedAdmin& CosNotification::UnsupportedAdmin::operator=(const CosNotification::UnsupportedAdmin& _s)
{
  if (&_s != this) {
    ((::CORBA::UserException*) this)->operator=(_s);
    admin_err = _s.admin_err;

  }
  return *this;
}

CosNotification::UnsupportedAdmin::~UnsupportedAdmin() {}

void CosNotification::UnsupportedAdmin::_raise() const { throw *this; }

const char* CosNotification::UnsupportedAdmin::_PD_repoId = "IDL:omg.org/CosNotification/UnsupportedAdmin:1.0";
const char* CosNotification::UnsupportedAdmin::_PD_typeId = "Exception/UserException/CosNotification::UnsupportedAdmin";

CosNotification::UnsupportedAdmin* CosNotification::UnsupportedAdmin::_downcast(::CORBA::Exception* _e) {
  return (UnsupportedAdmin*) _NP_is_a(_e, _PD_typeId);
}

const CosNotification::UnsupportedAdmin* CosNotification::UnsupportedAdmin::_downcast(const ::CORBA::Exception* _e) {
  return (const UnsupportedAdmin*) _NP_is_a(_e, _PD_typeId);
}

::CORBA::Exception* CosNotification::UnsupportedAdmin::_NP_duplicate() const {
  return new UnsupportedAdmin(*this);
}

const char* CosNotification::UnsupportedAdmin::_NP_typeId() const {
  return _PD_typeId;
}

const char* CosNotification::UnsupportedAdmin::_NP_repoId(int* _size) const {
  *_size = sizeof("IDL:omg.org/CosNotification/UnsupportedAdmin:1.0");
  return _PD_repoId;
}
 
void CosNotification::UnsupportedAdmin::_NP_marshal(cdrStream& _s) const {
  *this >>= _s;
}

void
CosNotification::UnsupportedAdmin::operator>>= (cdrStream& _n) const
{
  (const PropertyErrorSeq&) admin_err >>= _n;

}

void
CosNotification::UnsupportedAdmin::operator<<= (cdrStream& _n)
{
  (PropertyErrorSeq&)admin_err <<= _n;

}

void
CosNotification::FixedEventHeader::operator>>= (cdrStream &_n) const
{
  (const EventType&) event_type >>= _n;
  _n.marshalString(event_name,0);

}

void
CosNotification::FixedEventHeader::operator<<= (cdrStream &_n)
{
  (EventType&)event_type <<= _n;
  event_name = _n.unmarshalString(0);

}

void
CosNotification::EventHeader::operator>>= (cdrStream &_n) const
{
  (const FixedEventHeader&) fixed_header >>= _n;
  (const OptionalHeaderFields&) variable_header >>= _n;

}

void
CosNotification::EventHeader::operator<<= (cdrStream &_n)
{
  (FixedEventHeader&)fixed_header <<= _n;
  (OptionalHeaderFields&)variable_header <<= _n;

}

void
CosNotification::StructuredEvent::operator>>= (cdrStream &_n) const
{
  (const EventHeader&) header >>= _n;
  (const FilterableEventBody&) filterable_data >>= _n;
  (const ::CORBA::Any&) remainder_of_body >>= _n;

}

void
CosNotification::StructuredEvent::operator<<= (cdrStream &_n)
{
  (EventHeader&)header <<= _n;
  (FilterableEventBody&)filterable_data <<= _n;
  (::CORBA::Any&)remainder_of_body <<= _n;

}

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * EventReliability = "EventReliability";
} 
#else
const char * CosNotification::EventReliability = "EventReliability";
#endif

_init_in_def_( const ::CORBA::Short CosNotification::BestEffort = 0; )

_init_in_def_( const ::CORBA::Short CosNotification::Persistent = 1; )

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * ConnectionReliability = "ConnectionReliability";
} 
#else
const char * CosNotification::ConnectionReliability = "ConnectionReliability";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * Priority = "Priority";
} 
#else
const char * CosNotification::Priority = "Priority";
#endif

_init_in_def_( const ::CORBA::Short CosNotification::LowestPriority = -32767; )

_init_in_def_( const ::CORBA::Short CosNotification::HighestPriority = 32767; )

_init_in_def_( const ::CORBA::Short CosNotification::DefaultPriority = 0; )

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * StartTime = "StartTime";
} 
#else
const char * CosNotification::StartTime = "StartTime";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * StopTime = "StopTime";
} 
#else
const char * CosNotification::StopTime = "StopTime";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * Timeout = "Timeout";
} 
#else
const char * CosNotification::Timeout = "Timeout";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * OrderPolicy = "OrderPolicy";
} 
#else
const char * CosNotification::OrderPolicy = "OrderPolicy";
#endif

_init_in_def_( const ::CORBA::Short CosNotification::AnyOrder = 0; )

_init_in_def_( const ::CORBA::Short CosNotification::FifoOrder = 1; )

_init_in_def_( const ::CORBA::Short CosNotification::PriorityOrder = 2; )

_init_in_def_( const ::CORBA::Short CosNotification::DeadlineOrder = 3; )

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * DiscardPolicy = "DiscardPolicy";
} 
#else
const char * CosNotification::DiscardPolicy = "DiscardPolicy";
#endif

_init_in_def_( const ::CORBA::Short CosNotification::LifoOrder = 4; )

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * MaximumBatchSize = "MaximumBatchSize";
} 
#else
const char * CosNotification::MaximumBatchSize = "MaximumBatchSize";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * PacingInterval = "PacingInterval";
} 
#else
const char * CosNotification::PacingInterval = "PacingInterval";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * StartTimeSupported = "StartTimeSupported";
} 
#else
const char * CosNotification::StartTimeSupported = "StartTimeSupported";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * StopTimeSupported = "StopTimeSupported";
} 
#else
const char * CosNotification::StopTimeSupported = "StopTimeSupported";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * MaxEventsPerConsumer = "MaxEventsPerConsumer";
} 
#else
const char * CosNotification::MaxEventsPerConsumer = "MaxEventsPerConsumer";
#endif

CosNotification::QoSAdmin_ptr CosNotification::QoSAdmin_Helper::_nil() {
  return ::CosNotification::QoSAdmin::_nil();
}

::CORBA::Boolean CosNotification::QoSAdmin_Helper::is_nil(::CosNotification::QoSAdmin_ptr p) {
  return ::CORBA::is_nil(p);

}

void CosNotification::QoSAdmin_Helper::release(::CosNotification::QoSAdmin_ptr p) {
  ::CORBA::release(p);
}

void CosNotification::QoSAdmin_Helper::marshalObjRef(::CosNotification::QoSAdmin_ptr obj, cdrStream& s) {
  ::CosNotification::QoSAdmin::_marshalObjRef(obj, s);
}

CosNotification::QoSAdmin_ptr CosNotification::QoSAdmin_Helper::unmarshalObjRef(cdrStream& s) {
  return ::CosNotification::QoSAdmin::_unmarshalObjRef(s);
}

void CosNotification::QoSAdmin_Helper::duplicate(::CosNotification::QoSAdmin_ptr obj) {
  if (obj && !obj->_NP_is_nil())  omni::duplicateObjRef(obj);
}

CosNotification::QoSAdmin_ptr
CosNotification::QoSAdmin::_duplicate(::CosNotification::QoSAdmin_ptr obj)
{
  if (obj && !obj->_NP_is_nil())  omni::duplicateObjRef(obj);
  return obj;
}

CosNotification::QoSAdmin_ptr
CosNotification::QoSAdmin::_narrow(::CORBA::Object_ptr obj)
{
  if (!obj || obj->_NP_is_nil() || obj->_NP_is_pseudo()) return _nil();
  _ptr_type e = (_ptr_type) obj->_PR_getobj()->_realNarrow(_PD_repoId);
  return e ? e : _nil();
}


CosNotification::QoSAdmin_ptr
CosNotification::QoSAdmin::_unchecked_narrow(::CORBA::Object_ptr obj)
{
  if (!obj || obj->_NP_is_nil() || obj->_NP_is_pseudo()) return _nil();
  _ptr_type e = (_ptr_type) obj->_PR_getobj()->_uncheckedNarrow(_PD_repoId);
  return e ? e : _nil();
}

CosNotification::QoSAdmin_ptr
CosNotification::QoSAdmin::_nil()
{
#ifdef OMNI_UNLOADABLE_STUBS
  static _objref_QoSAdmin _the_nil_obj;
  return &_the_nil_obj;
#else
  static _objref_QoSAdmin* _the_nil_ptr = 0;
  if (!_the_nil_ptr) {
    omni::nilRefLock().lock();
    if (!_the_nil_ptr) {
      _the_nil_ptr = new _objref_QoSAdmin;
      registerNilCorbaObject(_the_nil_ptr);
    }
    omni::nilRefLock().unlock();
  }
  return _the_nil_ptr;
#endif
}

const char* CosNotification::QoSAdmin::_PD_repoId = "IDL:omg.org/CosNotification/QoSAdmin:1.0";


CosNotification::_objref_QoSAdmin::~_objref_QoSAdmin() {
  
}


CosNotification::_objref_QoSAdmin::_objref_QoSAdmin(omniIOR* ior, omniIdentity* id) :
   omniObjRef(::CosNotification::QoSAdmin::_PD_repoId, ior, id, 1)
   
   
{
  _PR_setobj(this);
}

void*
CosNotification::_objref_QoSAdmin::_ptrToObjRef(const char* id)
{
  if (id == ::CosNotification::QoSAdmin::_PD_repoId)
    return (::CosNotification::QoSAdmin_ptr) this;
  
  if (id == ::CORBA::Object::_PD_repoId)
    return (::CORBA::Object_ptr) this;

  if (omni::strMatch(id, ::CosNotification::QoSAdmin::_PD_repoId))
    return (::CosNotification::QoSAdmin_ptr) this;
  
  if (omni::strMatch(id, ::CORBA::Object::_PD_repoId))
    return (::CORBA::Object_ptr) this;

  return 0;
}


//
// Code for CosNotification::QoSAdmin::get_qos

// Proxy call descriptor class. Mangled signature:
//  _cCosNotification_mPropertySeq
class _0RL_cd_8b6214f5b3100e7e_00000000
  : public omniCallDescriptor
{
public:
  inline _0RL_cd_8b6214f5b3100e7e_00000000(LocalCallFn lcfn, const char* op_, size_t oplen, _CORBA_Boolean upcall=0)
    : omniCallDescriptor(lcfn, op_, oplen, 0, _user_exns, 0, upcall)
  {
    
  }
  
  
  void unmarshalReturnedValues(cdrStream&);
  void marshalReturnedValues(cdrStream&);
  
  
  static const char* const _user_exns[];

  CosNotification::QoSProperties_var result;
};

void _0RL_cd_8b6214f5b3100e7e_00000000::marshalReturnedValues(cdrStream& _n)
{
  (const CosNotification::QoSProperties&) result >>= _n;

}

void _0RL_cd_8b6214f5b3100e7e_00000000::unmarshalReturnedValues(cdrStream& _n)
{
  result = new CosNotification::QoSProperties;
  (CosNotification::QoSProperties&)result <<= _n;

}

const char* const _0RL_cd_8b6214f5b3100e7e_00000000::_user_exns[] = {
  0
};

// Local call call-back function.
static void
_0RL_lcfn_8b6214f5b3100e7e_10000000(omniCallDescriptor* cd, omniServant* svnt)
{
  _0RL_cd_8b6214f5b3100e7e_00000000* tcd = (_0RL_cd_8b6214f5b3100e7e_00000000*)cd;
  CosNotification::_impl_QoSAdmin* impl = (CosNotification::_impl_QoSAdmin*) svnt->_ptrToInterface(CosNotification::QoSAdmin::_PD_repoId);
  tcd->result = impl->get_qos();


}

CosNotification::QoSProperties* CosNotification::_objref_QoSAdmin::get_qos()
{
  _0RL_cd_8b6214f5b3100e7e_00000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_10000000, "get_qos", 8);


  _invoke(_call_desc);
  return _call_desc.result._retn();


}


//
// Code for CosNotification::QoSAdmin::set_qos

// Proxy call descriptor class. Mangled signature:
//  void_i_cCosNotification_mPropertySeq_e_cCosNotification_mUnsupportedQoS
class _0RL_cd_8b6214f5b3100e7e_20000000
  : public omniCallDescriptor
{
public:
  inline _0RL_cd_8b6214f5b3100e7e_20000000(LocalCallFn lcfn, const char* op_, size_t oplen, _CORBA_Boolean upcall=0)
    : omniCallDescriptor(lcfn, op_, oplen, 0, _user_exns, 1, upcall)
  {
    
  }
  
  void marshalArguments(cdrStream&);
  void unmarshalArguments(cdrStream&);

    
  void userException(cdrStream&, _OMNI_NS(IOP_C)*, const char*);
  static const char* const _user_exns[];

  CosNotification::QoSProperties_var arg_0_;
  const CosNotification::QoSProperties* arg_0;
};

void _0RL_cd_8b6214f5b3100e7e_20000000::marshalArguments(cdrStream& _n)
{
  (const CosNotification::QoSProperties&) *arg_0 >>= _n;

}

void _0RL_cd_8b6214f5b3100e7e_20000000::unmarshalArguments(cdrStream& _n)
{
  arg_0_ = new CosNotification::QoSProperties;
  (CosNotification::QoSProperties&)arg_0_ <<= _n;
  arg_0 = &arg_0_.in();

}

const char* const _0RL_cd_8b6214f5b3100e7e_20000000::_user_exns[] = {
  CosNotification::UnsupportedQoS::_PD_repoId
};

void _0RL_cd_8b6214f5b3100e7e_20000000::userException(cdrStream& s, _OMNI_NS(IOP_C)* iop_client, const char* repoId)
{
  if (omni::strMatch(repoId, CosNotification::UnsupportedQoS::_PD_repoId)) {
    CosNotification::UnsupportedQoS _ex;
    _ex <<= s;
    if (iop_client) iop_client->RequestCompleted();
    throw _ex;
  }


  else {
    if (iop_client) iop_client->RequestCompleted(1);
    OMNIORB_THROW(UNKNOWN,UNKNOWN_UserException,
                  (::CORBA::CompletionStatus)s.completion());
  }
}

// Local call call-back function.
static void
_0RL_lcfn_8b6214f5b3100e7e_30000000(omniCallDescriptor* cd, omniServant* svnt)
{
  _0RL_cd_8b6214f5b3100e7e_20000000* tcd = (_0RL_cd_8b6214f5b3100e7e_20000000*)cd;
  CosNotification::_impl_QoSAdmin* impl = (CosNotification::_impl_QoSAdmin*) svnt->_ptrToInterface(CosNotification::QoSAdmin::_PD_repoId);
#ifdef OMNI_HAS_Cplusplus_catch_exception_by_base
  impl->set_qos(*tcd->arg_0);
#else
  if (!cd->is_upcall())
    impl->set_qos(*tcd->arg_0);
  else {
    try {
      impl->set_qos(*tcd->arg_0);
    }
    catch(CosNotification::UnsupportedQoS& ex) {
      throw omniORB::StubUserException(ex._NP_duplicate());
    }


  }
#endif


}

void CosNotification::_objref_QoSAdmin::set_qos(const ::CosNotification::QoSProperties& qos)
{
  _0RL_cd_8b6214f5b3100e7e_20000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_30000000, "set_qos", 8);
  _call_desc.arg_0 = &(::CosNotification::QoSProperties&) qos;

  _invoke(_call_desc);



}


//
// Code for CosNotification::QoSAdmin::validate_qos

// Proxy call descriptor class. Mangled signature:
//  void_i_cCosNotification_mPropertySeq_o_cCosNotification_mNamedPropertyRangeSeq_e_cCosNotification_mUnsupportedQoS
class _0RL_cd_8b6214f5b3100e7e_40000000
  : public omniCallDescriptor
{
public:
  inline _0RL_cd_8b6214f5b3100e7e_40000000(LocalCallFn lcfn, const char* op_, size_t oplen, _CORBA_Boolean upcall=0)
    : omniCallDescriptor(lcfn, op_, oplen, 0, _user_exns, 1, upcall)
  {
    
  }
  
  void marshalArguments(cdrStream&);
  void unmarshalArguments(cdrStream&);

  void unmarshalReturnedValues(cdrStream&);
  void marshalReturnedValues(cdrStream&);
  
  void userException(cdrStream&, _OMNI_NS(IOP_C)*, const char*);
  static const char* const _user_exns[];

  CosNotification::QoSProperties_var arg_0_;
  const CosNotification::QoSProperties* arg_0;
  CosNotification::NamedPropertyRangeSeq_var arg_1;
};

void _0RL_cd_8b6214f5b3100e7e_40000000::marshalArguments(cdrStream& _n)
{
  (const CosNotification::QoSProperties&) *arg_0 >>= _n;

}

void _0RL_cd_8b6214f5b3100e7e_40000000::unmarshalArguments(cdrStream& _n)
{
  arg_0_ = new CosNotification::QoSProperties;
  (CosNotification::QoSProperties&)arg_0_ <<= _n;
  arg_0 = &arg_0_.in();

}

void _0RL_cd_8b6214f5b3100e7e_40000000::marshalReturnedValues(cdrStream& _n)
{
  (const CosNotification::NamedPropertyRangeSeq&) arg_1 >>= _n;

}

void _0RL_cd_8b6214f5b3100e7e_40000000::unmarshalReturnedValues(cdrStream& _n)
{
  arg_1 = new CosNotification::NamedPropertyRangeSeq;
  (CosNotification::NamedPropertyRangeSeq&)arg_1 <<= _n;

}

const char* const _0RL_cd_8b6214f5b3100e7e_40000000::_user_exns[] = {
  CosNotification::UnsupportedQoS::_PD_repoId
};

void _0RL_cd_8b6214f5b3100e7e_40000000::userException(cdrStream& s, _OMNI_NS(IOP_C)* iop_client, const char* repoId)
{
  if (omni::strMatch(repoId, CosNotification::UnsupportedQoS::_PD_repoId)) {
    CosNotification::UnsupportedQoS _ex;
    _ex <<= s;
    if (iop_client) iop_client->RequestCompleted();
    throw _ex;
  }


  else {
    if (iop_client) iop_client->RequestCompleted(1);
    OMNIORB_THROW(UNKNOWN,UNKNOWN_UserException,
                  (::CORBA::CompletionStatus)s.completion());
  }
}

// Local call call-back function.
static void
_0RL_lcfn_8b6214f5b3100e7e_50000000(omniCallDescriptor* cd, omniServant* svnt)
{
  _0RL_cd_8b6214f5b3100e7e_40000000* tcd = (_0RL_cd_8b6214f5b3100e7e_40000000*)cd;
  CosNotification::_impl_QoSAdmin* impl = (CosNotification::_impl_QoSAdmin*) svnt->_ptrToInterface(CosNotification::QoSAdmin::_PD_repoId);
#ifdef OMNI_HAS_Cplusplus_catch_exception_by_base
  impl->validate_qos(*tcd->arg_0, tcd->arg_1.out());
#else
  if (!cd->is_upcall())
    impl->validate_qos(*tcd->arg_0, tcd->arg_1.out());
  else {
    try {
      impl->validate_qos(*tcd->arg_0, tcd->arg_1.out());
    }
    catch(CosNotification::UnsupportedQoS& ex) {
      throw omniORB::StubUserException(ex._NP_duplicate());
    }


  }
#endif


}

void CosNotification::_objref_QoSAdmin::validate_qos(const ::CosNotification::QoSProperties& required_qos, ::CosNotification::NamedPropertyRangeSeq_out available_qos)
{
  _0RL_cd_8b6214f5b3100e7e_40000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_50000000, "validate_qos", 13);
  _call_desc.arg_0 = &(::CosNotification::QoSProperties&) required_qos;

  _invoke(_call_desc);
  available_qos = _call_desc.arg_1._retn();


}

CosNotification::_pof_QoSAdmin::~_pof_QoSAdmin() {}


omniObjRef*
CosNotification::_pof_QoSAdmin::newObjRef(omniIOR* ior, omniIdentity* id)
{
  return new ::CosNotification::_objref_QoSAdmin(ior, id);
}


::CORBA::Boolean
CosNotification::_pof_QoSAdmin::is_a(const char* id) const
{
  if (omni::ptrStrMatch(id, ::CosNotification::QoSAdmin::_PD_repoId))
    return 1;
  
  return 0;
}

const CosNotification::_pof_QoSAdmin _the_pof_CosNotification_mQoSAdmin;

CosNotification::_impl_QoSAdmin::~_impl_QoSAdmin() {}


::CORBA::Boolean
CosNotification::_impl_QoSAdmin::_dispatch(omniCallHandle& _handle)
{
  const char* op = _handle.operation_name();

  if (omni::strMatch(op, "get_qos")) {

    _0RL_cd_8b6214f5b3100e7e_00000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_10000000, "get_qos", 8, 1);
    
    _handle.upcall(this,_call_desc);
    return 1;
  }

  if (omni::strMatch(op, "set_qos")) {

    _0RL_cd_8b6214f5b3100e7e_20000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_30000000, "set_qos", 8, 1);
    
    _handle.upcall(this,_call_desc);
    return 1;
  }

  if (omni::strMatch(op, "validate_qos")) {

    _0RL_cd_8b6214f5b3100e7e_40000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_50000000, "validate_qos", 13, 1);
    
    _handle.upcall(this,_call_desc);
    return 1;
  }


  return 0;
}

void*
CosNotification::_impl_QoSAdmin::_ptrToInterface(const char* id)
{
  if (id == ::CosNotification::QoSAdmin::_PD_repoId)
    return (::CosNotification::_impl_QoSAdmin*) this;
  
  if (id == ::CORBA::Object::_PD_repoId)
    return (void*) 1;

  if (omni::strMatch(id, ::CosNotification::QoSAdmin::_PD_repoId))
    return (::CosNotification::_impl_QoSAdmin*) this;
  
  if (omni::strMatch(id, ::CORBA::Object::_PD_repoId))
    return (void*) 1;
  return 0;
}

const char*
CosNotification::_impl_QoSAdmin::_mostDerivedRepoId()
{
  return ::CosNotification::QoSAdmin::_PD_repoId;
}

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * MaxQueueLength = "MaxQueueLength";
} 
#else
const char * CosNotification::MaxQueueLength = "MaxQueueLength";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * MaxConsumers = "MaxConsumers";
} 
#else
const char * CosNotification::MaxConsumers = "MaxConsumers";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * MaxSuppliers = "MaxSuppliers";
} 
#else
const char * CosNotification::MaxSuppliers = "MaxSuppliers";
#endif

#if defined(OMNI_HAS_Cplusplus_Namespace) && defined(_MSC_VER)
// MSVC++ does not give the constant external linkage othewise.
namespace CosNotification { 
  extern const char * RejectNewEvents = "RejectNewEvents";
} 
#else
const char * CosNotification::RejectNewEvents = "RejectNewEvents";
#endif

CosNotification::AdminPropertiesAdmin_ptr CosNotification::AdminPropertiesAdmin_Helper::_nil() {
  return ::CosNotification::AdminPropertiesAdmin::_nil();
}

::CORBA::Boolean CosNotification::AdminPropertiesAdmin_Helper::is_nil(::CosNotification::AdminPropertiesAdmin_ptr p) {
  return ::CORBA::is_nil(p);

}

void CosNotification::AdminPropertiesAdmin_Helper::release(::CosNotification::AdminPropertiesAdmin_ptr p) {
  ::CORBA::release(p);
}

void CosNotification::AdminPropertiesAdmin_Helper::marshalObjRef(::CosNotification::AdminPropertiesAdmin_ptr obj, cdrStream& s) {
  ::CosNotification::AdminPropertiesAdmin::_marshalObjRef(obj, s);
}

CosNotification::AdminPropertiesAdmin_ptr CosNotification::AdminPropertiesAdmin_Helper::unmarshalObjRef(cdrStream& s) {
  return ::CosNotification::AdminPropertiesAdmin::_unmarshalObjRef(s);
}

void CosNotification::AdminPropertiesAdmin_Helper::duplicate(::CosNotification::AdminPropertiesAdmin_ptr obj) {
  if (obj && !obj->_NP_is_nil())  omni::duplicateObjRef(obj);
}

CosNotification::AdminPropertiesAdmin_ptr
CosNotification::AdminPropertiesAdmin::_duplicate(::CosNotification::AdminPropertiesAdmin_ptr obj)
{
  if (obj && !obj->_NP_is_nil())  omni::duplicateObjRef(obj);
  return obj;
}

CosNotification::AdminPropertiesAdmin_ptr
CosNotification::AdminPropertiesAdmin::_narrow(::CORBA::Object_ptr obj)
{
  if (!obj || obj->_NP_is_nil() || obj->_NP_is_pseudo()) return _nil();
  _ptr_type e = (_ptr_type) obj->_PR_getobj()->_realNarrow(_PD_repoId);
  return e ? e : _nil();
}


CosNotification::AdminPropertiesAdmin_ptr
CosNotification::AdminPropertiesAdmin::_unchecked_narrow(::CORBA::Object_ptr obj)
{
  if (!obj || obj->_NP_is_nil() || obj->_NP_is_pseudo()) return _nil();
  _ptr_type e = (_ptr_type) obj->_PR_getobj()->_uncheckedNarrow(_PD_repoId);
  return e ? e : _nil();
}

CosNotification::AdminPropertiesAdmin_ptr
CosNotification::AdminPropertiesAdmin::_nil()
{
#ifdef OMNI_UNLOADABLE_STUBS
  static _objref_AdminPropertiesAdmin _the_nil_obj;
  return &_the_nil_obj;
#else
  static _objref_AdminPropertiesAdmin* _the_nil_ptr = 0;
  if (!_the_nil_ptr) {
    omni::nilRefLock().lock();
    if (!_the_nil_ptr) {
      _the_nil_ptr = new _objref_AdminPropertiesAdmin;
      registerNilCorbaObject(_the_nil_ptr);
    }
    omni::nilRefLock().unlock();
  }
  return _the_nil_ptr;
#endif
}

const char* CosNotification::AdminPropertiesAdmin::_PD_repoId = "IDL:omg.org/CosNotification/AdminPropertiesAdmin:1.0";


CosNotification::_objref_AdminPropertiesAdmin::~_objref_AdminPropertiesAdmin() {
  
}


CosNotification::_objref_AdminPropertiesAdmin::_objref_AdminPropertiesAdmin(omniIOR* ior, omniIdentity* id) :
   omniObjRef(::CosNotification::AdminPropertiesAdmin::_PD_repoId, ior, id, 1)
   
   
{
  _PR_setobj(this);
}

void*
CosNotification::_objref_AdminPropertiesAdmin::_ptrToObjRef(const char* id)
{
  if (id == ::CosNotification::AdminPropertiesAdmin::_PD_repoId)
    return (::CosNotification::AdminPropertiesAdmin_ptr) this;
  
  if (id == ::CORBA::Object::_PD_repoId)
    return (::CORBA::Object_ptr) this;

  if (omni::strMatch(id, ::CosNotification::AdminPropertiesAdmin::_PD_repoId))
    return (::CosNotification::AdminPropertiesAdmin_ptr) this;
  
  if (omni::strMatch(id, ::CORBA::Object::_PD_repoId))
    return (::CORBA::Object_ptr) this;

  return 0;
}


//
// Code for CosNotification::AdminPropertiesAdmin::get_admin

// Local call call-back function.
static void
_0RL_lcfn_8b6214f5b3100e7e_60000000(omniCallDescriptor* cd, omniServant* svnt)
{
  _0RL_cd_8b6214f5b3100e7e_00000000* tcd = (_0RL_cd_8b6214f5b3100e7e_00000000*)cd;
  CosNotification::_impl_AdminPropertiesAdmin* impl = (CosNotification::_impl_AdminPropertiesAdmin*) svnt->_ptrToInterface(CosNotification::AdminPropertiesAdmin::_PD_repoId);
  tcd->result = impl->get_admin();


}

CosNotification::AdminProperties* CosNotification::_objref_AdminPropertiesAdmin::get_admin()
{
  _0RL_cd_8b6214f5b3100e7e_00000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_60000000, "get_admin", 10);


  _invoke(_call_desc);
  return _call_desc.result._retn();


}


//
// Code for CosNotification::AdminPropertiesAdmin::set_admin

// Proxy call descriptor class. Mangled signature:
//  void_i_cCosNotification_mPropertySeq_e_cCosNotification_mUnsupportedAdmin
class _0RL_cd_8b6214f5b3100e7e_70000000
  : public omniCallDescriptor
{
public:
  inline _0RL_cd_8b6214f5b3100e7e_70000000(LocalCallFn lcfn, const char* op_, size_t oplen, _CORBA_Boolean upcall=0)
    : omniCallDescriptor(lcfn, op_, oplen, 0, _user_exns, 1, upcall)
  {
    
  }
  
  void marshalArguments(cdrStream&);
  void unmarshalArguments(cdrStream&);

    
  void userException(cdrStream&, _OMNI_NS(IOP_C)*, const char*);
  static const char* const _user_exns[];

  CosNotification::AdminProperties_var arg_0_;
  const CosNotification::AdminProperties* arg_0;
};

void _0RL_cd_8b6214f5b3100e7e_70000000::marshalArguments(cdrStream& _n)
{
  (const CosNotification::AdminProperties&) *arg_0 >>= _n;

}

void _0RL_cd_8b6214f5b3100e7e_70000000::unmarshalArguments(cdrStream& _n)
{
  arg_0_ = new CosNotification::AdminProperties;
  (CosNotification::AdminProperties&)arg_0_ <<= _n;
  arg_0 = &arg_0_.in();

}

const char* const _0RL_cd_8b6214f5b3100e7e_70000000::_user_exns[] = {
  CosNotification::UnsupportedAdmin::_PD_repoId
};

void _0RL_cd_8b6214f5b3100e7e_70000000::userException(cdrStream& s, _OMNI_NS(IOP_C)* iop_client, const char* repoId)
{
  if (omni::strMatch(repoId, CosNotification::UnsupportedAdmin::_PD_repoId)) {
    CosNotification::UnsupportedAdmin _ex;
    _ex <<= s;
    if (iop_client) iop_client->RequestCompleted();
    throw _ex;
  }


  else {
    if (iop_client) iop_client->RequestCompleted(1);
    OMNIORB_THROW(UNKNOWN,UNKNOWN_UserException,
                  (::CORBA::CompletionStatus)s.completion());
  }
}

// Local call call-back function.
static void
_0RL_lcfn_8b6214f5b3100e7e_80000000(omniCallDescriptor* cd, omniServant* svnt)
{
  _0RL_cd_8b6214f5b3100e7e_70000000* tcd = (_0RL_cd_8b6214f5b3100e7e_70000000*)cd;
  CosNotification::_impl_AdminPropertiesAdmin* impl = (CosNotification::_impl_AdminPropertiesAdmin*) svnt->_ptrToInterface(CosNotification::AdminPropertiesAdmin::_PD_repoId);
#ifdef OMNI_HAS_Cplusplus_catch_exception_by_base
  impl->set_admin(*tcd->arg_0);
#else
  if (!cd->is_upcall())
    impl->set_admin(*tcd->arg_0);
  else {
    try {
      impl->set_admin(*tcd->arg_0);
    }
    catch(CosNotification::UnsupportedAdmin& ex) {
      throw omniORB::StubUserException(ex._NP_duplicate());
    }


  }
#endif


}

void CosNotification::_objref_AdminPropertiesAdmin::set_admin(const ::CosNotification::AdminProperties& admin)
{
  _0RL_cd_8b6214f5b3100e7e_70000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_80000000, "set_admin", 10);
  _call_desc.arg_0 = &(::CosNotification::AdminProperties&) admin;

  _invoke(_call_desc);



}

CosNotification::_pof_AdminPropertiesAdmin::~_pof_AdminPropertiesAdmin() {}


omniObjRef*
CosNotification::_pof_AdminPropertiesAdmin::newObjRef(omniIOR* ior, omniIdentity* id)
{
  return new ::CosNotification::_objref_AdminPropertiesAdmin(ior, id);
}


::CORBA::Boolean
CosNotification::_pof_AdminPropertiesAdmin::is_a(const char* id) const
{
  if (omni::ptrStrMatch(id, ::CosNotification::AdminPropertiesAdmin::_PD_repoId))
    return 1;
  
  return 0;
}

const CosNotification::_pof_AdminPropertiesAdmin _the_pof_CosNotification_mAdminPropertiesAdmin;

CosNotification::_impl_AdminPropertiesAdmin::~_impl_AdminPropertiesAdmin() {}


::CORBA::Boolean
CosNotification::_impl_AdminPropertiesAdmin::_dispatch(omniCallHandle& _handle)
{
  const char* op = _handle.operation_name();

  if (omni::strMatch(op, "get_admin")) {

    _0RL_cd_8b6214f5b3100e7e_00000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_60000000, "get_admin", 10, 1);
    
    _handle.upcall(this,_call_desc);
    return 1;
  }

  if (omni::strMatch(op, "set_admin")) {

    _0RL_cd_8b6214f5b3100e7e_70000000 _call_desc(_0RL_lcfn_8b6214f5b3100e7e_80000000, "set_admin", 10, 1);
    
    _handle.upcall(this,_call_desc);
    return 1;
  }


  return 0;
}

void*
CosNotification::_impl_AdminPropertiesAdmin::_ptrToInterface(const char* id)
{
  if (id == ::CosNotification::AdminPropertiesAdmin::_PD_repoId)
    return (::CosNotification::_impl_AdminPropertiesAdmin*) this;
  
  if (id == ::CORBA::Object::_PD_repoId)
    return (void*) 1;

  if (omni::strMatch(id, ::CosNotification::AdminPropertiesAdmin::_PD_repoId))
    return (::CosNotification::_impl_AdminPropertiesAdmin*) this;
  
  if (omni::strMatch(id, ::CORBA::Object::_PD_repoId))
    return (void*) 1;
  return 0;
}

const char*
CosNotification::_impl_AdminPropertiesAdmin::_mostDerivedRepoId()
{
  return ::CosNotification::AdminPropertiesAdmin::_PD_repoId;
}

POA_CosNotification::QoSAdmin::~QoSAdmin() {}

POA_CosNotification::AdminPropertiesAdmin::~AdminPropertiesAdmin() {}

