per_code.hh
Go to the documentation of this file.
#pragma once
#include "Params.hh"
#include "asn1_recode_per.hh"
class BITSTRING;
class TTCN_Typedescriptor_t;
struct asn_TYPE_descriptor_s;
template<typename TPDU>
class per_code : public asn1_recode_per
{
public:
virtual int encode(const TPDU& p_message, BITSTRING& p_bitstring) = 0;
virtual int decode(const BITSTRING& p_bitstring, TPDU& p_message) = 0;
protected:
int _decode (const TTCN_Typedescriptor_t& ttcn, const asn_TYPE_descriptor_s & td, const BITSTRING& p_data, TPDU& msg);
int _encode (const TTCN_Typedescriptor_t& ttcn, const asn_TYPE_descriptor_s & td, const TPDU& msg, BITSTRING& p_data);
}; // End of class per_code
#include "per_code.t.hh"
per_code::encode
virtual int encode(const TPDU &p_message, BITSTRING &p_bitstring)=0
Encode TITAN message into ASN.1 PER message.
asn1_recode_per
Forward declaration of asn1c class.
Definition: asn1_recode_per.hh:24
Params.hh
Header file for the parameter dictionary.
per_code::decode
virtual int decode(const BITSTRING &p_bitstring, TPDU &p_message)=0
Decode ASN.1 PER message into TITAN message.
per_code::_encode
int _encode(const TTCN_Typedescriptor_t &ttcn, const asn_TYPE_descriptor_s &td, const TPDU &msg, BITSTRING &p_data)
Definition: per_code.t.hh:16
per_code
Declare asn1c class.
Definition: per_code.hh:27
per_code::_decode
int _decode(const TTCN_Typedescriptor_t &ttcn, const asn_TYPE_descriptor_s &td, const BITSTRING &p_data, TPDU &msg)
Definition: per_code.t.hh:4
per_code.t.hh
asn1_recode_per.hh
Header file ASN.1 PER codec based on asn1c external tool.