Search for usage in LXR

KItinerary::UPERDecoder Class Reference

#include <uperdecoder.h>

Public Types

using size_type = BitVectorView::size_type

Public Member Functions

 UPERDecoder (BitVectorView data)
QByteArray errorMessage () const
bool hasError () const
size_type offset () const
template<std::size_t N>
std::bitset< N > readBitset ()
bool readBoolean ()
template<typename... Ts>
QVariant readChoiceWithExtensionMarker ()
int64_t readConstrainedWholeNumber (int64_t minimum, int64_t maximum)
template<typename T >
readEnumerated ()
template<typename T >
readEnumeratedWithExtensionMarker ()
QByteArray readIA5String ()
QByteArray readIA5String (size_type minLenght, size_type maxLength)
size_type readLengthDeterminant ()
QByteArray readOctetString ()
template<typename T >
QList< T > readSequenceOf ()
QList< int > readSequenceOfConstrainedWholeNumber (int64_t minimum, int64_t maximum)
QList< QByteArrayreadSequenceOfIA5String ()
QList< int > readSequenceOfUnconstrainedWholeNumber ()
QList< QStringreadSequenceOfUtf8String ()
int64_t readUnconstrainedWholeNumber ()
QString readUtf8String ()
void seek (size_type index)
void setError (const char *msg)

Detailed Description

Decoder for data encoded according to X.691 ASN.1 Unaligned Packed Encoding Rules (UPER).

Definition at line 16 of file uperdecoder.h.

Member Function Documentation

◆ hasError()

bool UPERDecoder::hasError ( ) const

Reading at any point encountered an error.

As uPER gives us no way to recover from that, everything read has to be considered invalid.

Definition at line 166 of file uperdecoder.cpp.

◆ readBitset()

template<std::size_t N>
std::bitset<N> KItinerary::UPERDecoder::readBitset ( )

Read an.

Template Parameters
Nsized bitmap.

Definition at line 65 of file uperdecoder.h.

◆ readBoolean()

bool UPERDecoder::readBoolean ( )

Read boolean value.

Definition at line 81 of file uperdecoder.cpp.

◆ readChoiceWithExtensionMarker()

template<typename... Ts>
QVariant KItinerary::UPERDecoder::readChoiceWithExtensionMarker ( )

Read a choice value.

See also
X.691 §23

Definition at line 117 of file uperdecoder.h.

◆ readConstrainedWholeNumber()

int64_t UPERDecoder::readConstrainedWholeNumber ( int64_t  minimum,
int64_t  maximum 

Read constrained whole number from the current position.

See also
X.691 §11.5

Definition at line 29 of file uperdecoder.cpp.

◆ readEnumerated()

template<typename T >
T KItinerary::UPERDecoder::readEnumerated ( )

Read enumerated value.

See also
X.691 §14

Definition at line 97 of file uperdecoder.h.

◆ readIA5String() [1/2]

QByteArray UPERDecoder::readIA5String ( )

Read an unconstrained IA5String (7 bit ASCII).

See also
X.691 §30

Definition at line 98 of file uperdecoder.cpp.

◆ readIA5String() [2/2]

QByteArray UPERDecoder::readIA5String ( size_type  minLenght,
size_type  maxLength 

Read length-constrained IA5String (7 bit ASCII).

See also
X.691 §30

Definition at line 103 of file uperdecoder.cpp.

◆ readLengthDeterminant()

UPERDecoder::size_type UPERDecoder::readLengthDeterminant ( )

Read length determinant.

See also
X.691 §11.9

Definition at line 51 of file uperdecoder.cpp.

◆ readOctetString()

QByteArray UPERDecoder::readOctetString ( )

Read unconstrained octet string (8 bit data).

See also
X.691 §17

Definition at line 114 of file uperdecoder.cpp.

◆ readSequenceOf()

template<typename T >
QList<T> KItinerary::UPERDecoder::readSequenceOf ( )

Read a sequence-of field with unrestricted size.

See also
X.691 §20

Definition at line 76 of file uperdecoder.h.

◆ readUnconstrainedWholeNumber()

int64_t UPERDecoder::readUnconstrainedWholeNumber ( )

Read unconstrained whole number.

See also
X.691 §11.8

Definition at line 39 of file uperdecoder.cpp.

◆ readUtf8String()

QString UPERDecoder::readUtf8String ( )

Read UTF-8 string.

Definition at line 73 of file uperdecoder.cpp.

◆ setError()

void UPERDecoder::setError ( const char *  msg)

Put the decoder into the error state.

Definition at line 176 of file uperdecoder.cpp.

The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Thu Sep 28 2023 04:00:17 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.