FSMSADF::Channel Class Reference
#include <channel.h>
Detailed Description
class Channel Channel in an FSM-based SADF graph.
Constructor & Destructor Documentation
FSMSADF::Channel::Channel | ( | GraphComponent | c | ) |
FSMSADF::Channel::~Channel | ( | ) |
~Channel () Destructor.
Member Function Documentation
Channel * FSMSADF::Channel::clone | ( | GraphComponent | c | ) | const |
clone () The function returns a pointer to a newly allocated channel object. All properties and the connection of the channel are cloned.
References connectDst(), connectSrc(), createCopy(), FSMSADF::ScenarioGraph::getActor(), getDstActor(), getDstPort(), FSMSADF::GraphComponent::getName(), FSMSADF::Actor::getPort(), getScenarioGraph(), getSrcActor(), getSrcPort(), and scPersistentTokenNames.
Referenced by FSMSADF::ScenarioBindingConstraints::clone().
void FSMSADF::Channel::connectDst | ( | Port * | p | ) |
connectDst () The function connects the channel to a destination port and port to channel.
References FSMSADF::Port::connectToChannel(), dst, getDstPort(), FSMSADF::GraphComponent::getName(), FSMSADF::Port::getType(), and FSMSADF::Port::getTypeAsString().
Referenced by clone(), constructFromXML(), FSMSADF::ScenarioGraph::createChannel(), and FSMSADF::RandomGraph::createChannel().
void FSMSADF::Channel::connectSrc | ( | Port * | p | ) |
connectSrc () The function connects the channel to a source port and port to channel.
References FSMSADF::Port::connectToChannel(), FSMSADF::GraphComponent::getName(), getSrcPort(), FSMSADF::Port::getType(), FSMSADF::Port::getTypeAsString(), and src.
Referenced by clone(), constructFromXML(), FSMSADF::ScenarioGraph::createChannel(), and FSMSADF::RandomGraph::createChannel().
void FSMSADF::Channel::constructFromXML | ( | const CNodePtr | channelNode | ) |
constructFromXML () The function initializes all basic channel properties based on the XML data.
References c, CGetAttribute(), CHasAttribute(), connectDst(), connectSrc(), g, FSMSADF::ScenarioGraph::getActor(), FSMSADF::Actor::getPort(), getScenarioGraph(), initialTokens, scPersistentTokenNames, setInitialTokens(), FSMSADF::GraphComponent::setName(), and CString::split().
Referenced by FSMSADF::ScenarioGraph::constructFromXML().
void FSMSADF::Channel::constructPropertiesFromXML | ( | Scenario * | s, | |
const CNodePtr | channelPropertiesNode | |||
) |
constructPropertiesFromXML () The function initializes all channel properties based on the XML data.
References CGetAttribute(), CGetChildNode(), CHasAttribute(), CHasChildNode(), and setTokenSizeOfScenario().
Referenced by FSMSADF::ScenarioGraph::constructPropertiesFromXML().
void FSMSADF::Channel::convertPropertiesToXML | ( | Scenario * | s, | |
const CNodePtr | channelPropertiesNode | |||
) |
convertPropertiesToXML () The function converts all channel properties to XML data.
References CAddAttribute(), CAddNode(), FSMSADF::GraphComponent::getName(), getTokenSizeOfScenario(), and tokenSize.
void FSMSADF::Channel::convertToXML | ( | const CNodePtr | channelNode | ) |
convertToXML () The function converts all basic channel properties to XML data.
References CAddAttribute(), getDstActor(), getDstPort(), getInitialTokens(), FSMSADF::GraphComponent::getName(), getSrcActor(), getSrcPort(), CString::join(), and scPersistentTokenNames.
Channel * FSMSADF::Channel::create | ( | GraphComponent | c | ) | const |
create () The function returns a pointer to a newly allocated channel object.
References Channel().
Referenced by createCopy().
Channel * FSMSADF::Channel::createCopy | ( | GraphComponent | c | ) | const |
createCopy () The function returns a pointer to a newly allocated channel object. All properties of the channel are copied.
References create(), getInitialTokens(), FSMSADF::GraphComponent::getName(), getTokenSize(), setInitialTokens(), FSMSADF::GraphComponent::setName(), and setTokenSize().
Referenced by clone().
Scenario * FSMSADF::Channel::getDefaultScenario | ( | ) | const [private] |
getDefaultScenario () The function returns a pointer to the default scenario.
References FSMSADF::Graph::getDefaultScenario(), FSMSADF::ScenarioGraph::getGraph(), and getScenarioGraph().
Referenced by getTokenSizeOfScenario(), and hasTokenSizeInScenario().
Actor* FSMSADF::Channel::getDstActor | ( | ) | const [inline] |
References dst, and getDstPort().
Referenced by FSMSADF::RandomGraph::assignInitialTokensToChannels(), FSMSADF::RandomGraph::assignRatesAndInitialTokens(), FSMSADF::RandomGraph::assignRatesToPorts(), clone(), FSMSADF::OutputHTML::convertPlatformBindingToPNG(), FSMSADF::OutputHTML::convertScenarioGraphToPNG(), convertToXML(), FSMSADF::BindingAwareGraph::createMappedChannelToConnectionNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToTileNSoC(), FSMSADF::RandomGraph::dfsStronglyConnected(), FSMSADF::GraphConversion::ensureStronglyBounded(), FSMSADF::ScenarioGraph::extractSDFgraph(), FSMSADF::RandomGraph::findCycles(), FSMSADF::RandomGraph::getChannelsBetweenActors(), FSMSADF::PrecedenceGraph::PrecedenceGraph(), print(), FSMSADF::OutputHTML::printScenario(), and FSMSADF::RandomGraph::selectInitialTokenChannels().
Port* FSMSADF::Channel::getDstPort | ( | ) | const [inline] |
References dst.
Referenced by FSMSADF::RandomGraph::assignRatesToPorts(), FSMSADF::calcFractionsConnectedActors(), clone(), connectDst(), convertToXML(), FSMSADF::BindingAwareGraph::createMappedActorNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToConnectionNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToTileNSoC(), FSMSADF::GraphConversion::ensureStronglyBounded(), FSMSADF::MemoryDimAlgo::estimateStorageDist(), FSMSADF::ScenarioGraph::extractSDFgraph(), getDstActor(), isConnected(), FSMSADF::PrecedenceGraph::PrecedenceGraph(), print(), and FSMSADF::OutputHTML::printScenario().
uint FSMSADF::Channel::getInitialTokens | ( | ) | const [inline] |
References initialTokens.
Referenced by FSMSADF::RandomGraph::assignInitialTokensToChannels(), FSMSADF::ScenarioGraph::constructFromXML(), FSMSADF::MPExplore::Exploration::convertEigenvector(), FSMSADF::OutputHTML::convertPlatformBindingToPNG(), FSMSADF::OutputHTML::convertScenarioGraphToPNG(), convertToXML(), createCopy(), FSMSADF::BindingAwareGraph::createMappedChannelToConnectionNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToTileNSoC(), FSMSADF::GraphConversion::ensureStronglyBounded(), FSMSADF::MemoryDimAlgo::estimateStorageDist(), FSMSADF::ScenarioGraph::extractSDFgraph(), FSMSADF::MPExplore::State::fromVector(), FSMSADF::PrecedenceGraph::PrecedenceGraph(), print(), FSMSADF::OutputHTML::printScenario(), FSMSADF::MPExploreBindingAware::SGraph::SGraph(), FSMSADF::MPExplore::SGraph::SGraph(), FSMSADF::MPExplore::State::zeroScheduleState(), and FSMSADF::MPExplore::State::zeroState().
CStrings FSMSADF::Channel::getPersistentTokenNames | ( | ) | const [inline] |
References scPersistentTokenNames.
Referenced by FSMSADF::ScenarioGraph::constructFromXML().
ScenarioGraph* FSMSADF::Channel::getScenarioGraph | ( | ) | const [inline] |
References FSMSADF::GraphComponent::getParent().
Referenced by clone(), constructFromXML(), FSMSADF::BindingAwareGraph::createMappedChannelToConnectionNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToTileNSoC(), getDefaultScenario(), and setTokenSize().
Actor* FSMSADF::Channel::getSrcActor | ( | ) | const [inline] |
References getSrcPort(), and src.
Referenced by FSMSADF::RandomGraph::assignInitialTokensToChannels(), FSMSADF::RandomGraph::assignRatesAndInitialTokens(), FSMSADF::RandomGraph::assignRatesToPorts(), clone(), FSMSADF::OutputHTML::convertPlatformBindingToPNG(), FSMSADF::OutputHTML::convertScenarioGraphToPNG(), convertToXML(), FSMSADF::BindingAwareGraph::createMappedChannelToConnectionNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToTileNSoC(), FSMSADF::RandomGraph::dfsStronglyConnected(), FSMSADF::GraphConversion::ensureStronglyBounded(), FSMSADF::ScenarioGraph::extractSDFgraph(), FSMSADF::RandomGraph::findCycles(), FSMSADF::PrecedenceGraph::PrecedenceGraph(), print(), FSMSADF::OutputHTML::printScenario(), FSMSADF::RandomGraph::selectInitialTokenChannels(), FSMSADF::MPExploreBindingAware::SGraph::SGraph(), and FSMSADF::MPExplore::SGraph::SGraph().
Port* FSMSADF::Channel::getSrcPort | ( | ) | const [inline] |
References src.
Referenced by FSMSADF::RandomGraph::assignRatesToPorts(), FSMSADF::calcFractionsConnectedActors(), clone(), connectSrc(), convertToXML(), FSMSADF::BindingAwareGraph::createMappedActorNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToConnectionNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToTileNSoC(), FSMSADF::GraphConversion::ensureStronglyBounded(), FSMSADF::MemoryDimAlgo::estimateStorageDist(), FSMSADF::ScenarioGraph::extractSDFgraph(), getSrcActor(), isConnected(), FSMSADF::PrecedenceGraph::PrecedenceGraph(), print(), FSMSADF::OutputHTML::printScenario(), FSMSADF::MPExploreBindingAware::SGraph::SGraph(), and FSMSADF::MPExplore::SGraph::SGraph().
References tokenSize.
Referenced by createCopy().
getTokenSizeOfScenario () The function returns the token size of a token send on this channel in scenario s. When no token size has been specified for this scenario, the default scenario is checked. When also no default scenario exists, an exception is thrown.
References getDefaultScenario(), FSMSADF::GraphComponent::getName(), and tokenSize.
Referenced by convertPropertiesToXML(), FSMSADF::BindingAwareGraph::createMappedChannelToConnectionNSoC(), isolateScenario(), and FSMSADF::OutputHTML::printScenario().
bool FSMSADF::Channel::hasTokenSizeInScenario | ( | Scenario * | s | ) | const |
hasTokenSizeInScenario () The function returns true when a token size has been specified for scenario s or through a default scenario. Otherwise the function returns false.
References getDefaultScenario(), and tokenSize.
Referenced by isolateScenario().
bool FSMSADF::Channel::isConnected | ( | ) | const |
isConnected () The function returns true if the channel is connected to a source and destination port.
References getDstPort(), and getSrcPort().
Referenced by print().
void FSMSADF::Channel::isolateScenario | ( | Scenario * | s | ) |
isolateScenario() The function removes all scenario except scenario s from the channel.
References getTokenSizeOfScenario(), hasTokenSizeInScenario(), setTokenSizeOfScenario(), and tokenSize.
Referenced by FSMSADF::ScenarioGraph::isolateScenario().
ostream & FSMSADF::Channel::print | ( | ostream & | out | ) |
print () Print the channel to the supplied output stream.
References getDstActor(), getDstPort(), FSMSADF::GraphComponent::getId(), getInitialTokens(), FSMSADF::GraphComponent::getName(), getSrcActor(), getSrcPort(), and isConnected().
Referenced by FSMSADF::ScenarioGraph::print().
void FSMSADF::Channel::setInitialTokens | ( | const uint | t | ) | [inline] |
References initialTokens.
Referenced by FSMSADF::RandomGraph::assignInitialTokensToChannels(), constructFromXML(), createCopy(), FSMSADF::BindingAwareGraph::createMappedActorNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToConnectionNSoC(), FSMSADF::BindingAwareGraph::createMappedChannelToTileNSoC(), and FSMSADF::GraphConversion::ensureStronglyBounded().
setTokenSize () The function sets the token size of all scenarios.
References FSMSADF::ScenarioGraph::getGraph(), FSMSADF::Graph::getScenario(), getScenarioGraph(), setTokenSizeOfScenario(), and tokenSize.
Referenced by createCopy().
setTokenSizeOfScenario () Set the token size of scenario s.
References tokenSize.
Referenced by FSMSADF::RandomGraph::assignChannelProperties(), constructPropertiesFromXML(), isolateScenario(), and setTokenSize().
Friends And Related Function Documentation
ostream& operator<< | ( | ostream & | out, | |
Channel & | c | |||
) | [friend] |
Member Data Documentation
Port* FSMSADF::Channel::dst [private] |
Referenced by connectDst(), getDstActor(), getDstPort(), and oppositePort().
uint FSMSADF::Channel::initialTokens [private] |
Referenced by constructFromXML(), getInitialTokens(), and setInitialTokens().
Referenced by clone(), constructFromXML(), convertToXML(), and getPersistentTokenNames().
Port* FSMSADF::Channel::src [private] |
Referenced by connectSrc(), getSrcActor(), getSrcPort(), and oppositePort().
map<Scenario*, Size> FSMSADF::Channel::tokenSize [private] |
The documentation for this class was generated from the following files: