00001 #ifndef SingleClientDataCollector_seen
00002 #define SingleClientDataCollector_seen
00003
00013 class SingleClientDataCollector :public virtual ClientOutputCollector {
00014 private:
00015 ClientOutputRelay* relay;
00016 public:
00017 SingleClientDataCollector( ClientOutputRelay* relay)
00018 { this->relay = relay; };
00019 static CDELETE ClientOutputCollector* create(ClientOutputRelay* relay) { return new SingleClientDataCollector(relay); };
00020 void computeClientOutput(ClientOutputEvent* evt)
00021 {
00022 printf ("SingleClientDataCollector::computeClientOutput\n");
00023
00024 if ((evt->getSource()->getId()) == 0)
00025 relay->relayMessageFromDataProducers(evt->getString());
00026 };
00027 void controllerClientOutput(ClientOutputEvent* evt)
00028 {
00029 printf ("SingleClientDataCollector::computeClientOutput\n");
00030 relay->relayMessageFromController(evt->getString());
00031 }
00032 void setClientOutputRelay( ClientOutputRelay* cR)
00033 { if (relay) delete relay; relay = cR;};
00034 void processOutOfBand(OutOfBandEvent * evt)
00035 {(void) evt; printf ("SingleClientDataCollector::processOutOfBand Method not implemented\n");};
00036 };
00037 #endif