00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036 #ifndef MACROS_H_
00037 #define MACROS_H_
00038
00039 #include "TopicManager.h"
00040 #include "ServiceManager.h"
00041 #include "TFManager.h"
00042 #include "WMPTopicManager.h"
00043 #include "WMPServiceManager.h"
00044 #include "WMPNodeManager.h"
00045
00046 #define TOPIC(name,type,src,dest, prio) m = new TopicManager<type> (n, port, std::string(name), src, dest, prio, false); \
00047 w->addManager(name, m); port++;
00048
00049 #define TOPIC_START_STOPPED(name,type,src,dest, prio) m = new TopicManager<type> (n, port, std::string(name), src, dest, prio, false); \
00050 w->addManager(name, m); port++; m->stop();
00051
00052 #define DYNAMIC_TOPIC(name,type,src, prio) m = new TopicManager<type> (n, port, std::string(name), src, prio, false); \
00053 w->addManager(name, m); port++;
00054
00055 #define WMP_TOPIC(name,type,src) m = new WMPTopicManager<type> (n, port, std::string(name), src, false); \
00056 w->addManager(name, m); port++;
00057
00058 #define SERVICE(name,type,host, prio) m = new ServiceManager<type> (n, port, std::string(name),host, prio); \
00059 w->addManager(name, m); port+=2;
00060
00061 #define DYNAMIC_SERVICE(name,type, prio) m = new ServiceManager<type> (n, port, std::string(name), prio); \
00062 w->addManager(name, m); port+=2;
00063
00064 #define WMP_SERVICE(name,type) m = new WMPServiceManager<type> (n, port, std::string(name)); \
00065 w->addManager(name, m); port+=2;
00066
00067 #define TOPIC_TF(src,dest) m = new TFManager(n, port, src, dest, false) ; \
00068 w->addManager("/tf", m); port++;
00069
00070 #define DYNAMIC_TOPIC_TF(src) m = new TFManager(n, port, src, false) ; \
00071 w->addManager("/tf", m); port++;
00072
00073 #define SHAPESHIFTER(name,src,dest) m = new ShapeShifterManager (n, port, std::string(name), src, dest,false); \
00074 w->addManager(name, m); port++;
00075
00076 #define BEGIN_TOPIC_DEFINITION void define_objects(ros::NodeHandle * n, WMPNodeManager * w){ Manager * m; int port = 4;
00077
00078 #define END_TOPIC_DEFINITION }
00079
00080 #endif