OpenASIP
2.0
|
#include <OperationModule.hh>
Public Member Functions | |
OperationModule (const std::string &name, const std::string &path) | |
OperationModule (const OperationModule &om) | |
virtual | ~OperationModule () |
OperationModule & | operator= (const OperationModule &om) |
virtual std::string | name () const |
virtual bool | definesBehavior () const |
virtual std::string | behaviorModule () const |
virtual std::string | propertiesModule () const |
virtual bool | hasBehaviorSource () const |
virtual std::string | behaviorSourceModule () const |
Private Member Functions | |
std::string | propertyFileName () const |
std::string | behaviorFileName () const |
std::string | behaviorSourceFileName () const |
Private Attributes | |
std::string | path_ |
The path of the module. More... | |
std::string | name_ |
The name of the module. More... | |
Static Private Attributes | |
static const std::string | PROPERTY_FILE_EXTENSION = ".opp" |
File extension of operation property file. More... | |
static const std::string | BEHAVIOR_FILE_EXTENSION = ".opb" |
File extension of operation behavior file. More... | |
static const std::string | BEHAVIOR_SOURCE_FILE_EXTENSION = ".cc" |
File extension of operation behavior source file. More... | |
Class that represents the name and the path of external files where Operation definitions are stored.
Definition at line 46 of file OperationModule.hh.
OperationModule::OperationModule | ( | const std::string & | name, |
const std::string & | path | ||
) |
Constructor.
name | The name of the module. |
path | The path of the module. |
Definition at line 54 of file OperationModule.cc.
OperationModule::OperationModule | ( | const OperationModule & | om | ) |
Copy constructor.
om | The module to be copied. |
Definition at line 64 of file OperationModule.cc.
References FileSystem::directoryOfPath(), name(), name_, path_, and propertiesModule().
|
virtual |
|
private |
Returns the name of the behavior file name.
Definition at line 170 of file OperationModule.cc.
References BEHAVIOR_FILE_EXTENSION, and name_.
Referenced by behaviorModule(), and definesBehavior().
|
virtual |
Returns the name of the behavior module.
FileNotFound | If behavior module is not found. |
Reimplemented in NullOperationModule.
Definition at line 105 of file OperationModule.cc.
References behaviorFileName(), definesBehavior(), FileSystem::DIRECTORY_SEPARATOR, and path_.
Referenced by OSEdRemoveModuleCmd::Do(), and OperationBehaviorLoader::importBehavior().
|
private |
Returns the name of the code file.
Definition at line 190 of file OperationModule.cc.
References BEHAVIOR_SOURCE_FILE_EXTENSION, and name_.
Referenced by behaviorSourceModule(), and hasBehaviorSource().
|
virtual |
Returns the name of the behavior source code file.
FileNotFound | If behavior source file not found. |
Reimplemented in NullOperationModule.
Definition at line 144 of file OperationModule.cc.
References behaviorSourceFileName(), FileSystem::DIRECTORY_SEPARATOR, hasBehaviorSource(), and path_.
Referenced by OSEdBuildAllCmd::Do(), OSEdRemoveModuleCmd::Do(), OSEdModifyBehaviorCmd::Do(), OSEdBuildCmd::Do(), and OperationPropertyDialog::onOpen().
|
virtual |
Checks whether OperationModule has behavior definition file.
Reimplemented in NullOperationModule.
Definition at line 93 of file OperationModule.cc.
References behaviorFileName(), FileSystem::DIRECTORY_SEPARATOR, FileSystem::fileExists(), and path_.
Referenced by behaviorModule(), and OSEdRemoveModuleCmd::Do().
|
virtual |
Checks whether module has behavior source file.
Reimplemented in NullOperationModule.
Definition at line 131 of file OperationModule.cc.
References behaviorSourceFileName(), FileSystem::DIRECTORY_SEPARATOR, FileSystem::fileExists(), and path_.
Referenced by behaviorSourceModule(), OperationPropertyDialog::createContents(), OSEdRemoveModuleCmd::Do(), OSEdModifyBehaviorCmd::Do(), OSEdBuildAllCmd::Do(), OSEdBuildCmd::isEnabled(), OSEdBuildAllCmd::isEnabled(), OperationPropertyDialog::onOpen(), and OperationPropertyDialog::setBehaviorLabel().
|
virtual |
Returns the name of the module.
Reimplemented in NullOperationModule.
Definition at line 160 of file OperationModule.cc.
References name_.
Referenced by OSEdTreeView::constructTree(), OSEdAddModuleCmd::Do(), OSEdBuildAllCmd::Do(), OSEdBuildCmd::Do(), OperationContainer::module(), OSEdInfoView::moduleView(), OperationModule(), operator=(), and OperationPropertyDialog::updateOperation().
OperationModule & OperationModule::operator= | ( | const OperationModule & | om | ) |
Assignment operator.
om | Module to be assigned. |
Definition at line 81 of file OperationModule.cc.
References FileSystem::directoryOfPath(), name(), name_, path_, and propertiesModule().
|
virtual |
Returns the name of the properties module.
Reimplemented in NullOperationModule.
Definition at line 121 of file OperationModule.cc.
References FileSystem::DIRECTORY_SEPARATOR, path_, and propertyFileName().
Referenced by OSEdTreeView::constructTree(), OSEdRemoveOperationCmd::Do(), OSEdAddModuleCmd::Do(), OSEdPropertiesCmd::Do(), OSEdRemoveModuleCmd::Do(), OSEdAddOperationCmd::Do(), OSEdModifyBehaviorCmd::Do(), OperationIndex::effectiveOperation(), OperationPropertyLoader::loadModule(), OperationPropertyLoader::loadOperationProperties(), OperationPropertyDialog::onOpen(), OperationContainer::operation(), OperationIndex::operationCount(), OperationModule(), OperationIndex::operationName(), operator=(), OperationIndex::readOperations(), OperationIndex::refreshModule(), and OperationIndex::removeModule().
|
private |
Returns the name of the properties file.
Definition at line 180 of file OperationModule.cc.
References name_, and PROPERTY_FILE_EXTENSION.
Referenced by propertiesModule().
|
staticprivate |
File extension of operation behavior file.
Behavior file extension.
Definition at line 70 of file OperationModule.hh.
Referenced by behaviorFileName().
|
staticprivate |
File extension of operation behavior source file.
Source file extension.
Definition at line 72 of file OperationModule.hh.
Referenced by behaviorSourceFileName().
|
private |
The name of the module.
Definition at line 77 of file OperationModule.hh.
Referenced by behaviorFileName(), behaviorSourceFileName(), name(), OperationModule(), operator=(), and propertyFileName().
|
private |
The path of the module.
Definition at line 75 of file OperationModule.hh.
Referenced by behaviorModule(), behaviorSourceModule(), definesBehavior(), hasBehaviorSource(), OperationModule(), operator=(), and propertiesModule().
|
staticprivate |
File extension of operation property file.
Property file extension.
Definition at line 68 of file OperationModule.hh.
Referenced by propertyFileName().