INTRODUCTION Overview Download and Install Quick Start Documentation Publications NONFRAMEWORK CODE Driver Interfaces Drivers Libraries Utilities FRAMEWORK CODE Interfaces Components Libraries Utilities Full Software Listings DEVELOPER Tutorials Examples Dev Guide Dashboard PEOPLE Contributors Users Project Download Mailing lists
|
velocitycontrol2dImpl.h00001 /* 00002 * Orca-Robotics Project: Components for robotics 00003 * http://orca-robotics.sf.net/ 00004 * Copyright (c) 2004-2009 Alex Brooks, Alexei Makarenko, Tobias Kaupp 00005 * 00006 * This copy of Orca is licensed to you under the terms described in 00007 * the LICENSE file included in this distribution. 00008 * 00009 */ 00010 00011 #ifndef ORCA_ORCAIFACEIMPL_VELOCITYCONTROL2D_IMPL_H 00012 #define ORCA_ORCAIFACEIMPL_VELOCITYCONTROL2D_IMPL_H 00013 00014 #include <orca/velocitycontrol2d.h> 00015 #include <gbxsickacfr/gbxiceutilacfr/store.h> 00016 #include <orcaice/context.h> 00017 00018 namespace gbxutilacfr { class Stoppable; } 00019 00020 namespace orcaifaceimpl { 00021 00022 class AbstractVelocityControl2dCallback { 00023 public: 00024 virtual ~AbstractVelocityControl2dCallback() {} 00025 virtual void setCommand( const orca::VelocityControl2dData &command )=0; 00026 }; 00027 00031 class VelocityControl2dImpl : public IceUtil::Shared 00032 { 00033 friend class VelocityControl2dI; 00034 00035 public: 00037 VelocityControl2dImpl( AbstractVelocityControl2dCallback &callback, 00038 const orca::VehicleDescription& descr, 00039 const std::string& interfaceTag, 00040 const orcaice::Context& context ); 00042 VelocityControl2dImpl( AbstractVelocityControl2dCallback &callback, 00043 const orca::VehicleDescription& descr, 00044 const orcaice::Context& context, 00045 const std::string& interfaceName ); 00046 ~VelocityControl2dImpl(); 00047 00049 void initInterface(); 00050 00053 void initInterface( gbxutilacfr::Stoppable* activity, const std::string& subsysName="", int retryInterval=2 ); 00054 00055 private: 00056 void init(); 00057 00058 // remote call implementations, mimic (but do not inherit) the orca interface 00059 orca::VehicleDescription internalGetDescription() const 00060 { return description_; } 00061 void internalSetCommand( const ::orca::VelocityControl2dData& ); 00062 00063 AbstractVelocityControl2dCallback &callback_; 00064 const orca::VehicleDescription description_; 00065 00066 Ice::ObjectPtr ptr_; 00067 const std::string interfaceName_; 00068 orcaice::Context context_; 00069 }; 00070 typedef IceUtil::Handle<VelocityControl2dImpl> VelocityControl2dImplPtr; 00071 00072 } // namespace 00073 00074 #endif |
Webmaster: Tobias Kaupp (tobasco at users.sourceforge.net)