ADTF  3.18.2
cQtIStringImpl

Specialisation for QString class, because the QString stores values as unsigned short. More...

Inheritance diagram for cQtIStringImpl:
[legend]

Public Member Functions

 cQtIStringImpl (QString *pstrAssignValue)
 CTOR with pointer to the value of value_type. More...
 
 ~cQtIStringImpl ()
 DTOR.
 
tResult Set (const char *strValue) override
 Sets the given null-terminated string to the implementation. More...
 
const char * Get () const override
 Gets the pointer to the current associated nullterminated-string. More...
 
size_t GetLength () const override
 Gets the current size of the strng. More...
 

Private Member Functions

 cQtIStringImpl ()=delete
 CTOR.
 
 cQtIStringImpl (const cQtIStringImpl &strValue)=delete
 copy CTOR More...
 
 cQtIStringImpl (cQtIStringImpl &&strValue)=delete
 move CTOR More...
 
cQtIStringImploperator= (const cQtIStringImpl &strValue)=delete
 copy operator More...
 
cQtIStringImploperator= (cQtIStringImpl &&strValue)=delete
 move operator More...
 

Private Attributes

QString * m_pAssignValue
 pointer to the value
 
QByteArray m_oValueToReturnConstChar
 

Additional Inherited Members

- Static Public Attributes inherited from IString
static constexpr size_t InvalidPos = g_npos
 Invalid Position size.
 

Detailed Description

Specialisation for QString class, because the QString stores values as unsigned short.

Definition at line 26 of file qt_string_intf.h.

Constructor & Destructor Documentation

◆ cQtIStringImpl() [1/3]

cQtIStringImpl ( const cQtIStringImpl strValue)
privatedelete

copy CTOR

Parameters
[in]strValueinitial value

◆ cQtIStringImpl() [2/3]

cQtIStringImpl ( cQtIStringImpl &&  strValue)
privatedelete

move CTOR

Parameters
[in]strValueinitial value

◆ cQtIStringImpl() [3/3]

cQtIStringImpl ( QString *  pstrAssignValue)
inlineexplicit

CTOR with pointer to the value of value_type.

Parameters
pstrAssignValue[in] pointer to the value

Definition at line 51 of file qt_string_intf.h.

References cQtIStringImpl::m_pAssignValue.

Member Function Documentation

◆ Get()

const char* Get ( ) const
inlineoverridevirtual

Gets the pointer to the current associated nullterminated-string.

Returns
The pointer to the null-terminated string.
Remarks
Check the pointer, because it depends on the implementation of IString!

Implements IString.

Definition at line 73 of file qt_string_intf.h.

References cQtIStringImpl::m_pAssignValue.

◆ GetLength()

size_t GetLength ( ) const
inlineoverridevirtual

Gets the current size of the strng.

Usually this is in Bytes (null-termination is not included!)

Returns
The size of the string.
Return values
Ifnot valid return InvalidPos!

Implements IString.

Definition at line 83 of file qt_string_intf.h.

References cQtIStringImpl::m_pAssignValue.

◆ operator=() [1/2]

cQtIStringImpl& operator= ( const cQtIStringImpl strValue)
privatedelete

copy operator

Parameters
[in]strValuevalue to copy from
Returns
this

◆ operator=() [2/2]

cQtIStringImpl& operator= ( cQtIStringImpl &&  strValue)
privatedelete

move operator

Parameters
[in]strValuevalue to move from
Returns
this

◆ Set()

tResult Set ( const char *  strValue)
inlineoverridevirtual

Sets the given null-terminated string to the implementation.

Parameters
strValue[in] The null-terminated string to set.
Return values
ERR_NOERRORThe value is set successfully
ERR_MEMORYThe value can not be set. Too long. No truncating provided.

Implements IString.

Definition at line 60 of file qt_string_intf.h.

References cQtIStringImpl::m_pAssignValue, RETURN_ERROR, and RETURN_NOERROR.