6#ifndef YARP_MANAGER_KBASE
7#define YARP_MANAGER_KBASE
22#define NODELINK_SUPERFICIAL 1
23#define NODELINK_DEEP 2
39 mainApplication(nullptr)
51 char **szAppName_=
nullptr,
52 bool modifyName=
false);
60 bool bAutoDependancy=
false,
bool bSilent=
false);
62 bool bAutoDependancy=
false,
bool bSilent=
false);
142 std::map<std::string, int> appList;
144 bool moduleCompleteness(
Module* module);
145 void updateNodesLink(
Graph& graph,
int level);
146 void makeResourceLinks(
Graph& graph);
147 void updateResourceWeight(
Graph& graph,
153 const char* createDataLabel(
const char* modlabel,
const char* port,
154 const char* postfix=
nullptr);
157 Module* module,
const char* szLabel);
164 bool removeModuleFromGraph(
Graph& graph,
Module* mod);
173 bool bAutoDependancy,
bool bSilent);
175 bool constrainSatisfied(
Node* node,
176 bool bAutoDependancy,
bool bSilent);
178 bool isExternalResource(
Graph& graph,
const char* szName);
179 float calculateLoad(
Computer* comp);
195 std::string strFirst((*f).getName());
196 std::string strSecond((*s).getName());
197 transform(strFirst.begin(), strFirst.end(), strFirst.begin(),
198 (
int(*)(
int))toupper);
199 transform(strSecond.begin(), strSecond.end(), strSecond.begin(),
200 (
int(*)(
int))toupper);
201 return (strFirst.compare(strSecond) < 0);
211 std::string strFirst((*f).getName());
212 std::string strSecond((*s).getName());
213 transform(strFirst.begin(), strFirst.end(), strFirst.begin(),
214 (
int(*)(
int))toupper);
215 transform(strSecond.begin(), strSecond.end(), strSecond.begin(),
216 (
int(*)(
int))toupper);
217 return (strFirst.compare(strSecond) < 0);
227 std::string strFirst(f->
getName());
228 std::string strSecond(s->
getName());
229 transform(strFirst.begin(), strFirst.end(), strFirst.begin(),
230 (
int(*)(
int))toupper);
231 transform(strSecond.begin(), strSecond.end(), strSecond.begin(),
232 (
int(*)(
int))toupper);
233 return (strFirst.compare(strSecond) < 0);
Abstract Class AppLoader.
Class ApplicationInterface.
Node * getNode(const char *szLabel)
Application * addIApplicationToApplication(Application *application, ApplicationInterface &app, bool isNew=false)
const ArbContainer & getArbitrators(Application *parent=nullptr)
const OutputContainer & getOutputCandidates(InputData *input)
Module * getModule(const char *szName)
bool removeModule(Module *module)
const ModulePContainer & getModules(Application *parent=nullptr)
bool removeIModuleFromApplication(Application *application, const char *szTag)
const ApplicaitonPContainer & getSelApplications()
const InputContainer & getInputCandidates(OutputData *output)
const CnnContainer & getSelConnection()
bool updateConnectionOfApplication(Application *application, Connection &prev, Connection &con)
const ModulePContainer & getSelModules()
bool setModulePrefix(Module *module, const char *szPrefix, bool updateBasePrefix=true)
GenericResource * getResource(const char *szName)
bool removeResource(GenericResource *resource)
bool removeConnectionFromApplication(Application *application, Connection &cnn)
Arbitrator & addArbitratorToApplication(Application *application, Arbitrator &arb)
const ResourcePContainer & getSelResources()
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)
Application * getApplication()
Module * addIModuleToApplication(Application *application, ModuleInterface &mod, bool isNew=false)
bool removeIApplicationFromApplication(Application *application, const char *szTag)
bool addModule(Module *module)
const ApplicaitonPContainer & getApplications(Application *parent=nullptr)
Application * getApplication(const char *szName)
bool removeApplication(Application *application)
bool createFrom(ModuleLoader *_mloader, AppLoader *_apploader, ResourceLoader *_resloader)
const CnnContainer & getConnections(Application *parent=nullptr)
const std::string getUniqueAppID(Application *parent, const char *szAppName)
const ResourcePContainer & getResources(Application *parent=nullptr)
bool removeArbitratorFromApplication(Application *application, Arbitrator &arb)
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)
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)