#include "produktfilter_impl.h" using namespace Auktion; // necessary for implementation, but we don't know why MICO declares // the base class with its namespace in an implementation file class Gebot_impl: virtual public OBV_Auktion::Gebot, virtual public CORBA::DefaultValueRefCountBase { public: Gebot_impl(void) {}; }; class GebotFactory: virtual public CORBA::ValueFactoryBase { public: CORBA::ValueBase* create_for_unmarshal() { return new Gebot_impl(); }; }; ProduktFilter_impl::ProduktFilter_impl(const char* name) : ProduktFilter_Session(), name_(name), context_(NULL) {} ProduktFilter_impl::~ProduktFilter_impl(void) {} char* ProduktFilter_impl::interessanter_gegenstand() { return CORBA::string_dup(name_.c_str()); } void ProduktFilter_impl::interessanter_gegenstand(const char* value) { assert(value); name_ = CORBA::string_dup(value); } void ProduktFilter_impl::push_eingehende_gebote(Gebot* conxn) { assert(conxn); // convert to std::string const std::string subject(conxn->gegenstand()->name()); // check if this filter is responsible if(subject == name_) { // notify all registered consumers context_->push_interessante_gebote(conxn); } } void ProduktFilter_impl::set_session_context(Components::SessionContext_ptr ctx) { // save container context context_ = CCM_ProduktFilter_Context::_narrow(ctx); assert(!CORBA::is_nil(context_)); }