OpenASIP
2.0
|
#include <ResourceMapper.hh>
Public Member Functions | |
ResourceMapper () | |
virtual | ~ResourceMapper () |
void | addResourceMap (const ResourceBroker &broker) |
int | resourceCount (const TTAMachine::MachinePart &mp) const |
SchedulingResource & | resourceOf (const TTAMachine::MachinePart &mp, int index=0) const |
Private Attributes | |
std::vector< const ResourceBroker * > | brokers_ |
Resource brokers. More... | |
Groups together the brokers managed by the resource build director and maps each resource object to corresponding machine parts.
Definition at line 51 of file ResourceMapper.hh.
ResourceMapper::ResourceMapper | ( | ) |
|
virtual |
void ResourceMapper::addResourceMap | ( | const ResourceBroker & | broker | ) |
Register broker as one of the elements that contribute to mapping a subset of machine parts to resources.
broker | Broker to register. |
Definition at line 60 of file ResourceMapper.cc.
References __func__, brokers_, and ContainerTools::containsValue().
Referenced by ResourceBuildDirector::build().
int ResourceMapper::resourceCount | ( | const TTAMachine::MachinePart & | mp | ) | const |
Return the number of resources that correspond to the given machine part.
mp | Machine part. |
Definition at line 76 of file ResourceMapper.cc.
References brokers_.
Referenced by OutputFUBroker::setupResourceLinks(), and InputFUBroker::setupResourceLinks().
SchedulingResource & ResourceMapper::resourceOf | ( | const TTAMachine::MachinePart & | mp, |
int | index = 0 |
||
) | const |
Find the resource object that corresponds to given machine part with index (default 0).
mp | Machine part to find Scheduling Resource for |
index | Index of machine part, in case there are several |
Definition at line 96 of file ResourceMapper.cc.
References __func__, brokers_, and TTAMachine::Component::name().
Referenced by InputFUBroker::allAvailableResources(), ExecutionPipelineBroker::setupResourceLinks(), OutputFUBroker::setupResourceLinks(), InputFUBroker::setupResourceLinks(), OutputPSocketBroker::setupResourceLinks(), ITemplateBroker::setupResourceLinks(), and IUBroker::setupResourceLinks().
|
private |
Resource brokers.
Definition at line 63 of file ResourceMapper.hh.
Referenced by addResourceMap(), resourceCount(), and resourceOf().