6 #ifndef YARP_MANAGER_KBASE
7 #define YARP_MANAGER_KBASE
23 #define NODELINK_SUPERFICIAL 1
24 #define NODELINK_DEEP 2
40 mainApplication(nullptr)
52 char **szAppName_=
nullptr,
53 bool modifyName=
false);
61 bool bAutoDependancy=
false,
bool bSilent=
false);
63 bool bAutoDependancy=
false,
bool bSilent=
false);
143 std::map<std::string, int> appList;
146 void updateNodesLink(
Graph& graph,
int level);
147 void makeResourceLinks(
Graph& graph);
148 void updateResourceWeight(
Graph& graph,
154 const char* createDataLabel(
const char* modlabel,
const char* port,
155 const char* postfix=
nullptr);
165 bool removeModuleFromGraph(
Graph& graph,
Module* mod);
174 bool bAutoDependancy,
bool bSilent);
176 bool constrainSatisfied(
Node* node,
177 bool bAutoDependancy,
bool bSilent);
179 bool isExternalResource(
Graph& graph,
const char* szName);
180 float calculateLoad(
Computer* comp);
196 std::string strFirst((*f).getName());
197 std::string strSecond((*s).getName());
198 transform(strFirst.begin(), strFirst.end(), strFirst.begin(),
199 (
int(*)(
int))toupper);
200 transform(strSecond.begin(), strSecond.end(), strSecond.begin(),
201 (
int(*)(
int))toupper);
202 return (strFirst.compare(strSecond) < 0);
212 std::string strFirst((*f).getName());
213 std::string strSecond((*s).getName());
214 transform(strFirst.begin(), strFirst.end(), strFirst.begin(),
215 (
int(*)(
int))toupper);
216 transform(strSecond.begin(), strSecond.end(), strSecond.begin(),
217 (
int(*)(
int))toupper);
218 return (strFirst.compare(strSecond) < 0);
228 std::string strFirst(f->
getName());
229 std::string strSecond(s->
getName());
230 transform(strFirst.begin(), strFirst.end(), strFirst.begin(),
231 (
int(*)(
int))toupper);
232 transform(strSecond.begin(), strSecond.end(), strSecond.begin(),
233 (
int(*)(
int))toupper);
234 return (strFirst.compare(strSecond) < 0);
Abstract Class AppLoader.
Class ApplicationInterface.
Node * getNode(const char *szLabel)
Application * addIApplicationToApplication(Application *application, ApplicationInterface &app, bool isNew=false)
GenericResource * getResource(const char *szName)
const ArbContainer & getArbitrators(Application *parent=nullptr)
const OutputContainer & getOutputCandidates(InputData *input)
bool removeModule(Module *module)
const ModulePContainer & getModules(Application *parent=nullptr)
bool removeIModuleFromApplication(Application *application, const char *szTag)
Application * getApplication(const char *szName)
const InputContainer & getInputCandidates(OutputData *output)
bool updateConnectionOfApplication(Application *application, Connection &prev, Connection &con)
bool setModulePrefix(Module *module, const char *szPrefix, bool updateBasePrefix=true)
bool removeResource(GenericResource *resource)
bool removeConnectionFromApplication(Application *application, Connection &cnn)
Arbitrator & addArbitratorToApplication(Application *application, Arbitrator &arb)
Module * getModule(const char *szName)
bool reasolveDependency(const char *szName, bool bAutoDependancy=false, bool bSilent=false)
bool exportAppGraph(const char *szFileName)
bool addResource(GenericResource *resource)
Connection & addConnectionToApplication(Application *application, Connection &cnn)
Node * getNode(std::string appName)
Module * addIModuleToApplication(Application *application, ModuleInterface &mod, bool isNew=false)
bool removeIApplicationFromApplication(Application *application, const char *szTag)
const ResourcePContainer & getSelResources()
bool addModule(Module *module)
const ApplicaitonPContainer & getApplications(Application *parent=nullptr)
bool removeApplication(Application *application)
Application * getApplication()
bool createFrom(ModuleLoader *_mloader, AppLoader *_apploader, ResourceLoader *_resloader)
const CnnContainer & getConnections(Application *parent=nullptr)
const std::string getUniqueAppID(Application *parent, const char *szAppName)
const ApplicaitonPContainer & getSelApplications()
const ResourcePContainer & getResources(Application *parent=nullptr)
bool removeArbitratorFromApplication(Application *application, Arbitrator &arb)
const CnnContainer & getSelConnection()
bool setApplicationPrefix(Application *app, const char *szPrefix, bool updateBasePref=true)
bool exportKbGraph(const char *szFileName)
bool addApplication(Application *application, char **szAppName_=nullptr, bool modifyName=false)
const ModulePContainer & getSelModules()
bool saveApplication(AppSaver *appSaver, Application *application)
Abstract Class ModuleLoader.
Abstract Class ResourceLoader.
bool operator()(Application *f, Application *s)
bool operator()(Module *f, Module *s)
bool operator()(GenericResource *f, GenericResource *s)
std::vector< InputData > InputContainer
std::vector< Node * > NodePVector
std::vector< Arbitrator > ArbContainer
std::vector< Node * >::iterator NodePVIterator
std::vector< OutputData > OutputContainer
std::vector< Module * > ModulePContainer
std::vector< GenericResource * > ResourcePContainer
std::vector< Application * > ApplicaitonPContainer
std::vector< Connection > CnnContainer
bool exportDotGraph(Graph &graph, const char *szFileName)
The main, catch-all namespace for YARP.