API Guides > ConceptRT 3.x
ConceptContainer Class Referenceabstract

Concept container. A container that can contain others ConceptElement. More...

Detailed Description

Concept container. A container that can contain others ConceptElement.

+ Inheritance diagram for ConceptContainer:

Public Member Methods

const bool & GetIsXmlPropertyVisible () const
 Show the xml field in the invocation. More...
 
const bool & GetIsXmlPropertyVisible ()
 Show the xml field in the invocation. More...
 
void SetIsXmlPropertyVisible (const bool &value)
 Show the xml field in the invocation. More...
 
const bool & GetIsXmlPropertyReadOnly () const
 Control access on the xml file shown in the invocation. More...
 
const bool & GetIsXmlPropertyReadOnly ()
 Control access on the xml file shown in the invocation. More...
 
void SetIsXmlPropertyReadOnly (const bool &value)
 Control access on the xml file shown in the invocation. More...
 
 ConceptContainer ()
 Default constructor. More...
 
 ~ConceptContainer ()
 Destructor. More...
 
virtual void Clear ()=0
 Clears the content of this container. More...
 
bool Contains (ConceptElement &element) const
 Query if this object contains the given element. More...
 
void ResolveLinks ()
 Resolve links. More...
 
void Invoke (const DynamicInvocationRequest &request, DynamicInvocationResult &result)
 Invokes the object fields and methods. More...
 
ConceptElementFind (const PCChar8 path) const
 Searches into the container and sub-containers an element. More...
 
void Accept (IContainerVisitor &visitor)
 Accepts IContainerVisitor to access the object published fields. More...
 
virtual ConceptElementFindByName (const PCChar8 name) const
 Searches into the container an element. More...
 
template<class ElementSubType >
ElementSubType * FindByName (const PCChar8 name) const
 Searches into the container an element of a certain type. More...
 
void RetrieveProvidedFactories (BaseConceptFactories &factories, const Predicate< BaseConceptFactory & > &filter)
 Retrieve provided factories. More...
 
void RetrieveProvidedFactories (BaseConceptFactories &factories)
 RetrieveProvidedFactories. More...
 
void RetrieveFactories (BaseConceptFactories &factories) const
 Retrieve factories. More...
 
- Public Member Methods inherited from ConceptElement
const bool & GetIsInvocable () const
 Controls if the objet should be shown in the invocation. More...
 
const bool & GetIsInvocable ()
 Controls if the objet should be shown in the invocation. More...
 
void SetIsInvocable (const bool &value)
 Controls if the objet should be shown in the invocation. More...
 
const bool & GetIsSerialized () const
 Controls if the objet should be serialized. More...
 
const bool & GetIsSerialized ()
 Controls if the objet should be serialized. More...
 
void SetIsSerialized (const bool &value)
 Controls if the objet should be serialized. More...
 
 ConceptElement ()
 Default constructor. More...
 
 ConceptElement (const ConceptElement &right)
 Default constructor. More...
 
ConceptElementoperator= (const ConceptElement &right)
 Assignment operator. More...
 
const StaticString< ConceptElementNameMaxLength > & GetName () const
 Gets the name. More...
 
void SetName (const PCChar8 name)
 Sets a name. More...
 
String GetPath () const
 Gets the path of the ConceptElement. More...
 
ConceptContainerGetContainer () const
 Gets the container of the ConceptElement. More...
 
template<class ContainerType >
ContainerType * GetContainerOfType () const
 Gets the container of a certain type the ConceptElement. More...
 
ConceptContainerGetRootContainer () const
 Gets the root container of the ConceptElement. More...
 
virtual const String GetDisplayName () const
 Gets the display name. More...
 
virtual void CopyDataFrom (const ConceptElement &source)
 Copies the data from another ConceptElement. More...
 
virtual void CopyFrom (const ConceptElement &source)
 Copies itself from a given source. More...
 
virtual void ReadFrom (IDataStore &dataStore, IMessageCollector *messages=NULL)=0
 Reads from. More...
 
virtual void WriteTo (IDataStore &dataStore) const =0
 Writes to. More...
 
virtual BaseConceptFactoryGetFactory () const =0
 Gets the ConceptElement factory. More...
 
ConceptElementGetProvider () const
 Gets the provider of the ConceptElement if defined, throws a ConceptException otherwise. More...
 
template<class T >
T & GetProvider () const
 Gets the provider of the ConceptElement if defined and of type T, throws a ConceptException otherwise. More...
 
bool GetHasProvider () const
 Tests the existence of a provider. More...
 
template<class T >
bool GetHasProvider () const
 Tests the existence of a provider of type T. More...
 
virtual ConceptElementClone () const
 Makes a deep copy of this object. More...
 
void RetrieveProvidedFactories (BaseConceptFactories &factories)
 Retrieve provided factories. More...
 
Variant GetPropertyMetaData (PCChar8 propertyName, PCChar8 metaDataName, const Variant &defaultValue=Variant::GetVariantNull()) const
 Returns a metadata string corresponding to a property and a metadata name. More...
 

Protected Member Functions

virtual Int32 Add (ConceptElement &element)
 Adds element. More...
 
virtual Int32 Add (ConceptElement &element, const PCChar8 name)
 Adds element. More...
 
- Protected Member Functions inherited from ConceptElement
void Initialize ()
 Initializes this object. More...
 
virtual BaseConceptFactoryInternalGetFactory () const
 Gets the object factory. More...
 
virtual void RetrieveElementProvidedFactories (BaseConceptFactories &factories, const Predicate< BaseConceptFactory & > &filter)
 RetrieveElementProvidedFactories. Used by the macro CONCEPT_PROVIDED_COMPONENT_BEGIN More...
 

Private fields

bool IsXmlPropertyVisible
 Show the xml field in the invocation. More...
 
bool IsXmlPropertyReadOnly
 Control access on the xml file shown in the invocation. More...
 

Constructor & Destructor Documentation

Default constructor.

Destructor.

Methods Documentation

virtual Int32 Add ( ConceptElement element)
protectedvirtual

Adds element.

Parameters
element[in,out] The ConceptElement& to add.
Returns
Position index of the added element.
Warning
Non-Deterministic: The inner list of elements may be extended that may lead to memory allocation. Determinism when using ConceptRT library can be ensure by using Context Time Critical mechanisms.

Reimplemented in ConceptDynamicComponent< ElementType >, and ConceptList.

virtual Int32 Add ( ConceptElement element,
const PCChar8  name 
)
protectedvirtual

Adds element.

Parameters
element[in,out] The ConceptElement& to add.
nameThe element's name.
Returns
Position index of the added element.
Warning
Non-Deterministic: The inner list of elements may be extended that may lead to memory allocation. Determinism when using ConceptRT library can be ensure by using Context Time Critical mechanisms.

Reimplemented in ConceptList.

virtual void Clear ( )
pure virtual

Clears the content of this container.

Warning
Non-Deterministic: Deletion of content will remove items from the heap. Determinism when using ConceptRT library can be ensure by using Context Time Critical mechanisms.

Implemented in AcquisitionSystem, ConceptDynamicComponent< ElementType >, ConceptList, ConceptComponent, and BaseConceptStaticList.

bool Contains ( ConceptElement element) const

Query if this object contains the given element.

Parameters
element[in,out] The ConceptElement& that may be contained.
Returns
true if the object is in this container, false if not.
ConceptElement* Find ( const PCChar8  path) const

Searches into the container and sub-containers an element.

Parameters
pathPath of the reserched element
Returns
null if it fails, else return the found element.
virtual ConceptElement* FindByName ( const PCChar8  name) const
virtual

Searches into the container an element.

Parameters
nameThe element's name.
Returns
null if it fails, else the found element.
ElementSubType * FindByName ( const PCChar8  name) const

Searches into the container an element of a certain type.

Template Parameters
ElementSubTypeExepected element type.
Parameters
nameThe element's name.
Returns
null if it fails, else the found element. Returns null also if the element is not of the base type of ElementSubType.

Return directly the found element in the expected type.

const bool & GetIsXmlPropertyReadOnly ( )
inline

Control access on the xml file shown in the invocation.

If the value is turn false, the xml field will be writable. By default the xml field is readOnly (true).

Returns
the property value
See also
Field: IsXmlPropertyReadOnly
Setter: SetIsXmlPropertyReadOnly()
const bool & GetIsXmlPropertyReadOnly ( ) const
inline

Control access on the xml file shown in the invocation.

If the value is turn false, the xml field will be writable. By default the xml field is readOnly (true).

Returns
the property value
See also
Field: IsXmlPropertyReadOnly
Setter: SetIsXmlPropertyReadOnly()
const bool & GetIsXmlPropertyVisible ( )
inline

Show the xml field in the invocation.

Display the object content (properties and children that are serializable) in XML format. By default this value is set to false.

Returns
the property value
See also
Field: IsXmlPropertyVisible
Setter: SetIsXmlPropertyVisible()
const bool & GetIsXmlPropertyVisible ( ) const
inline

Show the xml field in the invocation.

Display the object content (properties and children that are serializable) in XML format. By default this value is set to false.

Returns
the property value
See also
Field: IsXmlPropertyVisible
Setter: SetIsXmlPropertyVisible()
void Invoke ( const DynamicInvocationRequest request,
DynamicInvocationResult result 
)
virtual

Invokes the object fields and methods.

Parameters
requestThe request.
result[in,out] The result.

Dynamic Invocation on IInvocable objects enables us to have remote access on published fields and methods.

Implements ConceptElement.

Reimplemented in AcquisitionSystemRT< AcquitisionBufferSize, LoggerBufferSize, MemoryRootBufferSize >, AcquisitionSystem, AcquisitionChannel, and IoTechnology.

void ResolveLinks ( )
virtual

Resolve links.

Reimplemented from ConceptElement.

Reimplemented in IoMappingSimulationItemSync, and IoMappingChannelItemSync.

void RetrieveFactories ( BaseConceptFactories factories) const
virtual

Retrieve factories.

Parameters
factories[in, out] factories list to populate.

Reimplemented from ConceptElement.

void RetrieveProvidedFactories ( BaseConceptFactories factories,
const Predicate< BaseConceptFactory & > &  filter 
)
virtual

Retrieve provided factories.

Parameters
factories[in, out] factories list
filterfilter that makes the selection of the corresponding factories through Predicate pattern possible.

Reimplemented from ConceptElement.

void RetrieveProvidedFactories ( BaseConceptFactories factories)

RetrieveProvidedFactories.

Parameters
factories[in, out] factories list
void SetIsXmlPropertyReadOnly ( const bool &  value)
inline

Control access on the xml file shown in the invocation.

If the value is turn false, the xml field will be writable. By default the xml field is readOnly (true).

Parameters
[in]valueThe new parameter value.
Returns
the property value
See also
Field: IsXmlPropertyReadOnly
Getter: GetIsXmlPropertyReadOnly()
void SetIsXmlPropertyVisible ( const bool &  value)
inline

Show the xml field in the invocation.

Display the object content (properties and children that are serializable) in XML format. By default this value is set to false.

Parameters
[in]valueThe new parameter value.
Returns
the property value
See also
Field: IsXmlPropertyVisible
Getter: GetIsXmlPropertyVisible()

Fields Documentation

bool IsXmlPropertyReadOnly
private

Control access on the xml file shown in the invocation.

If the value is turn false, the xml field will be writable. By default the xml field is readOnly (true).

See also
Getter: GetIsXmlPropertyReadOnly()
Setter: SetIsXmlPropertyReadOnly()
bool IsXmlPropertyVisible
private

Show the xml field in the invocation.

Display the object content (properties and children that are serializable) in XML format. By default this value is set to false.

See also
Getter: GetIsXmlPropertyVisible()
Setter: SetIsXmlPropertyVisible()