4 Quoter_Stock_i::Quoter_Stock_i (const char *symbol
,
7 : supplier_personality_ (this)
9 this->data_
.symbol
= symbol
;
10 this->data_
.full_name
= full_name
;
11 this->data_
.price
= price
;
15 Quoter_Stock_i::symbol ()
17 return CORBA::string_dup (this->data_
.symbol
.in ());
21 Quoter_Stock_i::full_name ()
23 return CORBA::string_dup (this->data_
.full_name
.in ());
27 Quoter_Stock_i::price ()
29 return this->data_
.price
;
33 Quoter_Stock_i::set_price (CORBA::Double new_price
)
35 this->data_
.price
= new_price
;
36 if (CORBA::is_nil (this->consumer_proxy_
.in ()))
40 event
<<= this->data_
;
41 this->consumer_proxy_
->push (event
);
45 Quoter_Stock_i::disconnect_push_supplier ()
47 // Forget about the consumer it is not there anymore
48 this->consumer_proxy_
=
49 CosEventChannelAdmin::ProxyPushConsumer::_nil ();
53 Quoter_Stock_i::connect (CosEventChannelAdmin::SupplierAdmin_ptr supplier_admin
)
55 this->consumer_proxy_
=
56 supplier_admin
->obtain_push_consumer ();
57 CosEventComm::PushSupplier_var supplier
=
58 this->supplier_personality_
._this ();
59 this->consumer_proxy_
->connect_push_supplier (supplier
.in ());