00001 00020 #ifndef RTC_OUTPORTPULLCONNECTOR_H 00021 #define RTC_OUTPORTPULLCONNECTOR_H 00022 00023 #include <rtm/InPortConnector.h> 00024 #include <rtm/InPortProvider.h> 00025 #include <rtm/PublisherBase.h> 00026 #include <rtm/DataPortStatus.h> 00027 00028 namespace RTC 00029 { 00030 class OutPortConsumer; 00031 00051 class InPortPullConnector 00052 : public InPortConnector 00053 { 00054 public: 00055 DATAPORTSTATUS_ENUM 00063 InPortPullConnector(Profile profile, 00064 OutPortConsumer* consumer, 00065 CdrBufferBase* buffer = 0); 00066 00074 virtual ~InPortPullConnector(); 00075 00089 virtual ReturnCode read(cdrMemoryStream& data); 00090 00104 virtual ReturnCode disconnect(); 00105 00106 virtual void activate(){}; // do nothing 00107 virtual void deactivate(){}; // do nothing 00108 protected: 00109 CdrBufferBase* createBuffer(Profile& profile); 00110 00111 private: 00112 OutPortConsumer* m_consumer; 00113 }; 00114 }; // namespace RTC 00115 00116 #endif // RTC_PULL_CONNECTOR_H