CONZEPT 16 C++ API
C16::Record::FieldConst< Value > Class Template Reference

Constant field buffer of a record buffer. More...

#include "C16/Record.hpp"

Inheritance diagram for C16::Record::FieldConst< Value >:
C16::Record::FieldConstGeneric C16::Record::FieldCommon

Detailed Description

template<typename Value>
class C16::Record::FieldConst< Value >

Constant field buffer of a record buffer.

Template Parameters
ValueValue type of the field.

Public Member Functions

 FieldConst (const Record &record, const C16::Field &field)
 Constructs a constent field buffer of a record buffer by means of its corresponing field. More...
 
 FieldConst (const Record &record, int subrecord_number, int field_number)
 Constructs a constant field buffer of a record buffer by means of the number of its subrecord and the number of its corresponing field. More...
 
 FieldConst (const Record &record, const std::string &field_name)
 Constructs a constant field buffer of a record buffer by means of the name of its corresponing field. More...
 
Value value () const
 Gets the value of the field buffer. More...
 
 operator Value () const
 Gets the value of the field buffer. More...
 
- Public Member Functions inherited from C16::Record::FieldConstGeneric
const Recordrecord () const override
 Gets the record buffer of the field buffer. More...
 
- Public Member Functions inherited from C16::Record::FieldCommon
const Fieldfield () const
 Gets the field of the field buffer. More...
 

Constructor & Destructor Documentation

◆ FieldConst() [1/3]

template<typename Value >
C16::Record::FieldConst< Value >::FieldConst ( const Record record,
const C16::Field field 
)

Constructs a constent field buffer of a record buffer by means of its corresponing field.

Parameters
recordRecord buffer
fieldField
Exceptions
Exception::DifferenceTable different.
Table of the field is different to table of the record buffer.
Exception::DifferenceType different.
Type of the field is different to the value type.
See also
Record::field<Value>(const C16::Field& field) const

◆ FieldConst() [2/3]

template<typename Value >
C16::Record::FieldConst< Value >::FieldConst ( const Record record,
int  subrecord_number,
int  field_number 
)

Constructs a constant field buffer of a record buffer by means of the number of its subrecord and the number of its corresponing field.

Parameters
recordRecord buffer
subrecord_numberNumber of the subrecord
field_numberNumber of the field
Exceptions
Exception::InexistenceField inexistent.
Exception::DifferenceType different.
Type of the field is different to the value type.
See also
Record::field<Value>(int subrecord_number, int field_number) const

◆ FieldConst() [3/3]

template<typename Value >
C16::Record::FieldConst< Value >::FieldConst ( const Record record,
const std::string &  field_name 
)

Constructs a constant field buffer of a record buffer by means of the name of its corresponing field.

Parameters
recordRecord buffer
field_nameName of the field
Exceptions
Exception::InexistenceField inexistent.
Exception::DifferenceType different.
Type of the field is different to the value type.
See also
Record::field<Value>(const std::string& field_name) const

Member Function Documentation

◆ value()

template<typename Value >
Value C16::Record::FieldConst< Value >::value ( ) const

Gets the value of the field buffer.

◆ operator Value()

template<typename Value >
C16::Record::FieldConst< Value >::operator Value ( ) const

Gets the value of the field buffer.