ADTF  3.18.2
Source

the engine source More...

Inheritance diagram for Source:
[legend]

Public Member Functions

 Source (IMappingEnvironment &env)
 CTOR. More...
 
 Source (const Source &)=delete
 no copy CTOR
 
Sourceoperator= (const Source &)=delete
 no copy assignment operator More...
 
 ~Source ()
 DTOR.
 
a_util::result::Result create (const mapping::MapSource &map_source, const std::string &type_description)
 Creation method to fill the object with data. More...
 
a_util::result::Result addAssignment (const ddl::mapping::MapConfiguration &map_config, const std::string &source_element, TargetElement *target_element)
 Method to add a new pair of source element and target element to the intern assignment list. More...
 
a_util::result::Result addTrigger (const MapConfiguration &map_config, TriggerBase *trigger)
 Method to add a new trigger to the intern trigger list. More...
 
a_util::result::Result removeAssignmentsFor (const Target *target)
 Method to remove all elements of a target from the intern assignment list. More...
 
const std::string & getTypeName () const
 Getter for the source type. More...
 
const Assignments & getAssigmentList () const
 Getter for the assignment list. More...
 
a_util::result::Result onSampleReceived (const void *data, size_t size)
 Method to handle a sample when it is received. More...
 
- Public Member Functions inherited from ISignalListener
virtual ~ISignalListener ()
 DTOR.
 

Private Attributes

IMappingEnvironment_env
 
handle_t _handle
 
std::string _name
 
std::string _type_name
 
std::string _type_description
 
Assignments _assignments
 
TargetRefList _targets
 
std::unique_ptr< ddl::codec::CodecFactory_codec_factory
 
TypeMap _type_map
 
TargetElementList _received_elements
 
Triggers _triggers
 

Detailed Description

the engine source

Definition at line 60 of file source.h.

Constructor & Destructor Documentation

◆ Source()

CTOR.

Parameters
[in]envThe mapping environment

Member Function Documentation

◆ addAssignment()

a_util::result::Result addAssignment ( const ddl::mapping::MapConfiguration map_config,
const std::string &  source_element,
TargetElement target_element 
)

Method to add a new pair of source element and target element to the intern assignment list.

Parameters
[in]map_configThe Configuration instance
[in]source_elementThe name of the source element to map
[in]target_elementThe target element instance
Return values
a_util::result::SUCCESSEverything went fine

◆ addTrigger()

a_util::result::Result addTrigger ( const MapConfiguration map_config,
TriggerBase trigger 
)

Method to add a new trigger to the intern trigger list.

Parameters
[in]map_configThe Configuration instance
[in]triggerThe trigger
Return values
a_util::result::SUCCESSEverything went fine

◆ create()

a_util::result::Result create ( const mapping::MapSource map_source,
const std::string &  type_description 
)

Creation method to fill the object with data.

Parameters
[in]map_sourceThe soucre representation from mapping configuration
[in]type_descriptionThe description for the source type
Return values
a_util::result::SUCCESSEverything went fine
ERR_FAILEDError while filing the object

◆ getAssigmentList()

const Assignments& getAssigmentList ( ) const

Getter for the assignment list.

Returns
the assignment list

◆ getTypeName()

const std::string& getTypeName ( ) const

Getter for the source type.

Returns
the source type

◆ onSampleReceived()

a_util::result::Result onSampleReceived ( const void *  data,
size_t  size 
)
virtual

Method to handle a sample when it is received.

Parameters
[in]dataThe memory location of the received buffer
[in]sizeThe memory size of the received buffer
Return values
a_util::result::SUCCESSEverything went fine

Implements ISignalListener.

◆ operator=()

Source& operator= ( const Source )
delete

no copy assignment operator

Returns
Source&

◆ removeAssignmentsFor()

a_util::result::Result removeAssignmentsFor ( const Target target)

Method to remove all elements of a target from the intern assignment list.

Parameters
[in]targetThe target to unmap
Return values
a_util::result::SUCCESSEverything went fine