![]() |
Carousel
|
This class describes the component meta information. More...
#include <ComponentDefinition.h>
Static Public Member Functions | |
static QString | defaultProvider () |
This class describes the component meta information.
This class is used in the Components dialog to provide to user information about the component.
This class also specified that the current component has dependencies on another ones - on its 'parents'.
ComponentDefinition::ComponentDefinition | ( | ) |
Initializes a new instance of the ComponentDefinition class.
ComponentDefinition::ComponentDefinition | ( | const QString & | componentName, |
bool | isBuiltIn | ||
) |
Initializes a new instance of the ComponentDefinition class using specified component name and built-in flag which determines whether component registered statically in code (build-in) or dynamically (on start-time or run-time).
|
static |
Returns default component provider, which is Unknown.
void ComponentDefinition::addParent | ( | ParentDefinition * | parent | ) |
Adds a parent component definition as a dependency for defined component.
IComponent* ComponentDefinition::component | ( | ) | const |
Returns a defined component.
const QString& ComponentDefinition::componentLocation | ( | ) | const |
Returns a component location (for loaded components). It might be absolute or relative path.
Returns empty string for explicitly loaded components (static components).
const QString& ComponentDefinition::shortComponentName | ( | ) | const |
Returns a component short name.
const QString& ComponentDefinition::componentName | ( | ) | const |
Returns a component name.
const QString& ComponentDefinition::definitionLocation | ( | ) | const |
Returns a definition location (for loaded components). It might be absolute or relative path.
Returns empty string for explicitly loaded components (static components).
const QString& ComponentDefinition::description | ( | ) | const |
Gets a detailed description text that is displayed for this component in the About this component box in the Components dialog.
bool ComponentDefinition::isBuiltIn | ( | ) | const |
Gets a flag which determines whether component registered statically in code (build-in) or dynamically (on start-time or run-time).
bool ComponentDefinition::isCompatible | ( | const IComponent * | parent | ) | const |
Returns true if component version is compatible with all parent component versions, e.g. if they are equal. Otherwise, returns false.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
bool ComponentDefinition::isCompatible | ( | const ParentDefinitions & | parents | ) | const |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
const ParentDefinitions& ComponentDefinition::parents | ( | ) | const |
Gets a list of parent (dependent) components names.
const QString& ComponentDefinition::productName | ( | ) | const |
Gets a the name that is displayed for this component in the Components dialog.
const QString& ComponentDefinition::provider | ( | ) | const |
Gets a the name of component's provider, the person or company, who creates this component.
Unknown is by default.
const Version* ComponentDefinition::version | ( | ) | const |
Gets the version of a component.
void ComponentDefinition::setComponent | ( | IComponent * | component | ) |
Sets a component.
void ComponentDefinition::setComponentName | ( | const QString & | name | ) |
Sets the component name. The name should be unique in the application bounadaries, because components with the same name could not be added to the IComponentManager.
void ComponentDefinition::setShortComponentName | ( | const QString & | name | ) |
Sets the component short name. This name will be shown to the user in the components dialog.
void ComponentDefinition::setDescription | ( | const QString & | description | ) |
Sets the component description.
void ComponentDefinition::setProductName | ( | const QString & | productName | ) |
Sets the product name.
void ComponentDefinition::setProvider | ( | const QString & | provider | ) |
Sets the provider name.
void ComponentDefinition::setComponentLocation | ( | const QString & | componentLocation | ) |
Sets the component file location.
void ComponentDefinition::setDefinitionLocation | ( | const QString & | definitionLocation | ) |
Sets the definition file location.
void ComponentDefinition::setVersion | ( | int | major_version, |
int | minor_version, | ||
int | build_version = 0 , |
||
int | revision_version = 0 |
||
) |
Sets the version of a component.
void ComponentDefinition::setVersion | ( | Version * | version | ) |
Sets the version of a component. It takes ownership for the version pointer.