ADTF  3.18.2
sample_decoder_access< AccessType >

Implementation for decoder access concept (ddl::codec::DecoderElementAccess). More...

Inheritance diagram for sample_decoder_access< AccessType >:
[legend]

Public Types

typedef AccessType access_type
 used access type.
 
typedef tCodecIndex index_type
 used index type.
 
typedef ddl::codec::DecoderElement< sample_decoder_access< AccessType > > element_type
 supported element type.
 

Static Public Member Functions

static element_type getElement (access_type &access, const std::string &full_element_name)
 Get a element object for the given full_element_name. More...
 
static element_type getElement (access_type &access, const index_type &index)
 Get a element object for the given index. More...
 
static size_t getChildCount (access_type &access, const index_type &index)
 Get the Child Count. More...
 
static std::string getFullName (access_type &access, const index_type &index)
 Get the full name of the element within its main structure. More...
 
static std::string getName (access_type &access, const index_type &index)
 Get the name of the element within its level structure. More...
 
static std::string getBaseName (access_type &access, const index_type &index)
 Get the base name of the element within its level structure. More...
 
template<typename T >
static T getValue (access_type &access, const index_type &index)
 Get the value. More...
 
static a_util::variant::Variant getVariantValue (access_type &access, const index_type &index)
 Get the value as variant. More...
 
static std::string getStringValue (access_type &access, const index_type &index)
 Get the value as string. More...
 
static void getRawValue (access_type &access, const index_type &index, void *value, size_t value_size)
 Get the value by copy to the given value buffer. More...
 
static const void * getAddress (access_type &access, const index_type &index)
 Get the address. More...
 
static void resolve (access_type &access, index_type &index)
 Resolves the given CodecIndex and set the layout information. More...
 

Detailed Description

template<typename AccessType>
class adtf::mediadescription::osborn::sample_decoder_access< AccessType >

Implementation for decoder access concept (ddl::codec::DecoderElementAccess).

Template Parameters
AccessTypeThe adtf access type to use.

Definition at line 43 of file sample_codec_access_types.h.

Member Function Documentation

◆ getAddress()

static const void* getAddress ( access_type access,
const index_type index 
)
inlinestatic

Get the address.

Parameters
accessdefined access type.
indexThe codec index.
Returns
const void*

Definition at line 186 of file sample_codec_access_types.h.

◆ getBaseName()

static std::string getBaseName ( access_type access,
const index_type index 
)
inlinestatic

Get the base name of the element within its level structure.

If the element is an array you get the elements base name respresentation : "element_name" for each array element. If the element is not an array you get the elements name respresentation is also the base name respresentation: "element_name".

Parameters
accessdefined access type.
indexThe codec index
Returns
std::string

Definition at line 126 of file sample_codec_access_types.h.

◆ getChildCount()

static size_t getChildCount ( access_type access,
const index_type index 
)
inlinestatic

Get the Child Count.

Parameters
accessdefined access type.
indexThe codec index
Returns
size_t

Definition at line 87 of file sample_codec_access_types.h.

◆ getElement() [1/2]

static element_type getElement ( access_type access,
const index_type index 
)
inlinestatic

Get a element object for the given index.

Parameters
accessdefined access type.
indexThe codec index.
Returns
element_type

Definition at line 76 of file sample_codec_access_types.h.

◆ getElement() [2/2]

static element_type getElement ( access_type access,
const std::string &  full_element_name 
)
inlinestatic

Get a element object for the given full_element_name.

Parameters
accessdefined access type.
full_element_nameThe full name of the element in point notation (i.e. "element1.child_element[4].element_value").
Returns
element_type

Definition at line 65 of file sample_codec_access_types.h.

◆ getFullName()

static std::string getFullName ( access_type access,
const index_type index 
)
inlinestatic

Get the full name of the element within its main structure.

If the element is an array you get the elements array name respresentation: "main_element.element_name[0]" or main_element.element_name[1] ... etc. If the element is not an array you get the elements name respresentation: "main_element.element_name".

Parameters
accessdefined access type.
indexThe codec index
Returns
std::string

Definition at line 100 of file sample_codec_access_types.h.

◆ getName()

static std::string getName ( access_type access,
const index_type index 
)
inlinestatic

Get the name of the element within its level structure.

If the element is an array you get the elements array name respresentation: "element_name[0]" or element_name[1] ... etc. If the element is not an array you get the elements name respresentation: "element_name".

Parameters
accessdefined access type.
indexThe codec index
Returns
std::string

Definition at line 113 of file sample_codec_access_types.h.

◆ getRawValue()

static void getRawValue ( access_type access,
const index_type index,
void *  value,
size_t  value_size 
)
inlinestatic

Get the value by copy to the given value buffer.

Parameters
accessdefined access type.
indexThe codec index.
valuethe value buffer pointer.
value_sizethe size of the value buffer in bytes.

Definition at line 175 of file sample_codec_access_types.h.

◆ getStringValue()

static std::string getStringValue ( access_type access,
const index_type index 
)
inlinestatic

Get the value as string.

Parameters
accessdefined access type.
indexThe codec index.
Returns
value as string (the value is returned as element name in case of enum type)
Remarks
for T = std::string

Definition at line 163 of file sample_codec_access_types.h.

◆ getValue()

static T getValue ( access_type access,
const index_type index 
)
inlinestatic

Get the value.

Parameters
accessdefined access type.
indexThe codec index.
Template Parameters
TThe type of the value to return.
Returns
value in type T (supported types: all int types, bool, float, double, std::string)
Remarks
for T = std::string the value is returned as element name in case of enum type

Definition at line 140 of file sample_codec_access_types.h.

◆ getVariantValue()

static a_util::variant::Variant getVariantValue ( access_type access,
const index_type index 
)
inlinestatic

Get the value as variant.

Parameters
accessdefined access type.
indexThe codec index.
Returns
value as variant (supported types: all int types, bool, float, double, std::string)

Definition at line 151 of file sample_codec_access_types.h.

◆ resolve()

static void resolve ( access_type access,
index_type index 
)
inlinestatic

Resolves the given CodecIndex and set the layout information.

Parameters
accessdefined access type.
indexThe codec index to resolve
Exceptions
throwsif not found

Definition at line 198 of file sample_codec_access_types.h.