// This C++ source file was generated by the TTCN-3 compiler
// of the TTCN-3 Test Executor version 11.1.0
// The generation of user and time information were disabled by the -D flag.

// Copyright (c) 2000-2025 Ericsson Telecom AB

// Do not edit this file unless you know what you are doing.

/* Including header files */

#include "GSM_RestOctets.hh"

namespace GSM__RestOctets {

/* Literal string constants */

const unsigned char bs_1_bits[] = { 0 },
bs_2_bits[] = { 0 },
bs_3_bits[] = { 2 },
bs_0_bits[] = { 1 },
bs_4_bits[] = { 1 },
bs_5_bits[] = { 3 };
extern const BITSTRING bs_1(1, bs_1_bits),
bs_2(2, bs_2_bits),
bs_3(2, bs_3_bits),
bs_0(1, bs_0_bits),
bs_4(2, bs_4_bits),
bs_5(2, bs_5_bits);
const unsigned char pp_0[] = { 0x2b };
const unsigned char module_checksum[] = { 0xf4, 0xbf, 0x31, 0xd6, 0x0f, 0xba, 0x7c, 0xf5, 0x1d, 0x6c, 0xe2, 0x44, 0xfc, 0x73, 0x6b, 0x46 };

/* Global variable definitions */

const TTCN_RAWdescriptor_t IaRestOctets_presence_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       IaRestOctets_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t IaRestOctets_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t IaRestOctets_presence_descr_ = { "@GSM_RestOctets.IaRestOctets.presence", &BITSTRING_ber_, &IaRestOctets_presence_raw_, NULL, &IaRestOctets_presence_xer_, &BITSTRING_json_, &IaRestOctets_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctets_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctets_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,8,0,0,8,8,pp_0,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctets
const TTCN_Typedescriptor_t IaRestOctets_descr_ = { "@GSM_RestOctets.IaRestOctets", NULL, &IaRestOctets_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t IaRestOctLL_compressed__irat__ho__info__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       IaRestOctLL_compressed__irat__ho__info__ind_xer_ = { {"compressed_irat_ho_info_ind>\n", "compressed_irat_ho_info_ind>\n"}, {29, 29}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t IaRestOctLL_compressed__irat__ho__info__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t IaRestOctLL_compressed__irat__ho__info__ind_descr_ = { "@GSM_RestOctets.IaRestOctLL.compressed_irat_ho_info_ind", &BITSTRING_ber_, &IaRestOctLL_compressed__irat__ho__info__ind_raw_, NULL, &IaRestOctLL_compressed__irat__ho__info__ind_xer_, &BITSTRING_json_, &IaRestOctLL_compressed__irat__ho__info__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctLL_compressed__irat__ho__info__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctLL_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctLL
const TTCN_Typedescriptor_t IaRestOctLL_descr_ = { "@GSM_RestOctets.IaRestOctLL", NULL, &IaRestOctLL_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctLL_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctets_ll_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctets_ll
const TTCN_Typedescriptor_t IaRestOctets_ll_descr_ = { "@GSM_RestOctets.IaRestOctets.ll", NULL, &IaRestOctets_ll_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctets_ll_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctLH_presence_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       IaRestOctLH_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t IaRestOctLH_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t IaRestOctLH_presence_descr_ = { "@GSM_RestOctets.IaRestOctLH.presence", &BITSTRING_ber_, &IaRestOctLH_presence_raw_, NULL, &IaRestOctLH_presence_xer_, &BITSTRING_json_, &IaRestOctLH_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctLH_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctLH_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctLH
const TTCN_Typedescriptor_t IaRestOctLH_descr_ = { "@GSM_RestOctets.IaRestOctLH", NULL, &IaRestOctLH_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EgprsUlAss_ext__ra_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,5,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAss_ext__ra_xer_ = { {"ext_ra>\n", "ext_ra>\n"}, {8, 8}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t EgprsUlAss_ext__ra_descr_ = { "@GSM_RestOctets.EgprsUlAss.ext_ra", &BITSTRING_ber_, &EgprsUlAss_ext__ra_raw_, NULL, &EgprsUlAss_ext__ra_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAss_ext__ra_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAss_ats__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAss_ats__present_xer_ = { {"ats_present>\n", "ats_present>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAss_ats__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAss_ats__present_descr_ = { "@GSM_RestOctets.EgprsUlAss.ats_present", &BITSTRING_ber_, &EgprsUlAss_ats__present_raw_, NULL, &EgprsUlAss_ats__present_xer_, &BITSTRING_json_, &EgprsUlAss_ats__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAss_ats__present_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAss_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAss_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAss_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAss_presence_descr_ = { "@GSM_RestOctets.EgprsUlAss.presence", &BITSTRING_ber_, &EgprsUlAss_presence_raw_, NULL, &EgprsUlAss_presence_xer_, &BITSTRING_json_, &EgprsUlAss_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAss_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAss_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAss
const TTCN_Typedescriptor_t EgprsUlAss_descr_ = { "@GSM_RestOctets.EgprsUlAss", NULL, &EgprsUlAss_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EgprsUlAss_ats_raw_ = {0,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_REVERSE,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAss_ats
const TTCN_Typedescriptor_t EgprsUlAss_ats_descr_ = { "@GSM_RestOctets.EgprsUlAss.ats", NULL, &EgprsUlAss_ats_raw_, NULL, NULL, NULL, NULL, NULL, &RLCMAC__CSN1__Types::AccessTechnologiesRequestRepetition_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAss_ats_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_tfi__assignment_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_tfi__assignment_xer_ = { {"tfi_assignment>\n", "tfi_assignment>\n"}, {16, 16}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_tfi__assignment_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_tfi__assignment_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.tfi_assignment", &INTEGER_ber_, &EgprsUlAssignDyn_tfi__assignment_raw_, &INTEGER_text_, &EgprsUlAssignDyn_tfi__assignment_xer_, &INTEGER_json_, &EgprsUlAssignDyn_tfi__assignment_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_tfi__assignment_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_polling_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_polling_xer_ = { {"polling>\n", "polling>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_polling_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_polling_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.polling", &BITSTRING_ber_, &EgprsUlAssignDyn_polling_raw_, NULL, &EgprsUlAssignDyn_polling_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_polling_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_polling_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_spare_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_spare_xer_ = { {"spare>\n", "spare>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_spare_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_spare_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.spare", &BITSTRING_ber_, &EgprsUlAssignDyn_spare_raw_, NULL, &EgprsUlAssignDyn_spare_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_spare_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_spare_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_usf_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_usf_xer_ = { {"usf>\n", "usf>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_usf_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_usf_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.usf", &INTEGER_ber_, &EgprsUlAssignDyn_usf_raw_, &INTEGER_text_, &EgprsUlAssignDyn_usf_xer_, &INTEGER_json_, &EgprsUlAssignDyn_usf_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_usf_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_usf__granularity_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_usf__granularity_xer_ = { {"usf_granularity>\n", "usf_granularity>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_usf__granularity_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_usf__granularity_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.usf_granularity", &BITSTRING_ber_, &EgprsUlAssignDyn_usf__granularity_raw_, NULL, &EgprsUlAssignDyn_usf__granularity_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_usf__granularity_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_usf__granularity_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_p0__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_p0__present_xer_ = { {"p0_present>\n", "p0_present>\n"}, {12, 12}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_p0__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_p0__present_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.p0_present", &BITSTRING_ber_, &EgprsUlAssignDyn_p0__present_raw_, NULL, &EgprsUlAssignDyn_p0__present_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_p0__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_p0__present_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_egprs__ch__coding__cmd_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAssignDyn_egprs__ch__coding__cmd
const TTCN_Typedescriptor_t EgprsUlAssignDyn_egprs__ch__coding__cmd_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.egprs_ch_coding_cmd", NULL, &EgprsUlAssignDyn_egprs__ch__coding__cmd_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_egprs__ch__coding__cmd_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_tlli__block__chan__coding_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_tlli__block__chan__coding_xer_ = { {"tlli_block_chan_coding>\n", "tlli_block_chan_coding>\n"}, {24, 24}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_tlli__block__chan__coding_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_tlli__block__chan__coding_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.tlli_block_chan_coding", &BITSTRING_ber_, &EgprsUlAssignDyn_tlli__block__chan__coding_raw_, NULL, &EgprsUlAssignDyn_tlli__block__chan__coding_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_tlli__block__chan__coding_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_tlli__block__chan__coding_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_bep__period2__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_bep__period2__present_xer_ = { {"bep_period2_present>\n", "bep_period2_present>\n"}, {21, 21}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_bep__period2__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_bep__period2__present_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.bep_period2_present", &BITSTRING_ber_, &EgprsUlAssignDyn_bep__period2__present_raw_, NULL, &EgprsUlAssignDyn_bep__period2__present_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_bep__period2__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_bep__period2__present_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_resegment_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_resegment_xer_ = { {"resegment>\n", "resegment>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_resegment_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_resegment_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.resegment", &BITSTRING_ber_, &EgprsUlAssignDyn_resegment_raw_, NULL, &EgprsUlAssignDyn_resegment_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_resegment_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_resegment_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_egprs__window__size_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAssignDyn_egprs__window__size
const TTCN_Typedescriptor_t EgprsUlAssignDyn_egprs__window__size_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.egprs_window_size", NULL, &EgprsUlAssignDyn_egprs__window__size_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_egprs__window__size_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_alpha__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_alpha__present_xer_ = { {"alpha_present>\n", "alpha_present>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_alpha__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_alpha__present_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.alpha_present", &BITSTRING_ber_, &EgprsUlAssignDyn_alpha__present_raw_, NULL, &EgprsUlAssignDyn_alpha__present_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_alpha__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_alpha__present_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_gamma_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_gamma_xer_ = { {"gamma>\n", "gamma>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_gamma_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_gamma_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.gamma", &INTEGER_ber_, &EgprsUlAssignDyn_gamma_raw_, &INTEGER_text_, &EgprsUlAssignDyn_gamma_xer_, &INTEGER_json_, &EgprsUlAssignDyn_gamma_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_gamma_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_ta__index__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_ta__index__present_xer_ = { {"ta_index_present>\n", "ta_index_present>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_ta__index__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_ta__index__present_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.ta_index_present", &BITSTRING_ber_, &EgprsUlAssignDyn_ta__index__present_raw_, NULL, &EgprsUlAssignDyn_ta__index__present_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_ta__index__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_ta__index__present_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_tbf__starting__time__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_tbf__starting__time__present_xer_ = { {"tbf_starting_time_present>\n", "tbf_starting_time_present>\n"}, {27, 27}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_tbf__starting__time__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_tbf__starting__time__present_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.tbf_starting_time_present", &BITSTRING_ber_, &EgprsUlAssignDyn_tbf__starting__time__present_raw_, NULL, &EgprsUlAssignDyn_tbf__starting__time__present_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_tbf__starting__time__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_tbf__starting__time__present_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAssignDyn
const TTCN_Typedescriptor_t EgprsUlAssignDyn_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn", NULL, &EgprsUlAssignDyn_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_p0_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_p0_xer_ = { {"p0>\n", "p0>\n"}, {4, 4}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_p0_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_p0_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.p0", &INTEGER_ber_, &EgprsUlAssignDyn_p0_raw_, &INTEGER_text_, &EgprsUlAssignDyn_p0_xer_, &INTEGER_json_, &EgprsUlAssignDyn_p0_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_p0_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_pr__mode_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_pr__mode_xer_ = { {"pr_mode>\n", "pr_mode>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_pr__mode_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_pr__mode_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.pr_mode", &BITSTRING_ber_, &EgprsUlAssignDyn_pr__mode_raw_, NULL, &EgprsUlAssignDyn_pr__mode_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_pr__mode_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_pr__mode_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_bep__period2_raw_ = {4,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,4,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_bep__period2_xer_ = { {"bep_period2>\n", "bep_period2>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_bep__period2_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_bep__period2_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.bep_period2", &BITSTRING_ber_, &EgprsUlAssignDyn_bep__period2_raw_, NULL, &EgprsUlAssignDyn_bep__period2_xer_, &BITSTRING_json_, &EgprsUlAssignDyn_bep__period2_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_bep__period2_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_alpha_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_alpha_xer_ = { {"alpha>\n", "alpha>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_alpha_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_alpha_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.alpha", &INTEGER_ber_, &EgprsUlAssignDyn_alpha_raw_, &INTEGER_text_, &EgprsUlAssignDyn_alpha_xer_, &INTEGER_json_, &EgprsUlAssignDyn_alpha_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_alpha_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_ta__index_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignDyn_ta__index_xer_ = { {"ta_index>\n", "ta_index>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignDyn_ta__index_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignDyn_ta__index_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.ta_index", &INTEGER_ber_, &EgprsUlAssignDyn_ta__index_raw_, &INTEGER_text_, &EgprsUlAssignDyn_ta__index_xer_, &INTEGER_json_, &EgprsUlAssignDyn_ta__index_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_ta__index_default_coding("RAW");
const TTCN_RAWdescriptor_t TbfStartingTime_t1_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       TbfStartingTime_t1_xer_ = { {"t1>\n", "t1>\n"}, {4, 4}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t TbfStartingTime_t1_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t TbfStartingTime_t1_descr_ = { "@GSM_RestOctets.TbfStartingTime.t1", &INTEGER_ber_, &TbfStartingTime_t1_raw_, &INTEGER_text_, &TbfStartingTime_t1_xer_, &INTEGER_json_, &TbfStartingTime_t1_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING TbfStartingTime_t1_default_coding("RAW");
const TTCN_RAWdescriptor_t TbfStartingTime_t3_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       TbfStartingTime_t3_xer_ = { {"t3>\n", "t3>\n"}, {4, 4}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t TbfStartingTime_t3_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t TbfStartingTime_t3_descr_ = { "@GSM_RestOctets.TbfStartingTime.t3", &INTEGER_ber_, &TbfStartingTime_t3_raw_, &INTEGER_text_, &TbfStartingTime_t3_xer_, &INTEGER_json_, &TbfStartingTime_t3_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING TbfStartingTime_t3_default_coding("RAW");
const TTCN_RAWdescriptor_t TbfStartingTime_t2_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       TbfStartingTime_t2_xer_ = { {"t2>\n", "t2>\n"}, {4, 4}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t TbfStartingTime_t2_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t TbfStartingTime_t2_descr_ = { "@GSM_RestOctets.TbfStartingTime.t2", &INTEGER_ber_, &TbfStartingTime_t2_raw_, &INTEGER_text_, &TbfStartingTime_t2_xer_, &INTEGER_json_, &TbfStartingTime_t2_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING TbfStartingTime_t2_default_coding("RAW");
const TTCN_RAWdescriptor_t TbfStartingTime_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for TbfStartingTime
const TTCN_Typedescriptor_t TbfStartingTime_descr_ = { "@GSM_RestOctets.TbfStartingTime", NULL, &TbfStartingTime_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING TbfStartingTime_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignDyn_tbf__starting__time_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAssignDyn_tbf__starting__time
const TTCN_Typedescriptor_t EgprsUlAssignDyn_tbf__starting__time_descr_ = { "@GSM_RestOctets.EgprsUlAssignDyn.tbf_starting_time", NULL, &EgprsUlAssignDyn_tbf__starting__time_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_tbf__starting__time_default_coding("RAW");
UNIVERSAL_CHARSTRING EgprsUlAssignDyn_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAss_dynamic_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAss_dynamic
const TTCN_Typedescriptor_t EgprsUlAss_dynamic_descr_ = { "@GSM_RestOctets.EgprsUlAss.dynamic", NULL, &EgprsUlAss_dynamic_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAss_dynamic_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_alpha__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignMultiblock_alpha__present_xer_ = { {"alpha_present>\n", "alpha_present>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignMultiblock_alpha__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_alpha__present_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock.alpha_present", &BITSTRING_ber_, &EgprsUlAssignMultiblock_alpha__present_raw_, NULL, &EgprsUlAssignMultiblock_alpha__present_xer_, &BITSTRING_json_, &EgprsUlAssignMultiblock_alpha__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_alpha__present_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_gamma_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignMultiblock_gamma_xer_ = { {"gamma>\n", "gamma>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignMultiblock_gamma_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_gamma_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock.gamma", &INTEGER_ber_, &EgprsUlAssignMultiblock_gamma_raw_, &INTEGER_text_, &EgprsUlAssignMultiblock_gamma_xer_, &INTEGER_json_, &EgprsUlAssignMultiblock_gamma_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_gamma_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_tbf__starting__time_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAssignMultiblock_tbf__starting__time
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_tbf__starting__time_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock.tbf_starting_time", NULL, &EgprsUlAssignMultiblock_tbf__starting__time_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_tbf__starting__time_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_nr__radio__blocks__allocated_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignMultiblock_nr__radio__blocks__allocated_xer_ = { {"nr_radio_blocks_allocated>\n", "nr_radio_blocks_allocated>\n"}, {27, 27}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignMultiblock_nr__radio__blocks__allocated_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_nr__radio__blocks__allocated_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock.nr_radio_blocks_allocated", &BITSTRING_ber_, &EgprsUlAssignMultiblock_nr__radio__blocks__allocated_raw_, NULL, &EgprsUlAssignMultiblock_nr__radio__blocks__allocated_xer_, &BITSTRING_json_, &EgprsUlAssignMultiblock_nr__radio__blocks__allocated_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_nr__radio__blocks__allocated_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_p0__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignMultiblock_p0__present_xer_ = { {"p0_present>\n", "p0_present>\n"}, {12, 12}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignMultiblock_p0__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_p0__present_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock.p0_present", &BITSTRING_ber_, &EgprsUlAssignMultiblock_p0__present_raw_, NULL, &EgprsUlAssignMultiblock_p0__present_xer_, &BITSTRING_json_, &EgprsUlAssignMultiblock_p0__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_p0__present_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAssignMultiblock
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock", NULL, &EgprsUlAssignMultiblock_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_alpha_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignMultiblock_alpha_xer_ = { {"alpha>\n", "alpha>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignMultiblock_alpha_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_alpha_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock.alpha", &INTEGER_ber_, &EgprsUlAssignMultiblock_alpha_raw_, &INTEGER_text_, &EgprsUlAssignMultiblock_alpha_xer_, &INTEGER_json_, &EgprsUlAssignMultiblock_alpha_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_alpha_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_p0_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignMultiblock_p0_xer_ = { {"p0>\n", "p0>\n"}, {4, 4}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignMultiblock_p0_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_p0_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock.p0", &INTEGER_ber_, &EgprsUlAssignMultiblock_p0_raw_, &INTEGER_text_, &EgprsUlAssignMultiblock_p0_xer_, &INTEGER_json_, &EgprsUlAssignMultiblock_p0_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_p0_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_spare_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignMultiblock_spare_xer_ = { {"spare>\n", "spare>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignMultiblock_spare_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_spare_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock.spare", &BITSTRING_ber_, &EgprsUlAssignMultiblock_spare_raw_, NULL, &EgprsUlAssignMultiblock_spare_xer_, &BITSTRING_json_, &EgprsUlAssignMultiblock_spare_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_spare_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAssignMultiblock_pr__mode_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EgprsUlAssignMultiblock_pr__mode_xer_ = { {"pr_mode>\n", "pr_mode>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EgprsUlAssignMultiblock_pr__mode_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EgprsUlAssignMultiblock_pr__mode_descr_ = { "@GSM_RestOctets.EgprsUlAssignMultiblock.pr_mode", &BITSTRING_ber_, &EgprsUlAssignMultiblock_pr__mode_raw_, NULL, &EgprsUlAssignMultiblock_pr__mode_xer_, &BITSTRING_json_, &EgprsUlAssignMultiblock_pr__mode_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_pr__mode_default_coding("RAW");
UNIVERSAL_CHARSTRING EgprsUlAssignMultiblock_default_coding("RAW");
const TTCN_RAWdescriptor_t EgprsUlAss_multiblock_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EgprsUlAss_multiblock
const TTCN_Typedescriptor_t EgprsUlAss_multiblock_descr_ = { "@GSM_RestOctets.EgprsUlAss.multiblock", NULL, &EgprsUlAss_multiblock_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EgprsUlAss_multiblock_default_coding("RAW");
UNIVERSAL_CHARSTRING EgprsUlAss_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctLH_egprs__ul_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctLH_egprs__ul
const TTCN_Typedescriptor_t IaRestOctLH_egprs__ul_descr_ = { "@GSM_RestOctets.IaRestOctLH.egprs_ul", NULL, &IaRestOctLH_egprs__ul_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctLH_egprs__ul_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctLH_multiblock__dl__ass_raw_ = {0,SG_NO,ORDER_LSB,ORDER_MSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       IaRestOctLH_multiblock__dl__ass_xer_ = { {"multiblock_dl_ass>\n", "multiblock_dl_ass>\n"}, {19, 19}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const int IaRestOctLH_multiblock__dl__ass_oer_ext_arr_[0] = {};
const int IaRestOctLH_multiblock__dl__ass_oer_p_[0] = {};
const TTCN_OERdescriptor_t IaRestOctLH_multiblock__dl__ass_oer_ = { -1, TRUE, -1, FALSE, 0, 0, IaRestOctLH_multiblock__dl__ass_oer_ext_arr_, 0, IaRestOctLH_multiblock__dl__ass_oer_p_};
const TTCN_Typedescriptor_t IaRestOctLH_multiblock__dl__ass_descr_ = { "@GSM_RestOctets.IaRestOctLH.multiblock_dl_ass", &OCTETSTRING_ber_, &IaRestOctLH_multiblock__dl__ass_raw_, &OCTETSTRING_text_, &IaRestOctLH_multiblock__dl__ass_xer_, &OCTETSTRING_json_, &IaRestOctLH_multiblock__dl__ass_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctLH_multiblock__dl__ass_default_coding("RAW");
UNIVERSAL_CHARSTRING IaRestOctLH_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctets_lh_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctets_lh
const TTCN_Typedescriptor_t IaRestOctets_lh_descr_ = { "@GSM_RestOctets.IaRestOctets.lh", NULL, &IaRestOctets_lh_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctets_lh_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctHL_freq__par__len_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       IaRestOctHL_freq__par__len_xer_ = { {"freq_par_len>\n", "freq_par_len>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t IaRestOctHL_freq__par__len_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t IaRestOctHL_freq__par__len_descr_ = { "@GSM_RestOctets.IaRestOctHL.freq_par_len", &INTEGER_ber_, &IaRestOctHL_freq__par__len_raw_, &INTEGER_text_, &IaRestOctHL_freq__par__len_xer_, &INTEGER_json_, &IaRestOctHL_freq__par__len_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctHL_freq__par__len_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctHL_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctHL
const TTCN_Typedescriptor_t IaRestOctHL_descr_ = { "@GSM_RestOctets.IaRestOctHL", NULL, &IaRestOctHL_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t IaRestOctHL_padding_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       IaRestOctHL_padding_xer_ = { {"padding>\n", "padding>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t IaRestOctHL_padding_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t IaRestOctHL_padding_descr_ = { "@GSM_RestOctets.IaRestOctHL.padding", &BITSTRING_ber_, &IaRestOctHL_padding_raw_, NULL, &IaRestOctHL_padding_xer_, &BITSTRING_json_, &IaRestOctHL_padding_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctHL_padding_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctHL_maio_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       IaRestOctHL_maio_xer_ = { {"maio>\n", "maio>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t IaRestOctHL_maio_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t IaRestOctHL_maio_descr_ = { "@GSM_RestOctets.IaRestOctHL.maio", &INTEGER_ber_, &IaRestOctHL_maio_raw_, &INTEGER_text_, &IaRestOctHL_maio_xer_, &INTEGER_json_, &IaRestOctHL_maio_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctHL_maio_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctHL_mobile__allocation_raw_ = {0,SG_NO,ORDER_LSB,ORDER_MSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       IaRestOctHL_mobile__allocation_xer_ = { {"mobile_allocation>\n", "mobile_allocation>\n"}, {19, 19}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const int IaRestOctHL_mobile__allocation_oer_ext_arr_[0] = {};
const int IaRestOctHL_mobile__allocation_oer_p_[0] = {};
const TTCN_OERdescriptor_t IaRestOctHL_mobile__allocation_oer_ = { -1, TRUE, -1, FALSE, 0, 0, IaRestOctHL_mobile__allocation_oer_ext_arr_, 0, IaRestOctHL_mobile__allocation_oer_p_};
const TTCN_Typedescriptor_t IaRestOctHL_mobile__allocation_descr_ = { "@GSM_RestOctets.IaRestOctHL.mobile_allocation", &OCTETSTRING_ber_, &IaRestOctHL_mobile__allocation_raw_, &OCTETSTRING_text_, &IaRestOctHL_mobile__allocation_xer_, &OCTETSTRING_json_, &IaRestOctHL_mobile__allocation_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctHL_mobile__allocation_default_coding("RAW");
UNIVERSAL_CHARSTRING IaRestOctHL_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctets_hl_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctets_hl
const TTCN_Typedescriptor_t IaRestOctets_hl_descr_ = { "@GSM_RestOctets.IaRestOctets.hl", NULL, &IaRestOctets_hl_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctets_hl_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctHH_pa__disc_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       IaRestOctHH_pa__disc_xer_ = { {"pa_disc>\n", "pa_disc>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t IaRestOctHH_pa__disc_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t IaRestOctHH_pa__disc_descr_ = { "@GSM_RestOctets.IaRestOctHH.pa_disc", &BITSTRING_ber_, &IaRestOctHH_pa__disc_raw_, NULL, &IaRestOctHH_pa__disc_xer_, &BITSTRING_json_, &IaRestOctHH_pa__disc_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctHH_pa__disc_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketAssignUnion_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketAssignUnion
const TTCN_Typedescriptor_t PacketAssignUnion_descr_ = { "@GSM_RestOctets.PacketAssignUnion", NULL, &PacketAssignUnion_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SecondPartAssign_r99_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SecondPartAssign_r99_xer_ = { {"r99>\n", "r99>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SecondPartAssign_r99_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SecondPartAssign_r99_descr_ = { "@GSM_RestOctets.SecondPartAssign.r99", &BITSTRING_ber_, &SecondPartAssign_r99_raw_, NULL, &SecondPartAssign_r99_xer_, &BITSTRING_json_, &SecondPartAssign_r99_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SecondPartAssign_r99_default_coding("RAW");
const TTCN_RAWdescriptor_t SecondPartAssign_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SecondPartAssign
const TTCN_Typedescriptor_t SecondPartAssign_descr_ = { "@GSM_RestOctets.SecondPartAssign", NULL, &SecondPartAssign_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SecondPartAssign_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SecondPartAssign_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SecondPartAssign_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SecondPartAssign_presence_descr_ = { "@GSM_RestOctets.SecondPartAssign.presence", &BITSTRING_ber_, &SecondPartAssign_presence_raw_, NULL, &SecondPartAssign_presence_xer_, &BITSTRING_json_, &SecondPartAssign_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SecondPartAssign_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SecondPartAssign_ext__ra_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,5,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SecondPartAssign_ext__ra_xer_ = { {"ext_ra>\n", "ext_ra>\n"}, {8, 8}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SecondPartAssign_ext__ra_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SecondPartAssign_ext__ra_descr_ = { "@GSM_RestOctets.SecondPartAssign.ext_ra", &BITSTRING_ber_, &SecondPartAssign_ext__ra_raw_, NULL, &SecondPartAssign_ext__ra_xer_, &BITSTRING_json_, &SecondPartAssign_ext__ra_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SecondPartAssign_ext__ra_default_coding("RAW");
UNIVERSAL_CHARSTRING SecondPartAssign_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketAssignUnion_spa_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketAssignUnion_spa
const TTCN_Typedescriptor_t PacketAssignUnion_spa_descr_ = { "@GSM_RestOctets.PacketAssignUnion.spa", NULL, &PacketAssignUnion_spa_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketAssignUnion_spa_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlDlAssign_ass__disc_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlDlAssign_ass__disc_xer_ = { {"ass_disc>\n", "ass_disc>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlDlAssign_ass__disc_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlDlAssign_ass__disc_descr_ = { "@GSM_RestOctets.PacketUlDlAssign.ass_disc", &BITSTRING_ber_, &PacketUlDlAssign_ass__disc_raw_, NULL, &PacketUlDlAssign_ass__disc_xer_, &BITSTRING_json_, &PacketUlDlAssign_ass__disc_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlDlAssign_ass__disc_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlDlAssignUnion_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlDlAssignUnion
const TTCN_Typedescriptor_t PacketUlDlAssignUnion_descr_ = { "@GSM_RestOctets.PacketUlDlAssignUnion", NULL, &PacketUlDlAssignUnion_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t PacketUlAssign_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssign_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssign_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssign_presence_descr_ = { "@GSM_RestOctets.PacketUlAssign.presence", &BITSTRING_ber_, &PacketUlAssign_presence_raw_, NULL, &PacketUlAssign_presence_xer_, &BITSTRING_json_, &PacketUlAssign_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssign_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssign_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlAssign
const TTCN_Typedescriptor_t PacketUlAssign_descr_ = { "@GSM_RestOctets.PacketUlAssign", NULL, &PacketUlAssign_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t PacketUlAssignDyn_tfi__assignment_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_tfi__assignment_xer_ = { {"tfi_assignment>\n", "tfi_assignment>\n"}, {16, 16}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_tfi__assignment_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_tfi__assignment_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.tfi_assignment", &INTEGER_ber_, &PacketUlAssignDyn_tfi__assignment_raw_, &INTEGER_text_, &PacketUlAssignDyn_tfi__assignment_xer_, &INTEGER_json_, &PacketUlAssignDyn_tfi__assignment_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_tfi__assignment_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_polling_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_polling_xer_ = { {"polling>\n", "polling>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_polling_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_polling_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.polling", &BITSTRING_ber_, &PacketUlAssignDyn_polling_raw_, NULL, &PacketUlAssignDyn_polling_xer_, &BITSTRING_json_, &PacketUlAssignDyn_polling_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_polling_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_spare_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_spare_xer_ = { {"spare>\n", "spare>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_spare_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_spare_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.spare", &BITSTRING_ber_, &PacketUlAssignDyn_spare_raw_, NULL, &PacketUlAssignDyn_spare_xer_, &BITSTRING_json_, &PacketUlAssignDyn_spare_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_spare_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_usf_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_usf_xer_ = { {"usf>\n", "usf>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_usf_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_usf_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.usf", &INTEGER_ber_, &PacketUlAssignDyn_usf_raw_, &INTEGER_text_, &PacketUlAssignDyn_usf_xer_, &INTEGER_json_, &PacketUlAssignDyn_usf_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_usf_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_usf__granularity_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_usf__granularity_xer_ = { {"usf_granularity>\n", "usf_granularity>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_usf__granularity_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_usf__granularity_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.usf_granularity", &BITSTRING_ber_, &PacketUlAssignDyn_usf__granularity_raw_, NULL, &PacketUlAssignDyn_usf__granularity_xer_, &BITSTRING_json_, &PacketUlAssignDyn_usf__granularity_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_usf__granularity_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_p0__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_p0__present_xer_ = { {"p0_present>\n", "p0_present>\n"}, {12, 12}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_p0__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_p0__present_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.p0_present", &BITSTRING_ber_, &PacketUlAssignDyn_p0__present_raw_, NULL, &PacketUlAssignDyn_p0__present_xer_, &BITSTRING_json_, &PacketUlAssignDyn_p0__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_p0__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_ch__coding__cmd_raw_ = {2,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlAssignDyn_ch__coding__cmd
const TTCN_Typedescriptor_t PacketUlAssignDyn_ch__coding__cmd_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.ch_coding_cmd", NULL, &PacketUlAssignDyn_ch__coding__cmd_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_ch__coding__cmd_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_tlli__block__chan__coding_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_tlli__block__chan__coding_xer_ = { {"tlli_block_chan_coding>\n", "tlli_block_chan_coding>\n"}, {24, 24}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_tlli__block__chan__coding_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_tlli__block__chan__coding_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.tlli_block_chan_coding", &BITSTRING_ber_, &PacketUlAssignDyn_tlli__block__chan__coding_raw_, NULL, &PacketUlAssignDyn_tlli__block__chan__coding_xer_, &BITSTRING_json_, &PacketUlAssignDyn_tlli__block__chan__coding_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_tlli__block__chan__coding_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_alpha__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_alpha__present_xer_ = { {"alpha_present>\n", "alpha_present>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_alpha__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_alpha__present_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.alpha_present", &BITSTRING_ber_, &PacketUlAssignDyn_alpha__present_raw_, NULL, &PacketUlAssignDyn_alpha__present_xer_, &BITSTRING_json_, &PacketUlAssignDyn_alpha__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_alpha__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_gamma_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_gamma_xer_ = { {"gamma>\n", "gamma>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_gamma_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_gamma_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.gamma", &INTEGER_ber_, &PacketUlAssignDyn_gamma_raw_, &INTEGER_text_, &PacketUlAssignDyn_gamma_xer_, &INTEGER_json_, &PacketUlAssignDyn_gamma_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_gamma_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_ta__index__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_ta__index__present_xer_ = { {"ta_index_present>\n", "ta_index_present>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_ta__index__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_ta__index__present_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.ta_index_present", &BITSTRING_ber_, &PacketUlAssignDyn_ta__index__present_raw_, NULL, &PacketUlAssignDyn_ta__index__present_xer_, &BITSTRING_json_, &PacketUlAssignDyn_ta__index__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_ta__index__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_tbf__starting__time__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_tbf__starting__time__present_xer_ = { {"tbf_starting_time_present>\n", "tbf_starting_time_present>\n"}, {27, 27}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_tbf__starting__time__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_tbf__starting__time__present_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.tbf_starting_time_present", &BITSTRING_ber_, &PacketUlAssignDyn_tbf__starting__time__present_raw_, NULL, &PacketUlAssignDyn_tbf__starting__time__present_xer_, &BITSTRING_json_, &PacketUlAssignDyn_tbf__starting__time__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_tbf__starting__time__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlAssignDyn
const TTCN_Typedescriptor_t PacketUlAssignDyn_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn", NULL, &PacketUlAssignDyn_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t PacketUlAssignDyn_p0_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_p0_xer_ = { {"p0>\n", "p0>\n"}, {4, 4}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_p0_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_p0_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.p0", &INTEGER_ber_, &PacketUlAssignDyn_p0_raw_, &INTEGER_text_, &PacketUlAssignDyn_p0_xer_, &INTEGER_json_, &PacketUlAssignDyn_p0_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_p0_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_pr__mode_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_pr__mode_xer_ = { {"pr_mode>\n", "pr_mode>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_pr__mode_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_pr__mode_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.pr_mode", &BITSTRING_ber_, &PacketUlAssignDyn_pr__mode_raw_, NULL, &PacketUlAssignDyn_pr__mode_xer_, &BITSTRING_json_, &PacketUlAssignDyn_pr__mode_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_pr__mode_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_alpha_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_alpha_xer_ = { {"alpha>\n", "alpha>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_alpha_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_alpha_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.alpha", &INTEGER_ber_, &PacketUlAssignDyn_alpha_raw_, &INTEGER_text_, &PacketUlAssignDyn_alpha_xer_, &INTEGER_json_, &PacketUlAssignDyn_alpha_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_alpha_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_ta__index_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignDyn_ta__index_xer_ = { {"ta_index>\n", "ta_index>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignDyn_ta__index_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignDyn_ta__index_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.ta_index", &INTEGER_ber_, &PacketUlAssignDyn_ta__index_raw_, &INTEGER_text_, &PacketUlAssignDyn_ta__index_xer_, &INTEGER_json_, &PacketUlAssignDyn_ta__index_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_ta__index_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignDyn_tbf__starting__time_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlAssignDyn_tbf__starting__time
const TTCN_Typedescriptor_t PacketUlAssignDyn_tbf__starting__time_descr_ = { "@GSM_RestOctets.PacketUlAssignDyn.tbf_starting_time", NULL, &PacketUlAssignDyn_tbf__starting__time_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignDyn_tbf__starting__time_default_coding("RAW");
UNIVERSAL_CHARSTRING PacketUlAssignDyn_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssign_dynamic_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlAssign_dynamic
const TTCN_Typedescriptor_t PacketUlAssign_dynamic_descr_ = { "@GSM_RestOctets.PacketUlAssign.dynamic", NULL, &PacketUlAssign_dynamic_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssign_dynamic_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignSgl_alpha__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignSgl_alpha__present_xer_ = { {"alpha_present>\n", "alpha_present>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignSgl_alpha__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignSgl_alpha__present_descr_ = { "@GSM_RestOctets.PacketUlAssignSgl.alpha_present", &BITSTRING_ber_, &PacketUlAssignSgl_alpha__present_raw_, NULL, &PacketUlAssignSgl_alpha__present_xer_, &BITSTRING_json_, &PacketUlAssignSgl_alpha__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignSgl_alpha__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignSgl_gamma_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignSgl_gamma_xer_ = { {"gamma>\n", "gamma>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignSgl_gamma_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignSgl_gamma_descr_ = { "@GSM_RestOctets.PacketUlAssignSgl.gamma", &INTEGER_ber_, &PacketUlAssignSgl_gamma_raw_, &INTEGER_text_, &PacketUlAssignSgl_gamma_xer_, &INTEGER_json_, &PacketUlAssignSgl_gamma_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignSgl_gamma_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignSgl_padding_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignSgl_padding_xer_ = { {"padding>\n", "padding>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignSgl_padding_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignSgl_padding_descr_ = { "@GSM_RestOctets.PacketUlAssignSgl.padding", &BITSTRING_ber_, &PacketUlAssignSgl_padding_raw_, NULL, &PacketUlAssignSgl_padding_xer_, &BITSTRING_json_, &PacketUlAssignSgl_padding_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignSgl_padding_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignSgl_tbf__starting__time_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlAssignSgl_tbf__starting__time
const TTCN_Typedescriptor_t PacketUlAssignSgl_tbf__starting__time_descr_ = { "@GSM_RestOctets.PacketUlAssignSgl.tbf_starting_time", NULL, &PacketUlAssignSgl_tbf__starting__time_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignSgl_tbf__starting__time_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssignSgl_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlAssignSgl
const TTCN_Typedescriptor_t PacketUlAssignSgl_descr_ = { "@GSM_RestOctets.PacketUlAssignSgl", NULL, &PacketUlAssignSgl_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t PacketUlAssignSgl_alpha_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketUlAssignSgl_alpha_xer_ = { {"alpha>\n", "alpha>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketUlAssignSgl_alpha_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketUlAssignSgl_alpha_descr_ = { "@GSM_RestOctets.PacketUlAssignSgl.alpha", &INTEGER_ber_, &PacketUlAssignSgl_alpha_raw_, &INTEGER_text_, &PacketUlAssignSgl_alpha_xer_, &INTEGER_json_, &PacketUlAssignSgl_alpha_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssignSgl_alpha_default_coding("RAW");
UNIVERSAL_CHARSTRING PacketUlAssignSgl_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlAssign_single_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlAssign_single
const TTCN_Typedescriptor_t PacketUlAssign_single_descr_ = { "@GSM_RestOctets.PacketUlAssign.single", NULL, &PacketUlAssign_single_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlAssign_single_default_coding("RAW");
UNIVERSAL_CHARSTRING PacketUlAssign_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlDlAssignUnion_ul_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlDlAssignUnion_ul
const TTCN_Typedescriptor_t PacketUlDlAssignUnion_ul_descr_ = { "@GSM_RestOctets.PacketUlDlAssignUnion.ul", NULL, &PacketUlDlAssignUnion_ul_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlDlAssignUnion_ul_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_tlli_raw_ = {32,SG_NO,ORDER_LSB,ORDER_MSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,4,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssign_tlli_xer_ = { {"tlli>\n", "tlli>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const int PacketDlAssign_tlli_oer_ext_arr_[0] = {};
const int PacketDlAssign_tlli_oer_p_[0] = {};
const TTCN_OERdescriptor_t PacketDlAssign_tlli_oer_ = { -1, TRUE, 4, FALSE, 0, 0, PacketDlAssign_tlli_oer_ext_arr_, 0, PacketDlAssign_tlli_oer_p_};
const TTCN_Typedescriptor_t PacketDlAssign_tlli_descr_ = { "@GSM_RestOctets.PacketDlAssign.tlli", &OCTETSTRING_ber_, &PacketDlAssign_tlli_raw_, &OCTETSTRING_text_, &PacketDlAssign_tlli_xer_, &OCTETSTRING_json_, &PacketDlAssign_tlli_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_tlli_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_group1__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssign_group1__present_xer_ = { {"group1_present>\n", "group1_present>\n"}, {16, 16}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssign_group1__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssign_group1__present_descr_ = { "@GSM_RestOctets.PacketDlAssign.group1_present", &BITSTRING_ber_, &PacketDlAssign_group1__present_raw_, NULL, &PacketDlAssign_group1__present_xer_, &BITSTRING_json_, &PacketDlAssign_group1__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_group1__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_ta__index__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssign_ta__index__present_xer_ = { {"ta_index_present>\n", "ta_index_present>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssign_ta__index__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssign_ta__index__present_descr_ = { "@GSM_RestOctets.PacketDlAssign.ta_index_present", &BITSTRING_ber_, &PacketDlAssign_ta__index__present_raw_, NULL, &PacketDlAssign_ta__index__present_xer_, &BITSTRING_json_, &PacketDlAssign_ta__index__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_ta__index__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_tbf__starting__time__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssign_tbf__starting__time__present_xer_ = { {"tbf_starting_time_present>\n", "tbf_starting_time_present>\n"}, {27, 27}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssign_tbf__starting__time__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssign_tbf__starting__time__present_descr_ = { "@GSM_RestOctets.PacketDlAssign.tbf_starting_time_present", &BITSTRING_ber_, &PacketDlAssign_tbf__starting__time__present_raw_, NULL, &PacketDlAssign_tbf__starting__time__present_xer_, &BITSTRING_json_, &PacketDlAssign_tbf__starting__time__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_tbf__starting__time__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_p0__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssign_p0__present_xer_ = { {"p0_present>\n", "p0_present>\n"}, {12, 12}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssign_p0__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssign_p0__present_descr_ = { "@GSM_RestOctets.PacketDlAssign.p0_present", &BITSTRING_ber_, &PacketDlAssign_p0__present_raw_, NULL, &PacketDlAssign_p0__present_xer_, &BITSTRING_json_, &PacketDlAssign_p0__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_p0__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketDlAssign
const TTCN_Typedescriptor_t PacketDlAssign_descr_ = { "@GSM_RestOctets.PacketDlAssign", NULL, &PacketDlAssign_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t PacketDlAssG1_tfi__assignment_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssG1_tfi__assignment_xer_ = { {"tfi_assignment>\n", "tfi_assignment>\n"}, {16, 16}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssG1_tfi__assignment_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssG1_tfi__assignment_descr_ = { "@GSM_RestOctets.PacketDlAssG1.tfi_assignment", &INTEGER_ber_, &PacketDlAssG1_tfi__assignment_raw_, &INTEGER_text_, &PacketDlAssG1_tfi__assignment_xer_, &INTEGER_json_, &PacketDlAssG1_tfi__assignment_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssG1_tfi__assignment_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssG1_rlc__mode_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssG1_rlc__mode_xer_ = { {"rlc_mode>\n", "rlc_mode>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssG1_rlc__mode_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssG1_rlc__mode_descr_ = { "@GSM_RestOctets.PacketDlAssG1.rlc_mode", &BITSTRING_ber_, &PacketDlAssG1_rlc__mode_raw_, NULL, &PacketDlAssG1_rlc__mode_xer_, &BITSTRING_json_, &PacketDlAssG1_rlc__mode_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssG1_rlc__mode_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssG1_alpha__present_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssG1_alpha__present_xer_ = { {"alpha_present>\n", "alpha_present>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssG1_alpha__present_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssG1_alpha__present_descr_ = { "@GSM_RestOctets.PacketDlAssG1.alpha_present", &BITSTRING_ber_, &PacketDlAssG1_alpha__present_raw_, NULL, &PacketDlAssG1_alpha__present_xer_, &BITSTRING_json_, &PacketDlAssG1_alpha__present_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssG1_alpha__present_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssG1_gamma_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssG1_gamma_xer_ = { {"gamma>\n", "gamma>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssG1_gamma_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssG1_gamma_descr_ = { "@GSM_RestOctets.PacketDlAssG1.gamma", &INTEGER_ber_, &PacketDlAssG1_gamma_raw_, &INTEGER_text_, &PacketDlAssG1_gamma_xer_, &INTEGER_json_, &PacketDlAssG1_gamma_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssG1_gamma_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssG1_polling_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssG1_polling_xer_ = { {"polling>\n", "polling>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssG1_polling_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssG1_polling_descr_ = { "@GSM_RestOctets.PacketDlAssG1.polling", &BITSTRING_ber_, &PacketDlAssG1_polling_raw_, NULL, &PacketDlAssG1_polling_xer_, &BITSTRING_json_, &PacketDlAssG1_polling_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssG1_polling_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssG1_ta__valid_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssG1_ta__valid_xer_ = { {"ta_valid>\n", "ta_valid>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssG1_ta__valid_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssG1_ta__valid_descr_ = { "@GSM_RestOctets.PacketDlAssG1.ta_valid", &BITSTRING_ber_, &PacketDlAssG1_ta__valid_raw_, NULL, &PacketDlAssG1_ta__valid_xer_, &BITSTRING_json_, &PacketDlAssG1_ta__valid_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssG1_ta__valid_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssG1_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketDlAssG1
const TTCN_Typedescriptor_t PacketDlAssG1_descr_ = { "@GSM_RestOctets.PacketDlAssG1", NULL, &PacketDlAssG1_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t PacketDlAssG1_alpha_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssG1_alpha_xer_ = { {"alpha>\n", "alpha>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssG1_alpha_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssG1_alpha_descr_ = { "@GSM_RestOctets.PacketDlAssG1.alpha", &INTEGER_ber_, &PacketDlAssG1_alpha_raw_, &INTEGER_text_, &PacketDlAssG1_alpha_xer_, &INTEGER_json_, &PacketDlAssG1_alpha_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssG1_alpha_default_coding("RAW");
UNIVERSAL_CHARSTRING PacketDlAssG1_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_group1_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketDlAssign_group1
const TTCN_Typedescriptor_t PacketDlAssign_group1_descr_ = { "@GSM_RestOctets.PacketDlAssign.group1", NULL, &PacketDlAssign_group1_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_group1_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_ta__index_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssign_ta__index_xer_ = { {"ta_index>\n", "ta_index>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssign_ta__index_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssign_ta__index_descr_ = { "@GSM_RestOctets.PacketDlAssign.ta_index", &INTEGER_ber_, &PacketDlAssign_ta__index_raw_, &INTEGER_text_, &PacketDlAssign_ta__index_xer_, &INTEGER_json_, &PacketDlAssign_ta__index_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_ta__index_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_tbf__starting__time_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketDlAssign_tbf__starting__time
const TTCN_Typedescriptor_t PacketDlAssign_tbf__starting__time_descr_ = { "@GSM_RestOctets.PacketDlAssign.tbf_starting_time", NULL, &PacketDlAssign_tbf__starting__time_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_tbf__starting__time_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_p0_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssign_p0_xer_ = { {"p0>\n", "p0>\n"}, {4, 4}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssign_p0_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssign_p0_descr_ = { "@GSM_RestOctets.PacketDlAssign.p0", &INTEGER_ber_, &PacketDlAssign_p0_raw_, &INTEGER_text_, &PacketDlAssign_p0_xer_, &INTEGER_json_, &PacketDlAssign_p0_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_p0_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketDlAssign_pr__mode_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PacketDlAssign_pr__mode_xer_ = { {"pr_mode>\n", "pr_mode>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PacketDlAssign_pr__mode_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PacketDlAssign_pr__mode_descr_ = { "@GSM_RestOctets.PacketDlAssign.pr_mode", &BITSTRING_ber_, &PacketDlAssign_pr__mode_raw_, NULL, &PacketDlAssign_pr__mode_xer_, &BITSTRING_json_, &PacketDlAssign_pr__mode_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketDlAssign_pr__mode_default_coding("RAW");
UNIVERSAL_CHARSTRING PacketDlAssign_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlDlAssignUnion_dl_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlDlAssignUnion_dl
const TTCN_Typedescriptor_t PacketUlDlAssignUnion_dl_descr_ = { "@GSM_RestOctets.PacketUlDlAssignUnion.dl", NULL, &PacketUlDlAssignUnion_dl_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlDlAssignUnion_dl_default_coding("RAW");
UNIVERSAL_CHARSTRING PacketUlDlAssignUnion_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlDlAssign_ass_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlDlAssign_ass
const TTCN_Typedescriptor_t PacketUlDlAssign_ass_descr_ = { "@GSM_RestOctets.PacketUlDlAssign.ass", NULL, &PacketUlDlAssign_ass_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlDlAssign_ass_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketUlDlAssign_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketUlDlAssign
const TTCN_Typedescriptor_t PacketUlDlAssign_descr_ = { "@GSM_RestOctets.PacketUlDlAssign", NULL, &PacketUlDlAssign_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketUlDlAssign_default_coding("RAW");
const TTCN_RAWdescriptor_t PacketAssignUnion_uldl_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PacketAssignUnion_uldl
const TTCN_Typedescriptor_t PacketAssignUnion_uldl_descr_ = { "@GSM_RestOctets.PacketAssignUnion.uldl", NULL, &PacketAssignUnion_uldl_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PacketAssignUnion_uldl_default_coding("RAW");
UNIVERSAL_CHARSTRING PacketAssignUnion_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctHH_pa_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctHH_pa
const TTCN_Typedescriptor_t IaRestOctHH_pa_descr_ = { "@GSM_RestOctets.IaRestOctHH.pa", NULL, &IaRestOctHH_pa_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctHH_pa_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctHH_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctHH
const TTCN_Typedescriptor_t IaRestOctHH_descr_ = { "@GSM_RestOctets.IaRestOctHH", NULL, &IaRestOctHH_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctHH_default_coding("RAW");
const TTCN_RAWdescriptor_t IaRestOctets_hh_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IaRestOctets_hh
const TTCN_Typedescriptor_t IaRestOctets_hh_descr_ = { "@GSM_RestOctets.IaRestOctets.hh", NULL, &IaRestOctets_hh_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IaRestOctets_hh_default_coding("RAW");
UNIVERSAL_CHARSTRING IaRestOctets_default_coding("RAW");
const TTCN_RAWdescriptor_t ExtRAList_raw_ = {4,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for ExtRAList
const TTCN_Typedescriptor_t ExtRAList_descr_ = { "@GSM_RestOctets.ExtRAList", NULL, &ExtRAList_raw_, NULL, NULL, NULL, NULL, NULL, &ExtRAList_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t ExtRAOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       ExtRAOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t ExtRAOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t ExtRAOpt_presence_descr_ = { "@GSM_RestOctets.ExtRAOpt.presence", &BITSTRING_ber_, &ExtRAOpt_presence_raw_, NULL, &ExtRAOpt_presence_xer_, &BITSTRING_json_, &ExtRAOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ExtRAOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t ExtRAOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for ExtRAOpt
const TTCN_Typedescriptor_t ExtRAOpt_descr_ = { "@GSM_RestOctets.ExtRAOpt", NULL, &ExtRAOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t ExtRAOpt_ext__ra_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,5,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       ExtRAOpt_ext__ra_xer_ = { {"ext_ra>\n", "ext_ra>\n"}, {8, 8}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t ExtRAOpt_ext__ra_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t ExtRAOpt_ext__ra_descr_ = { "@GSM_RestOctets.ExtRAOpt.ext_ra", &BITSTRING_ber_, &ExtRAOpt_ext__ra_raw_, NULL, &ExtRAOpt_ext__ra_xer_, &BITSTRING_json_, &ExtRAOpt_ext__ra_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ExtRAOpt_ext__ra_default_coding("RAW");
UNIVERSAL_CHARSTRING ExtRAOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t ExtRAList_0_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for ExtRAList_0
const TTCN_Typedescriptor_t ExtRAList_0_descr_ = { "@GSM_RestOctets.ExtRAList.<oftype>", NULL, &ExtRAList_0_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ExtRAList_0_default_coding("RAW");
UNIVERSAL_CHARSTRING ExtRAList_default_coding("RAW");
const TTCN_RAWdescriptor_t IARRestOctets_ext__ra__list_raw_ = {4,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IARRestOctets_ext__ra__list
const TTCN_Typedescriptor_t IARRestOctets_ext__ra__list_descr_ = { "@GSM_RestOctets.IARRestOctets.ext_ra_list", NULL, &IARRestOctets_ext__ra__list_raw_, NULL, NULL, NULL, NULL, NULL, &ExtRAList_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IARRestOctets_ext__ra__list_default_coding("RAW");
const TTCN_RAWdescriptor_t IARRestOctets_rel13__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       IARRestOctets_rel13__ind_xer_ = { {"rel13_ind>\n", "rel13_ind>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t IARRestOctets_rel13__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t IARRestOctets_rel13__ind_descr_ = { "@GSM_RestOctets.IARRestOctets.rel13_ind", &BITSTRING_ber_, &IARRestOctets_rel13__ind_raw_, NULL, &IARRestOctets_rel13__ind_xer_, &BITSTRING_json_, &IARRestOctets_rel13__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IARRestOctets_rel13__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t IARRestOctets_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,8,0,0,8,8,pp_0,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for IARRestOctets
const TTCN_Typedescriptor_t IARRestOctets_descr_ = { "@GSM_RestOctets.IARRestOctets", NULL, &IARRestOctets_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t IARRestOctets_rcc_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       IARRestOctets_rcc_xer_ = { {"rcc>\n", "rcc>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t IARRestOctets_rcc_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t IARRestOctets_rcc_descr_ = { "@GSM_RestOctets.IARRestOctets.rcc", &INTEGER_ber_, &IARRestOctets_rcc_raw_, &INTEGER_text_, &IARRestOctets_rcc_xer_, &INTEGER_json_, &IARRestOctets_rcc_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING IARRestOctets_rcc_default_coding("RAW");
UNIVERSAL_CHARSTRING IARRestOctets_default_coding("RAW");
INTEGER_template template_tr__PacketUlDynAssign_tfi_defval;
const INTEGER_template& tr__PacketUlDynAssign_tfi_defval = template_tr__PacketUlDynAssign_tfi_defval;
BITSTRING_template template_tr__PacketUlDynAssign_polling_defval;
const BITSTRING_template& tr__PacketUlDynAssign_polling_defval = template_tr__PacketUlDynAssign_polling_defval;
INTEGER_template template_tr__PacketUlDynAssign_usf_defval;
const INTEGER_template& tr__PacketUlDynAssign_usf_defval = template_tr__PacketUlDynAssign_usf_defval;
BITSTRING_template template_tr__PacketUlDynAssign_usf__granularity_defval;
const BITSTRING_template& tr__PacketUlDynAssign_usf__granularity_defval = template_tr__PacketUlDynAssign_usf__granularity_defval;
RLCMAC__CSN1__Types::ChCodingCommand_template template_tr__PacketUlDynAssign_cs_defval;
const RLCMAC__CSN1__Types::ChCodingCommand_template& tr__PacketUlDynAssign_cs_defval = template_tr__PacketUlDynAssign_cs_defval;
PacketUlAssign_template template_tr__PacketUlSglAssign;
const PacketUlAssign_template& tr__PacketUlSglAssign = template_tr__PacketUlSglAssign;
BITSTRING_template template_tr__EgprsUlAssDynamic_ext__ra_defval;
const BITSTRING_template& tr__EgprsUlAssDynamic_ext__ra_defval = template_tr__EgprsUlAssDynamic_ext__ra_defval;
EgprsUlAssignDyn_template template_tr__EgprsUlAssDynamic_dyn__ass_defval;
const EgprsUlAssignDyn_template& tr__EgprsUlAssDynamic_dyn__ass_defval = template_tr__EgprsUlAssDynamic_dyn__ass_defval;
BITSTRING_template template_tr__EgprsUlAssMultiblock_ext__ra_defval;
const BITSTRING_template& tr__EgprsUlAssMultiblock_ext__ra_defval = template_tr__EgprsUlAssMultiblock_ext__ra_defval;
EgprsUlAssignMultiblock_template template_tr__EgprsUlAssMultiblock_mb__ass_defval;
const EgprsUlAssignMultiblock_template& tr__EgprsUlAssMultiblock_mb__ass_defval = template_tr__EgprsUlAssMultiblock_mb__ass_defval;
ExtRAList_template template_tr__IARRestOctets_ext__ra__list_defval;
const ExtRAList_template& tr__IARRestOctets_ext__ra__list_defval = template_tr__IARRestOctets_ext__ra__list_defval;
INTEGER_template template_tr__IARRestOctets_rcc_defval;
const INTEGER_template& tr__IARRestOctets_rcc_defval = template_tr__IARRestOctets_rcc_defval;
BITSTRING_template template_tr__ExtRAOpt_ext__ra_defval;
const BITSTRING_template& tr__ExtRAOpt_ext__ra_defval = template_tr__ExtRAOpt_ext__ra_defval;
const TTCN_RAWdescriptor_t SI2quaterRestOctets_ba__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterRestOctets_ba__ind_xer_ = { {"ba_ind>\n", "ba_ind>\n"}, {8, 8}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterRestOctets_ba__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterRestOctets_ba__ind_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.ba_ind", &BITSTRING_ber_, &SI2quaterRestOctets_ba__ind_raw_, NULL, &SI2quaterRestOctets_ba__ind_xer_, &BITSTRING_json_, &SI2quaterRestOctets_ba__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_ba__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_ba__3g__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterRestOctets_ba__3g__ind_xer_ = { {"ba_3g_ind>\n", "ba_3g_ind>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterRestOctets_ba__3g__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterRestOctets_ba__3g__ind_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.ba_3g_ind", &BITSTRING_ber_, &SI2quaterRestOctets_ba__3g__ind_raw_, NULL, &SI2quaterRestOctets_ba__3g__ind_xer_, &BITSTRING_json_, &SI2quaterRestOctets_ba__3g__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_ba__3g__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_mp__change__mark_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterRestOctets_mp__change__mark_xer_ = { {"mp_change_mark>\n", "mp_change_mark>\n"}, {16, 16}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterRestOctets_mp__change__mark_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterRestOctets_mp__change__mark_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.mp_change_mark", &BITSTRING_ber_, &SI2quaterRestOctets_mp__change__mark_raw_, NULL, &SI2quaterRestOctets_mp__change__mark_xer_, &BITSTRING_json_, &SI2quaterRestOctets_mp__change__mark_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_mp__change__mark_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_si2quater__index_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterRestOctets_si2quater__index_xer_ = { {"si2quater_index>\n", "si2quater_index>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterRestOctets_si2quater__index_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterRestOctets_si2quater__index_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.si2quater_index", &INTEGER_ber_, &SI2quaterRestOctets_si2quater__index_raw_, &INTEGER_text_, &SI2quaterRestOctets_si2quater__index_xer_, &INTEGER_json_, &SI2quaterRestOctets_si2quater__index_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_si2quater__index_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_si2quater__count_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterRestOctets_si2quater__count_xer_ = { {"si2quater_count>\n", "si2quater_count>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterRestOctets_si2quater__count_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterRestOctets_si2quater__count_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.si2quater_count", &INTEGER_ber_, &SI2quaterRestOctets_si2quater__count_raw_, &INTEGER_text_, &SI2quaterRestOctets_si2quater__count_xer_, &INTEGER_json_, &SI2quaterRestOctets_si2quater__count_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_si2quater__count_default_coding("RAW");
const TTCN_RAWdescriptor_t MeasParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       MeasParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t MeasParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t MeasParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.MeasParamsDescOpt.presence", &BITSTRING_ber_, &MeasParamsDescOpt_presence_raw_, NULL, &MeasParamsDescOpt_presence_xer_, &BITSTRING_json_, &MeasParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING MeasParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t MeasParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for MeasParamsDescOpt
const TTCN_Typedescriptor_t MeasParamsDescOpt_descr_ = { "@GSM_RestOctets.MeasParamsDescOpt", NULL, &MeasParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t MeasParamsDesc_report__type_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       MeasParamsDesc_report__type_xer_ = { {"report_type>\n", "report_type>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t MeasParamsDesc_report__type_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t MeasParamsDesc_report__type_descr_ = { "@GSM_RestOctets.MeasParamsDesc.report_type", &BITSTRING_ber_, &MeasParamsDesc_report__type_raw_, NULL, &MeasParamsDesc_report__type_xer_, &BITSTRING_json_, &MeasParamsDesc_report__type_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING MeasParamsDesc_report__type_default_coding("RAW");
const TTCN_RAWdescriptor_t MeasParamsDesc_serving__band__reporting_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       MeasParamsDesc_serving__band__reporting_xer_ = { {"serving_band_reporting>\n", "serving_band_reporting>\n"}, {24, 24}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t MeasParamsDesc_serving__band__reporting_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t MeasParamsDesc_serving__band__reporting_descr_ = { "@GSM_RestOctets.MeasParamsDesc.serving_band_reporting", &BITSTRING_ber_, &MeasParamsDesc_serving__band__reporting_raw_, NULL, &MeasParamsDesc_serving__band__reporting_xer_, &BITSTRING_json_, &MeasParamsDesc_serving__band__reporting_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING MeasParamsDesc_serving__band__reporting_default_coding("RAW");
const TTCN_RAWdescriptor_t MeasParamsDesc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for MeasParamsDesc
const TTCN_Typedescriptor_t MeasParamsDesc_descr_ = { "@GSM_RestOctets.MeasParamsDesc", NULL, &MeasParamsDesc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING MeasParamsDesc_default_coding("RAW");
const TTCN_RAWdescriptor_t MeasParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for MeasParamsDescOpt_desc
const TTCN_Typedescriptor_t MeasParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.MeasParamsDescOpt.desc", NULL, &MeasParamsDescOpt_desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING MeasParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING MeasParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_meas__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_meas__params__desc
const TTCN_Typedescriptor_t SI2quaterRestOctets_meas__params__desc_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.meas_params_desc", NULL, &SI2quaterRestOctets_meas__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_meas__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRS__RealTimeDiffDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       GPRS__RealTimeDiffDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t GPRS__RealTimeDiffDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t GPRS__RealTimeDiffDescOpt_presence_descr_ = { "@GSM_RestOctets.GPRS_RealTimeDiffDescOpt.presence", &BITSTRING_ber_, &GPRS__RealTimeDiffDescOpt_presence_raw_, NULL, &GPRS__RealTimeDiffDescOpt_presence_xer_, &BITSTRING_json_, &GPRS__RealTimeDiffDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRS__RealTimeDiffDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRS__RealTimeDiffDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for GPRS__RealTimeDiffDescOpt
const TTCN_Typedescriptor_t GPRS__RealTimeDiffDescOpt_descr_ = { "@GSM_RestOctets.GPRS_RealTimeDiffDescOpt", NULL, &GPRS__RealTimeDiffDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t GPRS__RealTimeDiffDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       GPRS__RealTimeDiffDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t GPRS__RealTimeDiffDescOpt_desc_descr_ = { "@GSM_RestOctets.GPRS_RealTimeDiffDescOpt.desc", &BITSTRING_ber_, &GPRS__RealTimeDiffDescOpt_desc_raw_, NULL, &GPRS__RealTimeDiffDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRS__RealTimeDiffDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING GPRS__RealTimeDiffDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_gprs_rt__diff__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_gprs_rt__diff__desc
const TTCN_Typedescriptor_t SI2quaterRestOctets_gprs_rt__diff__desc_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.gprs.rt_diff_desc", NULL, &SI2quaterRestOctets_gprs_rt__diff__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_gprs_rt__diff__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRS__BSICDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       GPRS__BSICDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t GPRS__BSICDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t GPRS__BSICDescOpt_presence_descr_ = { "@GSM_RestOctets.GPRS_BSICDescOpt.presence", &BITSTRING_ber_, &GPRS__BSICDescOpt_presence_raw_, NULL, &GPRS__BSICDescOpt_presence_xer_, &BITSTRING_json_, &GPRS__BSICDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRS__BSICDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRS__BSICDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for GPRS__BSICDescOpt
const TTCN_Typedescriptor_t GPRS__BSICDescOpt_descr_ = { "@GSM_RestOctets.GPRS_BSICDescOpt", NULL, &GPRS__BSICDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t GPRS__BSICDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       GPRS__BSICDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t GPRS__BSICDescOpt_desc_descr_ = { "@GSM_RestOctets.GPRS_BSICDescOpt.desc", &BITSTRING_ber_, &GPRS__BSICDescOpt_desc_raw_, NULL, &GPRS__BSICDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRS__BSICDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING GPRS__BSICDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_gprs_bsic__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_gprs_bsic__desc
const TTCN_Typedescriptor_t SI2quaterRestOctets_gprs_bsic__desc_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.gprs.bsic_desc", NULL, &SI2quaterRestOctets_gprs_bsic__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_gprs_bsic__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRS__ReportPrioDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       GPRS__ReportPrioDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t GPRS__ReportPrioDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t GPRS__ReportPrioDescOpt_presence_descr_ = { "@GSM_RestOctets.GPRS_ReportPrioDescOpt.presence", &BITSTRING_ber_, &GPRS__ReportPrioDescOpt_presence_raw_, NULL, &GPRS__ReportPrioDescOpt_presence_xer_, &BITSTRING_json_, &GPRS__ReportPrioDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRS__ReportPrioDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRS__ReportPrioDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for GPRS__ReportPrioDescOpt
const TTCN_Typedescriptor_t GPRS__ReportPrioDescOpt_descr_ = { "@GSM_RestOctets.GPRS_ReportPrioDescOpt", NULL, &GPRS__ReportPrioDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t GPRS__ReportPrioDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       GPRS__ReportPrioDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t GPRS__ReportPrioDescOpt_desc_descr_ = { "@GSM_RestOctets.GPRS_ReportPrioDescOpt.desc", &BITSTRING_ber_, &GPRS__ReportPrioDescOpt_desc_raw_, NULL, &GPRS__ReportPrioDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRS__ReportPrioDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING GPRS__ReportPrioDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_gprs_rep__prio__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_gprs_rep__prio__desc
const TTCN_Typedescriptor_t SI2quaterRestOctets_gprs_rep__prio__desc_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.gprs.rep_prio_desc", NULL, &SI2quaterRestOctets_gprs_rep__prio__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_gprs_rep__prio__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_gprs_meas__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_gprs_meas__params__desc
const TTCN_Typedescriptor_t SI2quaterRestOctets_gprs_meas__params__desc_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.gprs.meas_params_desc", NULL, &SI2quaterRestOctets_gprs_meas__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_gprs_meas__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_gprs_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_gprs
const TTCN_Typedescriptor_t SI2quaterRestOctets_gprs_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.gprs", NULL, &SI2quaterRestOctets_gprs_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_gprs_default_coding("RAW");
const TTCN_RAWdescriptor_t NCMeasParamsOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       NCMeasParamsOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t NCMeasParamsOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t NCMeasParamsOpt_presence_descr_ = { "@GSM_RestOctets.NCMeasParamsOpt.presence", &BITSTRING_ber_, &NCMeasParamsOpt_presence_raw_, NULL, &NCMeasParamsOpt_presence_xer_, &BITSTRING_json_, &NCMeasParamsOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING NCMeasParamsOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t NCMeasParamsOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for NCMeasParamsOpt
const TTCN_Typedescriptor_t NCMeasParamsOpt_descr_ = { "@GSM_RestOctets.NCMeasParamsOpt", NULL, &NCMeasParamsOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t NCMeasParams_nco_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       NCMeasParams_nco_xer_ = { {"nco>\n", "nco>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t NCMeasParams_nco_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t NCMeasParams_nco_descr_ = { "@GSM_RestOctets.NCMeasParams.nco", &BITSTRING_ber_, &NCMeasParams_nco_raw_, NULL, &NCMeasParams_nco_xer_, &BITSTRING_json_, &NCMeasParams_nco_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING NCMeasParams_nco_default_coding("RAW");
const TTCN_RAWdescriptor_t NCMeasParams_p__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       NCMeasParams_p__presence_xer_ = { {"p_presence>\n", "p_presence>\n"}, {12, 12}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t NCMeasParams_p__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t NCMeasParams_p__presence_descr_ = { "@GSM_RestOctets.NCMeasParams.p_presence", &BITSTRING_ber_, &NCMeasParams_p__presence_raw_, NULL, &NCMeasParams_p__presence_xer_, &BITSTRING_json_, &NCMeasParams_p__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING NCMeasParams_p__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t NCMeasParams_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for NCMeasParams
const TTCN_Typedescriptor_t NCMeasParams_descr_ = { "@GSM_RestOctets.NCMeasParams", NULL, &NCMeasParams_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t NCMeasPeriods_non__drx__period_raw_ = {3,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,3,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       NCMeasPeriods_non__drx__period_xer_ = { {"non_drx_period>\n", "non_drx_period>\n"}, {16, 16}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t NCMeasPeriods_non__drx__period_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t NCMeasPeriods_non__drx__period_descr_ = { "@GSM_RestOctets.NCMeasPeriods.non_drx_period", &BITSTRING_ber_, &NCMeasPeriods_non__drx__period_raw_, NULL, &NCMeasPeriods_non__drx__period_xer_, &BITSTRING_json_, &NCMeasPeriods_non__drx__period_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING NCMeasPeriods_non__drx__period_default_coding("RAW");
const TTCN_RAWdescriptor_t NCMeasPeriods_rep__period__i_raw_ = {3,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,3,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       NCMeasPeriods_rep__period__i_xer_ = { {"rep_period_i>\n", "rep_period_i>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t NCMeasPeriods_rep__period__i_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t NCMeasPeriods_rep__period__i_descr_ = { "@GSM_RestOctets.NCMeasPeriods.rep_period_i", &BITSTRING_ber_, &NCMeasPeriods_rep__period__i_raw_, NULL, &NCMeasPeriods_rep__period__i_xer_, &BITSTRING_json_, &NCMeasPeriods_rep__period__i_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING NCMeasPeriods_rep__period__i_default_coding("RAW");
const TTCN_RAWdescriptor_t NCMeasPeriods_rep__period__t_raw_ = {3,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,3,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       NCMeasPeriods_rep__period__t_xer_ = { {"rep_period_t>\n", "rep_period_t>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t NCMeasPeriods_rep__period__t_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t NCMeasPeriods_rep__period__t_descr_ = { "@GSM_RestOctets.NCMeasPeriods.rep_period_t", &BITSTRING_ber_, &NCMeasPeriods_rep__period__t_raw_, NULL, &NCMeasPeriods_rep__period__t_xer_, &BITSTRING_json_, &NCMeasPeriods_rep__period__t_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING NCMeasPeriods_rep__period__t_default_coding("RAW");
const TTCN_RAWdescriptor_t NCMeasPeriods_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for NCMeasPeriods
const TTCN_Typedescriptor_t NCMeasPeriods_descr_ = { "@GSM_RestOctets.NCMeasPeriods", NULL, &NCMeasPeriods_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING NCMeasPeriods_default_coding("RAW");
const TTCN_RAWdescriptor_t NCMeasParams_p_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for NCMeasParams_p
const TTCN_Typedescriptor_t NCMeasParams_p_descr_ = { "@GSM_RestOctets.NCMeasParams.p", NULL, &NCMeasParams_p_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING NCMeasParams_p_default_coding("RAW");
UNIVERSAL_CHARSTRING NCMeasParams_default_coding("RAW");
const TTCN_RAWdescriptor_t NCMeasParamsOpt_params_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for NCMeasParamsOpt_params
const TTCN_Typedescriptor_t NCMeasParamsOpt_params_descr_ = { "@GSM_RestOctets.NCMeasParamsOpt.params", NULL, &NCMeasParamsOpt_params_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING NCMeasParamsOpt_params_default_coding("RAW");
UNIVERSAL_CHARSTRING NCMeasParamsOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_nc__meas__params_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_nc__meas__params
const TTCN_Typedescriptor_t SI2quaterRestOctets_nc__meas__params_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.nc_meas_params", NULL, &SI2quaterRestOctets_nc__meas__params_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_nc__meas__params_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterExtInfoOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterExtInfoOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterExtInfoOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterExtInfoOpt_presence_descr_ = { "@GSM_RestOctets.SI2quaterExtInfoOpt.presence", &BITSTRING_ber_, &SI2quaterExtInfoOpt_presence_raw_, NULL, &SI2quaterExtInfoOpt_presence_xer_, &BITSTRING_json_, &SI2quaterExtInfoOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterExtInfoOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterExtInfoOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterExtInfoOpt
const TTCN_Typedescriptor_t SI2quaterExtInfoOpt_descr_ = { "@GSM_RestOctets.SI2quaterExtInfoOpt", NULL, &SI2quaterExtInfoOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI2quaterExtInfo_len_raw_ = {8,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,1,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterExtInfo_len_xer_ = { {"len>\n", "len>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterExtInfo_len_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterExtInfo_len_descr_ = { "@GSM_RestOctets.SI2quaterExtInfo.len", &INTEGER_ber_, &SI2quaterExtInfo_len_raw_, &INTEGER_text_, &SI2quaterExtInfo_len_xer_, &INTEGER_json_, &SI2quaterExtInfo_len_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterExtInfo_len_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterExtInfo_padding_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterExtInfo_padding_xer_ = { {"padding>\n", "padding>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t SI2quaterExtInfo_padding_descr_ = { "@GSM_RestOctets.SI2quaterExtInfo.padding", &BITSTRING_ber_, &SI2quaterExtInfo_padding_raw_, NULL, &SI2quaterExtInfo_padding_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterExtInfo_padding_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterExtInfo_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterExtInfo
const TTCN_Typedescriptor_t SI2quaterExtInfo_descr_ = { "@GSM_RestOctets.SI2quaterExtInfo", NULL, &SI2quaterExtInfo_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t CCNSupportDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       CCNSupportDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t CCNSupportDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t CCNSupportDescOpt_presence_descr_ = { "@GSM_RestOctets.CCNSupportDescOpt.presence", &BITSTRING_ber_, &CCNSupportDescOpt_presence_raw_, NULL, &CCNSupportDescOpt_presence_xer_, &BITSTRING_json_, &CCNSupportDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING CCNSupportDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t CCNSupportDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for CCNSupportDescOpt
const TTCN_Typedescriptor_t CCNSupportDescOpt_descr_ = { "@GSM_RestOctets.CCNSupportDescOpt", NULL, &CCNSupportDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t CCNSupportDesc_nr__of__cells_raw_ = {7,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,1,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       CCNSupportDesc_nr__of__cells_xer_ = { {"nr_of_cells>\n", "nr_of_cells>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t CCNSupportDesc_nr__of__cells_descr_ = { "@GSM_RestOctets.CCNSupportDesc.nr_of_cells", &INTEGER_ber_, &CCNSupportDesc_nr__of__cells_raw_, &INTEGER_text_, &CCNSupportDesc_nr__of__cells_xer_, &INTEGER_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING CCNSupportDesc_nr__of__cells_default_coding("RAW");
const TTCN_RAWdescriptor_t CCNSupportDesc_ccn__supported_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       CCNSupportDesc_ccn__supported_xer_ = { {"ccn_supported>\n", "ccn_supported>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t CCNSupportDesc_ccn__supported_descr_ = { "@GSM_RestOctets.CCNSupportDesc.ccn_supported", &BITSTRING_ber_, &CCNSupportDesc_ccn__supported_raw_, NULL, &CCNSupportDesc_ccn__supported_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING CCNSupportDesc_ccn__supported_default_coding("RAW");
const TTCN_RAWdescriptor_t CCNSupportDesc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for CCNSupportDesc
const TTCN_Typedescriptor_t CCNSupportDesc_descr_ = { "@GSM_RestOctets.CCNSupportDesc", NULL, &CCNSupportDesc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING CCNSupportDesc_default_coding("RAW");
const TTCN_RAWdescriptor_t CCNSupportDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for CCNSupportDescOpt_desc
const TTCN_Typedescriptor_t CCNSupportDescOpt_desc_descr_ = { "@GSM_RestOctets.CCNSupportDescOpt.desc", NULL, &CCNSupportDescOpt_desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING CCNSupportDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING CCNSupportDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterExtInfo_ccn__supp__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterExtInfo_ccn__supp__desc
const TTCN_Typedescriptor_t SI2quaterExtInfo_ccn__supp__desc_descr_ = { "@GSM_RestOctets.SI2quaterExtInfo.ccn_supp_desc", NULL, &SI2quaterExtInfo_ccn__supp__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterExtInfo_ccn__supp__desc_default_coding("RAW");
UNIVERSAL_CHARSTRING SI2quaterExtInfo_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterExtInfoOpt_info_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterExtInfoOpt_info
const TTCN_Typedescriptor_t SI2quaterExtInfoOpt_info_descr_ = { "@GSM_RestOctets.SI2quaterExtInfoOpt.info", NULL, &SI2quaterExtInfoOpt_info_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterExtInfoOpt_info_default_coding("RAW");
UNIVERSAL_CHARSTRING SI2quaterExtInfoOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_ext__info_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_ext__info
const TTCN_Typedescriptor_t SI2quaterRestOctets_ext__info_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.ext_info", NULL, &SI2quaterRestOctets_ext__info_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_ext__info_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__NeighDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__NeighDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__NeighDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__NeighDescOpt_presence_descr_ = { "@GSM_RestOctets.UTRAN_NeighDescOpt.presence", &BITSTRING_ber_, &UTRAN__NeighDescOpt_presence_raw_, NULL, &UTRAN__NeighDescOpt_presence_xer_, &BITSTRING_json_, &UTRAN__NeighDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__NeighDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__NeighDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__NeighDescOpt
const TTCN_Typedescriptor_t UTRAN__NeighDescOpt_descr_ = { "@GSM_RestOctets.UTRAN_NeighDescOpt", NULL, &UTRAN__NeighDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UTRAN__NeighDesc_idx__start__3g__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__NeighDesc_idx__start__3g__presence_xer_ = { {"idx_start_3g_presence>\n", "idx_start_3g_presence>\n"}, {23, 23}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__NeighDesc_idx__start__3g__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__NeighDesc_idx__start__3g__presence_descr_ = { "@GSM_RestOctets.UTRAN_NeighDesc.idx_start_3g_presence", &BITSTRING_ber_, &UTRAN__NeighDesc_idx__start__3g__presence_raw_, NULL, &UTRAN__NeighDesc_idx__start__3g__presence_xer_, &BITSTRING_json_, &UTRAN__NeighDesc_idx__start__3g__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__NeighDesc_idx__start__3g__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__NeighDesc_abs__idx__start__emr__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__NeighDesc_abs__idx__start__emr__presence_xer_ = { {"abs_idx_start_emr_presence>\n", "abs_idx_start_emr_presence>\n"}, {28, 28}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__NeighDesc_abs__idx__start__emr__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__NeighDesc_abs__idx__start__emr__presence_descr_ = { "@GSM_RestOctets.UTRAN_NeighDesc.abs_idx_start_emr_presence", &BITSTRING_ber_, &UTRAN__NeighDesc_abs__idx__start__emr__presence_raw_, NULL, &UTRAN__NeighDesc_abs__idx__start__emr__presence_xer_, &BITSTRING_json_, &UTRAN__NeighDesc_abs__idx__start__emr__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__NeighDesc_abs__idx__start__emr__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__FDDDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__FDDDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__FDDDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__FDDDescOpt_presence_descr_ = { "@GSM_RestOctets.UTRAN_FDDDescOpt.presence", &BITSTRING_ber_, &UTRAN__FDDDescOpt_presence_raw_, NULL, &UTRAN__FDDDescOpt_presence_xer_, &BITSTRING_json_, &UTRAN__FDDDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__FDDDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__FDDDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__FDDDescOpt
const TTCN_Typedescriptor_t UTRAN__FDDDescOpt_descr_ = { "@GSM_RestOctets.UTRAN_FDDDescOpt", NULL, &UTRAN__FDDDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UTRAN__FDDDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__FDDDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t UTRAN__FDDDescOpt_desc_descr_ = { "@GSM_RestOctets.UTRAN_FDDDescOpt.desc", &BITSTRING_ber_, &UTRAN__FDDDescOpt_desc_raw_, NULL, &UTRAN__FDDDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__FDDDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING UTRAN__FDDDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__NeighDesc_fdd__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__NeighDesc_fdd__desc
const TTCN_Typedescriptor_t UTRAN__NeighDesc_fdd__desc_descr_ = { "@GSM_RestOctets.UTRAN_NeighDesc.fdd_desc", NULL, &UTRAN__NeighDesc_fdd__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__NeighDesc_fdd__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__TDDDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__TDDDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__TDDDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__TDDDescOpt_presence_descr_ = { "@GSM_RestOctets.UTRAN_TDDDescOpt.presence", &BITSTRING_ber_, &UTRAN__TDDDescOpt_presence_raw_, NULL, &UTRAN__TDDDescOpt_presence_xer_, &BITSTRING_json_, &UTRAN__TDDDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__TDDDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__TDDDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__TDDDescOpt
const TTCN_Typedescriptor_t UTRAN__TDDDescOpt_descr_ = { "@GSM_RestOctets.UTRAN_TDDDescOpt", NULL, &UTRAN__TDDDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UTRAN__TDDDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__TDDDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t UTRAN__TDDDescOpt_desc_descr_ = { "@GSM_RestOctets.UTRAN_TDDDescOpt.desc", &BITSTRING_ber_, &UTRAN__TDDDescOpt_desc_raw_, NULL, &UTRAN__TDDDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__TDDDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING UTRAN__TDDDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__NeighDesc_tdd__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__NeighDesc_tdd__desc
const TTCN_Typedescriptor_t UTRAN__NeighDesc_tdd__desc_descr_ = { "@GSM_RestOctets.UTRAN_NeighDesc.tdd_desc", NULL, &UTRAN__NeighDesc_tdd__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__NeighDesc_tdd__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__NeighDesc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__NeighDesc
const TTCN_Typedescriptor_t UTRAN__NeighDesc_descr_ = { "@GSM_RestOctets.UTRAN_NeighDesc", NULL, &UTRAN__NeighDesc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UTRAN__NeighDesc_idx__start__3g_raw_ = {7,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__NeighDesc_idx__start__3g_xer_ = { {"idx_start_3g>\n", "idx_start_3g>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__NeighDesc_idx__start__3g_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__NeighDesc_idx__start__3g_descr_ = { "@GSM_RestOctets.UTRAN_NeighDesc.idx_start_3g", &INTEGER_ber_, &UTRAN__NeighDesc_idx__start__3g_raw_, &INTEGER_text_, &UTRAN__NeighDesc_idx__start__3g_xer_, &INTEGER_json_, &UTRAN__NeighDesc_idx__start__3g_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__NeighDesc_idx__start__3g_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__NeighDesc_abs__idx__start__emr_raw_ = {7,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__NeighDesc_abs__idx__start__emr_xer_ = { {"abs_idx_start_emr>\n", "abs_idx_start_emr>\n"}, {19, 19}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__NeighDesc_abs__idx__start__emr_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__NeighDesc_abs__idx__start__emr_descr_ = { "@GSM_RestOctets.UTRAN_NeighDesc.abs_idx_start_emr", &INTEGER_ber_, &UTRAN__NeighDesc_abs__idx__start__emr_raw_, &INTEGER_text_, &UTRAN__NeighDesc_abs__idx__start__emr_xer_, &INTEGER_json_, &UTRAN__NeighDesc_abs__idx__start__emr_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__NeighDesc_abs__idx__start__emr_default_coding("RAW");
UNIVERSAL_CHARSTRING UTRAN__NeighDesc_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__NeighDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__NeighDescOpt_desc
const TTCN_Typedescriptor_t UTRAN__NeighDescOpt_desc_descr_ = { "@GSM_RestOctets.UTRAN_NeighDescOpt.desc", NULL, &UTRAN__NeighDescOpt_desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__NeighDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING UTRAN__NeighDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_utran__neigh__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_utran__neigh__desc
const TTCN_Typedescriptor_t SI2quaterRestOctets_utran__neigh__desc_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.utran_neigh_desc", NULL, &SI2quaterRestOctets_utran__neigh__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_utran__neigh__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__MeasParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__MeasParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__MeasParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__MeasParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.UTRAN_MeasParamsDescOpt.presence", &BITSTRING_ber_, &UTRAN__MeasParamsDescOpt_presence_raw_, NULL, &UTRAN__MeasParamsDescOpt_presence_xer_, &BITSTRING_json_, &UTRAN__MeasParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__MeasParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__MeasParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__MeasParamsDescOpt
const TTCN_Typedescriptor_t UTRAN__MeasParamsDescOpt_descr_ = { "@GSM_RestOctets.UTRAN_MeasParamsDescOpt", NULL, &UTRAN__MeasParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UTRAN__MeasParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__MeasParamsDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t UTRAN__MeasParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.UTRAN_MeasParamsDescOpt.desc", &BITSTRING_ber_, &UTRAN__MeasParamsDescOpt_desc_raw_, NULL, &UTRAN__MeasParamsDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__MeasParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING UTRAN__MeasParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_utran__meas__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_utran__meas__params__desc
const TTCN_Typedescriptor_t SI2quaterRestOctets_utran__meas__params__desc_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.utran_meas_params_desc", NULL, &SI2quaterRestOctets_utran__meas__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_utran__meas__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__GPRSMeasParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__GPRSMeasParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__GPRSMeasParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__GPRSMeasParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.UTRAN_GPRSMeasParamsDescOpt.presence", &BITSTRING_ber_, &UTRAN__GPRSMeasParamsDescOpt_presence_raw_, NULL, &UTRAN__GPRSMeasParamsDescOpt_presence_xer_, &BITSTRING_json_, &UTRAN__GPRSMeasParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__GPRSMeasParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__GPRSMeasParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__GPRSMeasParamsDescOpt
const TTCN_Typedescriptor_t UTRAN__GPRSMeasParamsDescOpt_descr_ = { "@GSM_RestOctets.UTRAN_GPRSMeasParamsDescOpt", NULL, &UTRAN__GPRSMeasParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UTRAN__GPRSMeasParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__GPRSMeasParamsDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t UTRAN__GPRSMeasParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.UTRAN_GPRSMeasParamsDescOpt.desc", &BITSTRING_ber_, &UTRAN__GPRSMeasParamsDescOpt_desc_raw_, NULL, &UTRAN__GPRSMeasParamsDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__GPRSMeasParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING UTRAN__GPRSMeasParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_utran__gprs__meas__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_utran__gprs__meas__params__desc
const TTCN_Typedescriptor_t SI2quaterRestOctets_utran__gprs__meas__params__desc_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.utran_gprs_meas_params_desc", NULL, &SI2quaterRestOctets_utran__gprs__meas__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_utran__gprs__meas__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterAdditions_rel5__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI2quaterAdditions_rel5__presence_xer_ = { {"rel5_presence>\n", "rel5_presence>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterAdditions_rel5__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterAdditions_rel5__presence_descr_ = { "@GSM_RestOctets.SI2quaterAdditions.rel5_presence", &BITSTRING_ber_, &SI2quaterAdditions_rel5__presence_raw_, NULL, &SI2quaterAdditions_rel5__presence_xer_, &BITSTRING_json_, &SI2quaterAdditions_rel5__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterAdditions_rel5__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterAdditions_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterAdditions
const TTCN_Typedescriptor_t SI2quaterAdditions_descr_ = { "@GSM_RestOctets.SI2quaterAdditions", NULL, &SI2quaterAdditions_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UMTS__AddMeasParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UMTS__AddMeasParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDescOpt.presence", &BITSTRING_ber_, &UMTS__AddMeasParamsDescOpt_presence_raw_, NULL, &UMTS__AddMeasParamsDescOpt_presence_xer_, &BITSTRING_json_, &UMTS__AddMeasParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UMTS__AddMeasParamsDescOpt
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDescOpt_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDescOpt", NULL, &UMTS__AddMeasParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDesc_fdd__qmin__offset_raw_ = {3,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,3,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UMTS__AddMeasParamsDesc_fdd__qmin__offset_xer_ = { {"fdd_qmin_offset>\n", "fdd_qmin_offset>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UMTS__AddMeasParamsDesc_fdd__qmin__offset_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDesc_fdd__qmin__offset_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDesc.fdd_qmin_offset", &BITSTRING_ber_, &UMTS__AddMeasParamsDesc_fdd__qmin__offset_raw_, NULL, &UMTS__AddMeasParamsDesc_fdd__qmin__offset_xer_, &BITSTRING_json_, &UMTS__AddMeasParamsDesc_fdd__qmin__offset_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDesc_fdd__qmin__offset_default_coding("RAW");
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDesc_fdd__rscpmin_raw_ = {4,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,4,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UMTS__AddMeasParamsDesc_fdd__rscpmin_xer_ = { {"fdd_rscpmin>\n", "fdd_rscpmin>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UMTS__AddMeasParamsDesc_fdd__rscpmin_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDesc_fdd__rscpmin_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDesc.fdd_rscpmin", &BITSTRING_ber_, &UMTS__AddMeasParamsDesc_fdd__rscpmin_raw_, NULL, &UMTS__AddMeasParamsDesc_fdd__rscpmin_xer_, &BITSTRING_json_, &UMTS__AddMeasParamsDesc_fdd__rscpmin_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDesc_fdd__rscpmin_default_coding("RAW");
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDesc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UMTS__AddMeasParamsDesc
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDesc_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDesc", NULL, &UMTS__AddMeasParamsDesc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDesc_default_coding("RAW");
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UMTS__AddMeasParamsDescOpt_desc
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDescOpt.desc", NULL, &UMTS__AddMeasParamsDescOpt_desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR5Additions_umts__add__meas__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR5Additions_umts__add__meas__params__desc
const TTCN_Typedescriptor_t SI2quaterR5Additions_umts__add__meas__params__desc_descr_ = { "@GSM_RestOctets.SI2quaterR5Additions.umts_add_meas_params_desc", NULL, &SI2quaterR5Additions_umts__add__meas__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR5Additions_umts__add__meas__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDesc2Opt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UMTS__AddMeasParamsDesc2Opt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UMTS__AddMeasParamsDesc2Opt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDesc2Opt_presence_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDesc2Opt.presence", &BITSTRING_ber_, &UMTS__AddMeasParamsDesc2Opt_presence_raw_, NULL, &UMTS__AddMeasParamsDesc2Opt_presence_xer_, &BITSTRING_json_, &UMTS__AddMeasParamsDesc2Opt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDesc2Opt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDesc2Opt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UMTS__AddMeasParamsDesc2Opt
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDesc2Opt_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDesc2Opt", NULL, &UMTS__AddMeasParamsDesc2Opt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDesc2Opt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UMTS__AddMeasParamsDesc2Opt_desc
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDesc2Opt_desc_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDesc2Opt.desc", NULL, &UMTS__AddMeasParamsDesc2Opt_desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDesc2Opt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDesc2Opt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR5Additions_umts__add__meas__params__desc2_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR5Additions_umts__add__meas__params__desc2
const TTCN_Typedescriptor_t SI2quaterR5Additions_umts__add__meas__params__desc2_descr_ = { "@GSM_RestOctets.SI2quaterR5Additions.umts_add_meas_params_desc2", NULL, &SI2quaterR5Additions_umts__add__meas__params__desc2_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR5Additions_umts__add__meas__params__desc2_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR5Additions_rel6__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI2quaterR5Additions_rel6__presence_xer_ = { {"rel6_presence>\n", "rel6_presence>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterR5Additions_rel6__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterR5Additions_rel6__presence_descr_ = { "@GSM_RestOctets.SI2quaterR5Additions.rel6_presence", &BITSTRING_ber_, &SI2quaterR5Additions_rel6__presence_raw_, NULL, &SI2quaterR5Additions_rel6__presence_xer_, &BITSTRING_json_, &SI2quaterR5Additions_rel6__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR5Additions_rel6__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR5Additions_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR5Additions
const TTCN_Typedescriptor_t SI2quaterR5Additions_descr_ = { "@GSM_RestOctets.SI2quaterR5Additions", NULL, &SI2quaterR5Additions_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI2quaterR6Additions_umts__ccn__active_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterR6Additions_umts__ccn__active_xer_ = { {"umts_ccn_active>\n", "umts_ccn_active>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterR6Additions_umts__ccn__active_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterR6Additions_umts__ccn__active_descr_ = { "@GSM_RestOctets.SI2quaterR6Additions.umts_ccn_active", &BITSTRING_ber_, &SI2quaterR6Additions_umts__ccn__active_raw_, NULL, &SI2quaterR6Additions_umts__ccn__active_xer_, &BITSTRING_json_, &SI2quaterR6Additions_umts__ccn__active_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR6Additions_umts__ccn__active_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR6Additions_rel7__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI2quaterR6Additions_rel7__presence_xer_ = { {"rel7_presence>\n", "rel7_presence>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterR6Additions_rel7__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterR6Additions_rel7__presence_descr_ = { "@GSM_RestOctets.SI2quaterR6Additions.rel7_presence", &BITSTRING_ber_, &SI2quaterR6Additions_rel7__presence_raw_, NULL, &SI2quaterR6Additions_rel7__presence_xer_, &BITSTRING_json_, &SI2quaterR6Additions_rel7__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR6Additions_rel7__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR6Additions_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR6Additions
const TTCN_Typedescriptor_t SI2quaterR6Additions_descr_ = { "@GSM_RestOctets.SI2quaterR6Additions", NULL, &SI2quaterR6Additions_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t Rel7RepOffseThresholdOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       Rel7RepOffseThresholdOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t Rel7RepOffseThresholdOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t Rel7RepOffseThresholdOpt_presence_descr_ = { "@GSM_RestOctets.Rel7RepOffseThresholdOpt.presence", &BITSTRING_ber_, &Rel7RepOffseThresholdOpt_presence_raw_, NULL, &Rel7RepOffseThresholdOpt_presence_xer_, &BITSTRING_json_, &Rel7RepOffseThresholdOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel7RepOffseThresholdOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel7RepOffseThresholdOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel7RepOffseThresholdOpt
const TTCN_Typedescriptor_t Rel7RepOffseThresholdOpt_descr_ = { "@GSM_RestOctets.Rel7RepOffseThresholdOpt", NULL, &Rel7RepOffseThresholdOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t Rel7RepOffseThreshold_offset_raw_ = {3,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,3,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       Rel7RepOffseThreshold_offset_xer_ = { {"offset>\n", "offset>\n"}, {8, 8}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t Rel7RepOffseThreshold_offset_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t Rel7RepOffseThreshold_offset_descr_ = { "@GSM_RestOctets.Rel7RepOffseThreshold.offset", &BITSTRING_ber_, &Rel7RepOffseThreshold_offset_raw_, NULL, &Rel7RepOffseThreshold_offset_xer_, &BITSTRING_json_, &Rel7RepOffseThreshold_offset_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel7RepOffseThreshold_offset_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel7RepOffseThreshold_threshold_raw_ = {3,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,3,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       Rel7RepOffseThreshold_threshold_xer_ = { {"threshold>\n", "threshold>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t Rel7RepOffseThreshold_threshold_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t Rel7RepOffseThreshold_threshold_descr_ = { "@GSM_RestOctets.Rel7RepOffseThreshold.threshold", &BITSTRING_ber_, &Rel7RepOffseThreshold_threshold_raw_, NULL, &Rel7RepOffseThreshold_threshold_xer_, &BITSTRING_json_, &Rel7RepOffseThreshold_threshold_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel7RepOffseThreshold_threshold_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel7RepOffseThreshold_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel7RepOffseThreshold
const TTCN_Typedescriptor_t Rel7RepOffseThreshold_descr_ = { "@GSM_RestOctets.Rel7RepOffseThreshold", NULL, &Rel7RepOffseThreshold_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel7RepOffseThreshold_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel7RepOffseThresholdOpt_val_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel7RepOffseThresholdOpt_val
const TTCN_Typedescriptor_t Rel7RepOffseThresholdOpt_val_descr_ = { "@GSM_RestOctets.Rel7RepOffseThresholdOpt.val", NULL, &Rel7RepOffseThresholdOpt_val_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel7RepOffseThresholdOpt_val_default_coding("RAW");
UNIVERSAL_CHARSTRING Rel7RepOffseThresholdOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR7Additions_rep700_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR7Additions_rep700
const TTCN_Typedescriptor_t SI2quaterR7Additions_rep700_descr_ = { "@GSM_RestOctets.SI2quaterR7Additions.rep700", NULL, &SI2quaterR7Additions_rep700_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR7Additions_rep700_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR7Additions_rep810_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR7Additions_rep810
const TTCN_Typedescriptor_t SI2quaterR7Additions_rep810_descr_ = { "@GSM_RestOctets.SI2quaterR7Additions.rep810", NULL, &SI2quaterR7Additions_rep810_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR7Additions_rep810_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR7Additions_rel8__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI2quaterR7Additions_rel8__presence_xer_ = { {"rel8_presence>\n", "rel8_presence>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterR7Additions_rel8__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterR7Additions_rel8__presence_descr_ = { "@GSM_RestOctets.SI2quaterR7Additions.rel8_presence", &BITSTRING_ber_, &SI2quaterR7Additions_rel8__presence_raw_, NULL, &SI2quaterR7Additions_rel8__presence_xer_, &BITSTRING_json_, &SI2quaterR7Additions_rel8__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR7Additions_rel8__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR7Additions_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR7Additions
const TTCN_Typedescriptor_t SI2quaterR7Additions_descr_ = { "@GSM_RestOctets.SI2quaterR7Additions", NULL, &SI2quaterR7Additions_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t Rel8PrioEUTRANParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       Rel8PrioEUTRANParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t Rel8PrioEUTRANParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t Rel8PrioEUTRANParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.Rel8PrioEUTRANParamsDescOpt.presence", &BITSTRING_ber_, &Rel8PrioEUTRANParamsDescOpt_presence_raw_, NULL, &Rel8PrioEUTRANParamsDescOpt_presence_xer_, &BITSTRING_json_, &Rel8PrioEUTRANParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8PrioEUTRANParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8PrioEUTRANParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel8PrioEUTRANParamsDescOpt
const TTCN_Typedescriptor_t Rel8PrioEUTRANParamsDescOpt_descr_ = { "@GSM_RestOctets.Rel8PrioEUTRANParamsDescOpt", NULL, &Rel8PrioEUTRANParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t ServingCellPrioParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       ServingCellPrioParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t ServingCellPrioParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t ServingCellPrioParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.ServingCellPrioParamsDescOpt.presence", &BITSTRING_ber_, &ServingCellPrioParamsDescOpt_presence_raw_, NULL, &ServingCellPrioParamsDescOpt_presence_xer_, &BITSTRING_json_, &ServingCellPrioParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ServingCellPrioParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t ServingCellPrioParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for ServingCellPrioParamsDescOpt
const TTCN_Typedescriptor_t ServingCellPrioParamsDescOpt_descr_ = { "@GSM_RestOctets.ServingCellPrioParamsDescOpt", NULL, &ServingCellPrioParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t ServingCellPrioParamsDesc_geran__priority_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       ServingCellPrioParamsDesc_geran__priority_xer_ = { {"geran_priority>\n", "geran_priority>\n"}, {16, 16}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t ServingCellPrioParamsDesc_geran__priority_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t ServingCellPrioParamsDesc_geran__priority_descr_ = { "@GSM_RestOctets.ServingCellPrioParamsDesc.geran_priority", &INTEGER_ber_, &ServingCellPrioParamsDesc_geran__priority_raw_, &INTEGER_text_, &ServingCellPrioParamsDesc_geran__priority_xer_, &INTEGER_json_, &ServingCellPrioParamsDesc_geran__priority_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ServingCellPrioParamsDesc_geran__priority_default_coding("RAW");
const TTCN_RAWdescriptor_t ServingCellPrioParamsDesc_thresh__priority__search_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       ServingCellPrioParamsDesc_thresh__priority__search_xer_ = { {"thresh_priority_search>\n", "thresh_priority_search>\n"}, {24, 24}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t ServingCellPrioParamsDesc_thresh__priority__search_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t ServingCellPrioParamsDesc_thresh__priority__search_descr_ = { "@GSM_RestOctets.ServingCellPrioParamsDesc.thresh_priority_search", &INTEGER_ber_, &ServingCellPrioParamsDesc_thresh__priority__search_raw_, &INTEGER_text_, &ServingCellPrioParamsDesc_thresh__priority__search_xer_, &INTEGER_json_, &ServingCellPrioParamsDesc_thresh__priority__search_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ServingCellPrioParamsDesc_thresh__priority__search_default_coding("RAW");
const TTCN_RAWdescriptor_t ServingCellPrioParamsDesc_thresh__gsm__low_raw_ = {4,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       ServingCellPrioParamsDesc_thresh__gsm__low_xer_ = { {"thresh_gsm_low>\n", "thresh_gsm_low>\n"}, {16, 16}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t ServingCellPrioParamsDesc_thresh__gsm__low_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t ServingCellPrioParamsDesc_thresh__gsm__low_descr_ = { "@GSM_RestOctets.ServingCellPrioParamsDesc.thresh_gsm_low", &INTEGER_ber_, &ServingCellPrioParamsDesc_thresh__gsm__low_raw_, &INTEGER_text_, &ServingCellPrioParamsDesc_thresh__gsm__low_xer_, &INTEGER_json_, &ServingCellPrioParamsDesc_thresh__gsm__low_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ServingCellPrioParamsDesc_thresh__gsm__low_default_coding("RAW");
const TTCN_RAWdescriptor_t ServingCellPrioParamsDesc_h__prio_raw_ = {2,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       ServingCellPrioParamsDesc_h__prio_xer_ = { {"h_prio>\n", "h_prio>\n"}, {8, 8}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t ServingCellPrioParamsDesc_h__prio_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t ServingCellPrioParamsDesc_h__prio_descr_ = { "@GSM_RestOctets.ServingCellPrioParamsDesc.h_prio", &INTEGER_ber_, &ServingCellPrioParamsDesc_h__prio_raw_, &INTEGER_text_, &ServingCellPrioParamsDesc_h__prio_xer_, &INTEGER_json_, &ServingCellPrioParamsDesc_h__prio_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ServingCellPrioParamsDesc_h__prio_default_coding("RAW");
const TTCN_RAWdescriptor_t ServingCellPrioParamsDesc_t__reselection_raw_ = {2,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       ServingCellPrioParamsDesc_t__reselection_xer_ = { {"t_reselection>\n", "t_reselection>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t ServingCellPrioParamsDesc_t__reselection_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t ServingCellPrioParamsDesc_t__reselection_descr_ = { "@GSM_RestOctets.ServingCellPrioParamsDesc.t_reselection", &INTEGER_ber_, &ServingCellPrioParamsDesc_t__reselection_raw_, &INTEGER_text_, &ServingCellPrioParamsDesc_t__reselection_xer_, &INTEGER_json_, &ServingCellPrioParamsDesc_t__reselection_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ServingCellPrioParamsDesc_t__reselection_default_coding("RAW");
const TTCN_RAWdescriptor_t ServingCellPrioParamsDesc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for ServingCellPrioParamsDesc
const TTCN_Typedescriptor_t ServingCellPrioParamsDesc_descr_ = { "@GSM_RestOctets.ServingCellPrioParamsDesc", NULL, &ServingCellPrioParamsDesc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ServingCellPrioParamsDesc_default_coding("RAW");
const TTCN_RAWdescriptor_t ServingCellPrioParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for ServingCellPrioParamsDescOpt_desc
const TTCN_Typedescriptor_t ServingCellPrioParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.ServingCellPrioParamsDescOpt.desc", NULL, &ServingCellPrioParamsDescOpt_desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING ServingCellPrioParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING ServingCellPrioParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8PrioEUTRANParamsDesc_sc__prio__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel8PrioEUTRANParamsDesc_sc__prio__params__desc
const TTCN_Typedescriptor_t Rel8PrioEUTRANParamsDesc_sc__prio__params__desc_descr_ = { "@GSM_RestOctets.Rel8PrioEUTRANParamsDesc.sc_prio_params_desc", NULL, &Rel8PrioEUTRANParamsDesc_sc__prio__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8PrioEUTRANParamsDesc_sc__prio__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__PrioParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__PrioParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UTRAN__PrioParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UTRAN__PrioParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.UTRAN_PrioParamsDescOpt.presence", &BITSTRING_ber_, &UTRAN__PrioParamsDescOpt_presence_raw_, NULL, &UTRAN__PrioParamsDescOpt_presence_xer_, &BITSTRING_json_, &UTRAN__PrioParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__PrioParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UTRAN__PrioParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UTRAN__PrioParamsDescOpt
const TTCN_Typedescriptor_t UTRAN__PrioParamsDescOpt_descr_ = { "@GSM_RestOctets.UTRAN_PrioParamsDescOpt", NULL, &UTRAN__PrioParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UTRAN__PrioParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UTRAN__PrioParamsDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t UTRAN__PrioParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.UTRAN_PrioParamsDescOpt.desc", &BITSTRING_ber_, &UTRAN__PrioParamsDescOpt_desc_raw_, NULL, &UTRAN__PrioParamsDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UTRAN__PrioParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING UTRAN__PrioParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8PrioEUTRANParamsDesc_utran__prio__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel8PrioEUTRANParamsDesc_utran__prio__params__desc
const TTCN_Typedescriptor_t Rel8PrioEUTRANParamsDesc_utran__prio__params__desc_descr_ = { "@GSM_RestOctets.Rel8PrioEUTRANParamsDesc.utran_prio_params_desc", NULL, &Rel8PrioEUTRANParamsDesc_utran__prio__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8PrioEUTRANParamsDesc_utran__prio__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__ParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__ParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__ParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDescOpt.presence", &BITSTRING_ber_, &EUTRAN__ParamsDescOpt_presence_raw_, NULL, &EUTRAN__ParamsDescOpt_presence_xer_, &BITSTRING_json_, &EUTRAN__ParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__ParamsDescOpt
const TTCN_Typedescriptor_t EUTRAN__ParamsDescOpt_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDescOpt", NULL, &EUTRAN__ParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_ccn__active_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__ParamsDesc_ccn__active_xer_ = { {"ccn_active>\n", "ccn_active>\n"}, {12, 12}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__ParamsDesc_ccn__active_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_ccn__active_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.ccn_active", &BITSTRING_ber_, &EUTRAN__ParamsDesc_ccn__active_raw_, NULL, &EUTRAN__ParamsDesc_ccn__active_xer_, &BITSTRING_json_, &EUTRAN__ParamsDesc_ccn__active_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_ccn__active_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_e__start_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__ParamsDesc_e__start_xer_ = { {"e_start>\n", "e_start>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__ParamsDesc_e__start_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_e__start_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.e_start", &BITSTRING_ber_, &EUTRAN__ParamsDesc_e__start_raw_, NULL, &EUTRAN__ParamsDesc_e__start_xer_, &BITSTRING_json_, &EUTRAN__ParamsDesc_e__start_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_e__start_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_e__stop_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__ParamsDesc_e__stop_xer_ = { {"e_stop>\n", "e_stop>\n"}, {8, 8}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__ParamsDesc_e__stop_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_e__stop_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.e_stop", &BITSTRING_ber_, &EUTRAN__ParamsDesc_e__stop_raw_, NULL, &EUTRAN__ParamsDesc_e__stop_xer_, &BITSTRING_json_, &EUTRAN__ParamsDesc_e__stop_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_e__stop_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__MeasParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__MeasParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__MeasParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__MeasParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.EUTRAN_MeasParamsDescOpt.presence", &BITSTRING_ber_, &EUTRAN__MeasParamsDescOpt_presence_raw_, NULL, &EUTRAN__MeasParamsDescOpt_presence_xer_, &BITSTRING_json_, &EUTRAN__MeasParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__MeasParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__MeasParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__MeasParamsDescOpt
const TTCN_Typedescriptor_t EUTRAN__MeasParamsDescOpt_descr_ = { "@GSM_RestOctets.EUTRAN_MeasParamsDescOpt", NULL, &EUTRAN__MeasParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__MeasParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__MeasParamsDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t EUTRAN__MeasParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.EUTRAN_MeasParamsDescOpt.desc", &BITSTRING_ber_, &EUTRAN__MeasParamsDescOpt_desc_raw_, NULL, &EUTRAN__MeasParamsDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__MeasParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__MeasParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_meas__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__ParamsDesc_meas__params__desc
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_meas__params__desc_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.meas_params_desc", NULL, &EUTRAN__ParamsDesc_meas__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_meas__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__GPRSMeasParamsDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__GPRSMeasParamsDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__GPRSMeasParamsDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__GPRSMeasParamsDescOpt_presence_descr_ = { "@GSM_RestOctets.EUTRAN_GPRSMeasParamsDescOpt.presence", &BITSTRING_ber_, &EUTRAN__GPRSMeasParamsDescOpt_presence_raw_, NULL, &EUTRAN__GPRSMeasParamsDescOpt_presence_xer_, &BITSTRING_json_, &EUTRAN__GPRSMeasParamsDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__GPRSMeasParamsDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__GPRSMeasParamsDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__GPRSMeasParamsDescOpt
const TTCN_Typedescriptor_t EUTRAN__GPRSMeasParamsDescOpt_descr_ = { "@GSM_RestOctets.EUTRAN_GPRSMeasParamsDescOpt", NULL, &EUTRAN__GPRSMeasParamsDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__GPRSMeasParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__GPRSMeasParamsDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t EUTRAN__GPRSMeasParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.EUTRAN_GPRSMeasParamsDescOpt.desc", &BITSTRING_ber_, &EUTRAN__GPRSMeasParamsDescOpt_desc_raw_, NULL, &EUTRAN__GPRSMeasParamsDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__GPRSMeasParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__GPRSMeasParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_gprs__meas__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__ParamsDesc_gprs__meas__params__desc
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_gprs__meas__params__desc_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.gprs_meas_params_desc", NULL, &EUTRAN__ParamsDesc_gprs__meas__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_gprs__meas__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_repeated__neigh__cells__term_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__ParamsDesc_repeated__neigh__cells__term_xer_ = { {"repeated_neigh_cells_term>\n", "repeated_neigh_cells_term>\n"}, {27, 27}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__ParamsDesc_repeated__neigh__cells__term_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_repeated__neigh__cells__term_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.repeated_neigh_cells_term", &BITSTRING_ber_, &EUTRAN__ParamsDesc_repeated__neigh__cells__term_raw_, NULL, &EUTRAN__ParamsDesc_repeated__neigh__cells__term_xer_, &BITSTRING_json_, &EUTRAN__ParamsDesc_repeated__neigh__cells__term_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_repeated__neigh__cells__term_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_repeated__not__allowed__cells__term_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__ParamsDesc_repeated__not__allowed__cells__term_xer_ = { {"repeated_not_allowed_cells_term>\n", "repeated_not_allowed_cells_term>\n"}, {33, 33}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__ParamsDesc_repeated__not__allowed__cells__term_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_repeated__not__allowed__cells__term_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.repeated_not_allowed_cells_term", &BITSTRING_ber_, &EUTRAN__ParamsDesc_repeated__not__allowed__cells__term_raw_, NULL, &EUTRAN__ParamsDesc_repeated__not__allowed__cells__term_xer_, &BITSTRING_json_, &EUTRAN__ParamsDesc_repeated__not__allowed__cells__term_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_repeated__not__allowed__cells__term_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_pcid2ta__map__list__term_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__ParamsDesc_pcid2ta__map__list__term_xer_ = { {"pcid2ta_map_list_term>\n", "pcid2ta_map_list_term>\n"}, {23, 23}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__ParamsDesc_pcid2ta__map__list__term_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_pcid2ta__map__list__term_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.pcid2ta_map_list_term", &BITSTRING_ber_, &EUTRAN__ParamsDesc_pcid2ta__map__list__term_raw_, NULL, &EUTRAN__ParamsDesc_pcid2ta__map__list__term_xer_, &BITSTRING_json_, &EUTRAN__ParamsDesc_pcid2ta__map__list__term_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_pcid2ta__map__list__term_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__ParamsDesc
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc", NULL, &EUTRAN__ParamsDesc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__RepeatedNeighbourCells_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__RepeatedNeighbourCells
const TTCN_Typedescriptor_t EUTRAN__RepeatedNeighbourCells_descr_ = { "@GSM_RestOctets.EUTRAN_RepeatedNeighbourCells", NULL, &EUTRAN__RepeatedNeighbourCells_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__RepeatedNeighbourCells_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_item__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NeighbourCells_item__ind_xer_ = { {"item_ind>\n", "item_ind>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NeighbourCells_item__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_item__ind_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.item_ind", &BITSTRING_ber_, &EUTRAN__NeighbourCells_item__ind_raw_, NULL, &EUTRAN__NeighbourCells_item__ind_xer_, &BITSTRING_json_, &EUTRAN__NeighbourCells_item__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_item__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_cell__desc__list__term_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NeighbourCells_cell__desc__list__term_xer_ = { {"cell_desc_list_term>\n", "cell_desc_list_term>\n"}, {21, 21}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NeighbourCells_cell__desc__list__term_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_cell__desc__list__term_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.cell_desc_list_term", &BITSTRING_ber_, &EUTRAN__NeighbourCells_cell__desc__list__term_raw_, NULL, &EUTRAN__NeighbourCells_cell__desc__list__term_xer_, &BITSTRING_json_, &EUTRAN__NeighbourCells_cell__desc__list__term_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_cell__desc__list__term_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_prio__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NeighbourCells_prio__presence_xer_ = { {"prio_presence>\n", "prio_presence>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NeighbourCells_prio__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_prio__presence_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.prio_presence", &BITSTRING_ber_, &EUTRAN__NeighbourCells_prio__presence_raw_, NULL, &EUTRAN__NeighbourCells_prio__presence_xer_, &BITSTRING_json_, &EUTRAN__NeighbourCells_prio__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_prio__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_thresh__high_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NeighbourCells_thresh__high_xer_ = { {"thresh_high>\n", "thresh_high>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NeighbourCells_thresh__high_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_thresh__high_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.thresh_high", &INTEGER_ber_, &EUTRAN__NeighbourCells_thresh__high_raw_, &INTEGER_text_, &EUTRAN__NeighbourCells_thresh__high_xer_, &INTEGER_json_, &EUTRAN__NeighbourCells_thresh__high_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_thresh__high_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_thresh__low__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NeighbourCells_thresh__low__presence_xer_ = { {"thresh_low_presence>\n", "thresh_low_presence>\n"}, {21, 21}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NeighbourCells_thresh__low__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_thresh__low__presence_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.thresh_low_presence", &BITSTRING_ber_, &EUTRAN__NeighbourCells_thresh__low__presence_raw_, NULL, &EUTRAN__NeighbourCells_thresh__low__presence_xer_, &BITSTRING_json_, &EUTRAN__NeighbourCells_thresh__low__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_thresh__low__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_qrxlevmin__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NeighbourCells_qrxlevmin__presence_xer_ = { {"qrxlevmin_presence>\n", "qrxlevmin_presence>\n"}, {20, 20}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NeighbourCells_qrxlevmin__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_qrxlevmin__presence_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.qrxlevmin_presence", &BITSTRING_ber_, &EUTRAN__NeighbourCells_qrxlevmin__presence_raw_, NULL, &EUTRAN__NeighbourCells_qrxlevmin__presence_xer_, &BITSTRING_json_, &EUTRAN__NeighbourCells_qrxlevmin__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_qrxlevmin__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__NeighbourCells
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells", NULL, &EUTRAN__NeighbourCells_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__CellDescs_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__CellDescs
const TTCN_Typedescriptor_t EUTRAN__CellDescs_descr_ = { "@GSM_RestOctets.EUTRAN_CellDescs", NULL, &EUTRAN__CellDescs_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__CellDescs_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__CellDesc_item__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__CellDesc_item__ind_xer_ = { {"item_ind>\n", "item_ind>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__CellDesc_item__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__CellDesc_item__ind_descr_ = { "@GSM_RestOctets.EUTRAN_CellDesc.item_ind", &BITSTRING_ber_, &EUTRAN__CellDesc_item__ind_raw_, NULL, &EUTRAN__CellDesc_item__ind_xer_, &BITSTRING_json_, &EUTRAN__CellDesc_item__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__CellDesc_item__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__CellDesc_e__arfcn_raw_ = {16,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__CellDesc_e__arfcn_xer_ = { {"e_arfcn>\n", "e_arfcn>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__CellDesc_e__arfcn_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__CellDesc_e__arfcn_descr_ = { "@GSM_RestOctets.EUTRAN_CellDesc.e_arfcn", &INTEGER_ber_, &EUTRAN__CellDesc_e__arfcn_raw_, &INTEGER_text_, &EUTRAN__CellDesc_e__arfcn_xer_, &INTEGER_json_, &EUTRAN__CellDesc_e__arfcn_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__CellDesc_e__arfcn_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__CellDesc_meas__bw__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__CellDesc_meas__bw__presence_xer_ = { {"meas_bw_presence>\n", "meas_bw_presence>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__CellDesc_meas__bw__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__CellDesc_meas__bw__presence_descr_ = { "@GSM_RestOctets.EUTRAN_CellDesc.meas_bw_presence", &BITSTRING_ber_, &EUTRAN__CellDesc_meas__bw__presence_raw_, NULL, &EUTRAN__CellDesc_meas__bw__presence_xer_, &BITSTRING_json_, &EUTRAN__CellDesc_meas__bw__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__CellDesc_meas__bw__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__CellDesc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__CellDesc
const TTCN_Typedescriptor_t EUTRAN__CellDesc_descr_ = { "@GSM_RestOctets.EUTRAN_CellDesc", NULL, &EUTRAN__CellDesc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__CellDesc_meas__bw_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__CellDesc_meas__bw_xer_ = { {"meas_bw>\n", "meas_bw>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__CellDesc_meas__bw_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__CellDesc_meas__bw_descr_ = { "@GSM_RestOctets.EUTRAN_CellDesc.meas_bw", &INTEGER_ber_, &EUTRAN__CellDesc_meas__bw_raw_, &INTEGER_text_, &EUTRAN__CellDesc_meas__bw_xer_, &INTEGER_json_, &EUTRAN__CellDesc_meas__bw_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__CellDesc_meas__bw_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__CellDesc_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__CellDescs_0_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__CellDescs_0
const TTCN_Typedescriptor_t EUTRAN__CellDescs_0_descr_ = { "@GSM_RestOctets.EUTRAN_CellDescs.<oftype>", NULL, &EUTRAN__CellDescs_0_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__CellDescs_0_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__CellDescs_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_cell__desc__list_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__NeighbourCells_cell__desc__list
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_cell__desc__list_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.cell_desc_list", NULL, &EUTRAN__NeighbourCells_cell__desc__list_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__CellDescs_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_cell__desc__list_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_prio_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NeighbourCells_prio_xer_ = { {"prio>\n", "prio>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NeighbourCells_prio_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_prio_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.prio", &INTEGER_ber_, &EUTRAN__NeighbourCells_prio_raw_, &INTEGER_text_, &EUTRAN__NeighbourCells_prio_xer_, &INTEGER_json_, &EUTRAN__NeighbourCells_prio_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_prio_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_thresh__low_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NeighbourCells_thresh__low_xer_ = { {"thresh_low>\n", "thresh_low>\n"}, {12, 12}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NeighbourCells_thresh__low_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_thresh__low_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.thresh_low", &INTEGER_ber_, &EUTRAN__NeighbourCells_thresh__low_raw_, &INTEGER_text_, &EUTRAN__NeighbourCells_thresh__low_xer_, &INTEGER_json_, &EUTRAN__NeighbourCells_thresh__low_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_thresh__low_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NeighbourCells_qrxlevmin_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NeighbourCells_qrxlevmin_xer_ = { {"qrxlevmin>\n", "qrxlevmin>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NeighbourCells_qrxlevmin_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NeighbourCells_qrxlevmin_descr_ = { "@GSM_RestOctets.EUTRAN_NeighbourCells.qrxlevmin", &INTEGER_ber_, &EUTRAN__NeighbourCells_qrxlevmin_raw_, &INTEGER_text_, &EUTRAN__NeighbourCells_qrxlevmin_xer_, &INTEGER_json_, &EUTRAN__NeighbourCells_qrxlevmin_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_qrxlevmin_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__NeighbourCells_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__RepeatedNeighbourCells_0_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__RepeatedNeighbourCells_0
const TTCN_Typedescriptor_t EUTRAN__RepeatedNeighbourCells_0_descr_ = { "@GSM_RestOctets.EUTRAN_RepeatedNeighbourCells.<oftype>", NULL, &EUTRAN__RepeatedNeighbourCells_0_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__RepeatedNeighbourCells_0_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__RepeatedNeighbourCells_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_repeated__neigh__cells_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__ParamsDesc_repeated__neigh__cells
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_repeated__neigh__cells_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.repeated_neigh_cells", NULL, &EUTRAN__ParamsDesc_repeated__neigh__cells_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__RepeatedNeighbourCells_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_repeated__neigh__cells_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__RepeatedNotAllowedCells_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__RepeatedNotAllowedCells
const TTCN_Typedescriptor_t EUTRAN__RepeatedNotAllowedCells_descr_ = { "@GSM_RestOctets.EUTRAN_RepeatedNotAllowedCells", NULL, &EUTRAN__RepeatedNotAllowedCells_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__RepeatedNotAllowedCells_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__NotAllowedCells_item__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NotAllowedCells_item__ind_xer_ = { {"item_ind>\n", "item_ind>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NotAllowedCells_item__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NotAllowedCells_item__ind_descr_ = { "@GSM_RestOctets.EUTRAN_NotAllowedCells.item_ind", &BITSTRING_ber_, &EUTRAN__NotAllowedCells_item__ind_raw_, NULL, &EUTRAN__NotAllowedCells_item__ind_xer_, &BITSTRING_json_, &EUTRAN__NotAllowedCells_item__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NotAllowedCells_item__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NotAllowedCells_pcid__group__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NotAllowedCells_pcid__group__presence_xer_ = { {"pcid_group_presence>\n", "pcid_group_presence>\n"}, {21, 21}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NotAllowedCells_pcid__group__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NotAllowedCells_pcid__group__presence_descr_ = { "@GSM_RestOctets.EUTRAN_NotAllowedCells.pcid_group_presence", &BITSTRING_ber_, &EUTRAN__NotAllowedCells_pcid__group__presence_raw_, NULL, &EUTRAN__NotAllowedCells_pcid__group__presence_xer_, &BITSTRING_json_, &EUTRAN__NotAllowedCells_pcid__group__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NotAllowedCells_pcid__group__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NotAllowedCells_freq__idx__list__term_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__NotAllowedCells_freq__idx__list__term_xer_ = { {"freq_idx_list_term>\n", "freq_idx_list_term>\n"}, {20, 20}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__NotAllowedCells_freq__idx__list__term_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__NotAllowedCells_freq__idx__list__term_descr_ = { "@GSM_RestOctets.EUTRAN_NotAllowedCells.freq_idx_list_term", &BITSTRING_ber_, &EUTRAN__NotAllowedCells_freq__idx__list__term_raw_, NULL, &EUTRAN__NotAllowedCells_freq__idx__list__term_xer_, &BITSTRING_json_, &EUTRAN__NotAllowedCells_freq__idx__list__term_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NotAllowedCells_freq__idx__list__term_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NotAllowedCells_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__NotAllowedCells
const TTCN_Typedescriptor_t EUTRAN__NotAllowedCells_descr_ = { "@GSM_RestOctets.EUTRAN_NotAllowedCells", NULL, &EUTRAN__NotAllowedCells_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__FreqIndexes_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__FreqIndexes
const TTCN_Typedescriptor_t EUTRAN__FreqIndexes_descr_ = { "@GSM_RestOctets.EUTRAN_FreqIndexes", NULL, &EUTRAN__FreqIndexes_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__FreqIndexes_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__FreqIndex_item__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__FreqIndex_item__ind_xer_ = { {"item_ind>\n", "item_ind>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__FreqIndex_item__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__FreqIndex_item__ind_descr_ = { "@GSM_RestOctets.EUTRAN_FreqIndex.item_ind", &BITSTRING_ber_, &EUTRAN__FreqIndex_item__ind_raw_, NULL, &EUTRAN__FreqIndex_item__ind_xer_, &BITSTRING_json_, &EUTRAN__FreqIndex_item__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__FreqIndex_item__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__FreqIndex_idx_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__FreqIndex_idx_xer_ = { {"idx>\n", "idx>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__FreqIndex_idx_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__FreqIndex_idx_descr_ = { "@GSM_RestOctets.EUTRAN_FreqIndex.idx", &INTEGER_ber_, &EUTRAN__FreqIndex_idx_raw_, &INTEGER_text_, &EUTRAN__FreqIndex_idx_xer_, &INTEGER_json_, &EUTRAN__FreqIndex_idx_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__FreqIndex_idx_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__FreqIndex_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__FreqIndex
const TTCN_Typedescriptor_t EUTRAN__FreqIndex_descr_ = { "@GSM_RestOctets.EUTRAN_FreqIndex", NULL, &EUTRAN__FreqIndex_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__FreqIndex_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__FreqIndexes_0_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__FreqIndexes_0
const TTCN_Typedescriptor_t EUTRAN__FreqIndexes_0_descr_ = { "@GSM_RestOctets.EUTRAN_FreqIndexes.<oftype>", NULL, &EUTRAN__FreqIndexes_0_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__FreqIndexes_0_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__FreqIndexes_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__NotAllowedCells_freq__idx__list_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__NotAllowedCells_freq__idx__list
const TTCN_Typedescriptor_t EUTRAN__NotAllowedCells_freq__idx__list_descr_ = { "@GSM_RestOctets.EUTRAN_NotAllowedCells.freq_idx_list", NULL, &EUTRAN__NotAllowedCells_freq__idx__list_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__FreqIndexes_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__NotAllowedCells_freq__idx__list_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__NotAllowedCells_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__RepeatedNotAllowedCells_0_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__RepeatedNotAllowedCells_0
const TTCN_Typedescriptor_t EUTRAN__RepeatedNotAllowedCells_0_descr_ = { "@GSM_RestOctets.EUTRAN_RepeatedNotAllowedCells.<oftype>", NULL, &EUTRAN__RepeatedNotAllowedCells_0_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__RepeatedNotAllowedCells_0_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__RepeatedNotAllowedCells_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_repeated__not__allowed__cells_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__ParamsDesc_repeated__not__allowed__cells
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_repeated__not__allowed__cells_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.repeated_not_allowed_cells", NULL, &EUTRAN__ParamsDesc_repeated__not__allowed__cells_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__RepeatedNotAllowedCells_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_repeated__not__allowed__cells_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__PCID2TAMaps_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__PCID2TAMaps
const TTCN_Typedescriptor_t EUTRAN__PCID2TAMaps_descr_ = { "@GSM_RestOctets.EUTRAN_PCID2TAMaps", NULL, &EUTRAN__PCID2TAMaps_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__PCID2TAMaps_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__PCID2TAMap_item__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__PCID2TAMap_item__ind_xer_ = { {"item_ind>\n", "item_ind>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__PCID2TAMap_item__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__PCID2TAMap_item__ind_descr_ = { "@GSM_RestOctets.EUTRAN_PCID2TAMap.item_ind", &BITSTRING_ber_, &EUTRAN__PCID2TAMap_item__ind_raw_, NULL, &EUTRAN__PCID2TAMap_item__ind_xer_, &BITSTRING_json_, &EUTRAN__PCID2TAMap_item__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__PCID2TAMap_item__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__PCID2TAMap_pcid__group__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__PCID2TAMap_pcid__group__presence_xer_ = { {"pcid_group_presence>\n", "pcid_group_presence>\n"}, {21, 21}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__PCID2TAMap_pcid__group__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__PCID2TAMap_pcid__group__presence_descr_ = { "@GSM_RestOctets.EUTRAN_PCID2TAMap.pcid_group_presence", &BITSTRING_ber_, &EUTRAN__PCID2TAMap_pcid__group__presence_raw_, NULL, &EUTRAN__PCID2TAMap_pcid__group__presence_xer_, &BITSTRING_json_, &EUTRAN__PCID2TAMap_pcid__group__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__PCID2TAMap_pcid__group__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__PCID2TAMap_freq__idx__list__term_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       EUTRAN__PCID2TAMap_freq__idx__list__term_xer_ = { {"freq_idx_list_term>\n", "freq_idx_list_term>\n"}, {20, 20}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t EUTRAN__PCID2TAMap_freq__idx__list__term_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t EUTRAN__PCID2TAMap_freq__idx__list__term_descr_ = { "@GSM_RestOctets.EUTRAN_PCID2TAMap.freq_idx_list_term", &BITSTRING_ber_, &EUTRAN__PCID2TAMap_freq__idx__list__term_raw_, NULL, &EUTRAN__PCID2TAMap_freq__idx__list__term_xer_, &BITSTRING_json_, &EUTRAN__PCID2TAMap_freq__idx__list__term_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__PCID2TAMap_freq__idx__list__term_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__PCID2TAMap_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__PCID2TAMap
const TTCN_Typedescriptor_t EUTRAN__PCID2TAMap_descr_ = { "@GSM_RestOctets.EUTRAN_PCID2TAMap", NULL, &EUTRAN__PCID2TAMap_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t EUTRAN__PCID2TAMap_freq__idx__list_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__PCID2TAMap_freq__idx__list
const TTCN_Typedescriptor_t EUTRAN__PCID2TAMap_freq__idx__list_descr_ = { "@GSM_RestOctets.EUTRAN_PCID2TAMap.freq_idx_list", NULL, &EUTRAN__PCID2TAMap_freq__idx__list_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__FreqIndexes_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__PCID2TAMap_freq__idx__list_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__PCID2TAMap_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__PCID2TAMaps_0_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__PCID2TAMaps_0
const TTCN_Typedescriptor_t EUTRAN__PCID2TAMaps_0_descr_ = { "@GSM_RestOctets.EUTRAN_PCID2TAMaps.<oftype>", NULL, &EUTRAN__PCID2TAMaps_0_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__PCID2TAMaps_0_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__PCID2TAMaps_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDesc_pcid2ta__map__list_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__ParamsDesc_pcid2ta__map__list
const TTCN_Typedescriptor_t EUTRAN__ParamsDesc_pcid2ta__map__list_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDesc.pcid2ta_map_list", NULL, &EUTRAN__ParamsDesc_pcid2ta__map__list_raw_, NULL, NULL, NULL, NULL, NULL, &EUTRAN__PCID2TAMaps_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_pcid2ta__map__list_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__ParamsDesc_default_coding("RAW");
const TTCN_RAWdescriptor_t EUTRAN__ParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for EUTRAN__ParamsDescOpt_desc
const TTCN_Typedescriptor_t EUTRAN__ParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.EUTRAN_ParamsDescOpt.desc", NULL, &EUTRAN__ParamsDescOpt_desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING EUTRAN__ParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING EUTRAN__ParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8PrioEUTRANParamsDesc_eutran__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel8PrioEUTRANParamsDesc_eutran__params__desc
const TTCN_Typedescriptor_t Rel8PrioEUTRANParamsDesc_eutran__params__desc_descr_ = { "@GSM_RestOctets.Rel8PrioEUTRANParamsDesc.eutran_params_desc", NULL, &Rel8PrioEUTRANParamsDesc_eutran__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8PrioEUTRANParamsDesc_eutran__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8PrioEUTRANParamsDesc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel8PrioEUTRANParamsDesc
const TTCN_Typedescriptor_t Rel8PrioEUTRANParamsDesc_descr_ = { "@GSM_RestOctets.Rel8PrioEUTRANParamsDesc", NULL, &Rel8PrioEUTRANParamsDesc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8PrioEUTRANParamsDesc_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8PrioEUTRANParamsDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel8PrioEUTRANParamsDescOpt_desc
const TTCN_Typedescriptor_t Rel8PrioEUTRANParamsDescOpt_desc_descr_ = { "@GSM_RestOctets.Rel8PrioEUTRANParamsDescOpt.desc", NULL, &Rel8PrioEUTRANParamsDescOpt_desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8PrioEUTRANParamsDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING Rel8PrioEUTRANParamsDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR8Additions_prio__eutran__params__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR8Additions_prio__eutran__params__desc
const TTCN_Typedescriptor_t SI2quaterR8Additions_prio__eutran__params__desc_descr_ = { "@GSM_RestOctets.SI2quaterR8Additions.prio_eutran_params_desc", NULL, &SI2quaterR8Additions_prio__eutran__params__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR8Additions_prio__eutran__params__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8UTRANCSGDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       Rel8UTRANCSGDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t Rel8UTRANCSGDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t Rel8UTRANCSGDescOpt_presence_descr_ = { "@GSM_RestOctets.Rel8UTRANCSGDescOpt.presence", &BITSTRING_ber_, &Rel8UTRANCSGDescOpt_presence_raw_, NULL, &Rel8UTRANCSGDescOpt_presence_xer_, &BITSTRING_json_, &Rel8UTRANCSGDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8UTRANCSGDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8UTRANCSGDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel8UTRANCSGDescOpt
const TTCN_Typedescriptor_t Rel8UTRANCSGDescOpt_descr_ = { "@GSM_RestOctets.Rel8UTRANCSGDescOpt", NULL, &Rel8UTRANCSGDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t Rel8UTRANCSGDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       Rel8UTRANCSGDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t Rel8UTRANCSGDescOpt_desc_descr_ = { "@GSM_RestOctets.Rel8UTRANCSGDescOpt.desc", &BITSTRING_ber_, &Rel8UTRANCSGDescOpt_desc_raw_, NULL, &Rel8UTRANCSGDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8UTRANCSGDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING Rel8UTRANCSGDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR8Additions_utran__csg__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR8Additions_utran__csg__desc
const TTCN_Typedescriptor_t SI2quaterR8Additions_utran__csg__desc_descr_ = { "@GSM_RestOctets.SI2quaterR8Additions.utran_csg_desc", NULL, &SI2quaterR8Additions_utran__csg__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR8Additions_utran__csg__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8EUTRANCSGDescOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       Rel8EUTRANCSGDescOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t Rel8EUTRANCSGDescOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t Rel8EUTRANCSGDescOpt_presence_descr_ = { "@GSM_RestOctets.Rel8EUTRANCSGDescOpt.presence", &BITSTRING_ber_, &Rel8EUTRANCSGDescOpt_presence_raw_, NULL, &Rel8EUTRANCSGDescOpt_presence_xer_, &BITSTRING_json_, &Rel8EUTRANCSGDescOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8EUTRANCSGDescOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t Rel8EUTRANCSGDescOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for Rel8EUTRANCSGDescOpt
const TTCN_Typedescriptor_t Rel8EUTRANCSGDescOpt_descr_ = { "@GSM_RestOctets.Rel8EUTRANCSGDescOpt", NULL, &Rel8EUTRANCSGDescOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t Rel8EUTRANCSGDescOpt_desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       Rel8EUTRANCSGDescOpt_desc_xer_ = { {"desc>\n", "desc>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t Rel8EUTRANCSGDescOpt_desc_descr_ = { "@GSM_RestOctets.Rel8EUTRANCSGDescOpt.desc", &BITSTRING_ber_, &Rel8EUTRANCSGDescOpt_desc_raw_, NULL, &Rel8EUTRANCSGDescOpt_desc_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING Rel8EUTRANCSGDescOpt_desc_default_coding("RAW");
UNIVERSAL_CHARSTRING Rel8EUTRANCSGDescOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR8Additions_eutran__csg__desc_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR8Additions_eutran__csg__desc
const TTCN_Typedescriptor_t SI2quaterR8Additions_eutran__csg__desc_descr_ = { "@GSM_RestOctets.SI2quaterR8Additions.eutran_csg_desc", NULL, &SI2quaterR8Additions_eutran__csg__desc_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR8Additions_eutran__csg__desc_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR8Additions_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR8Additions
const TTCN_Typedescriptor_t SI2quaterR8Additions_descr_ = { "@GSM_RestOctets.SI2quaterR8Additions", NULL, &SI2quaterR8Additions_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR8Additions_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR7Additions_rel8_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR7Additions_rel8
const TTCN_Typedescriptor_t SI2quaterR7Additions_rel8_descr_ = { "@GSM_RestOctets.SI2quaterR7Additions.rel8", NULL, &SI2quaterR7Additions_rel8_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR7Additions_rel8_default_coding("RAW");
UNIVERSAL_CHARSTRING SI2quaterR7Additions_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR6Additions_rel7_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR6Additions_rel7
const TTCN_Typedescriptor_t SI2quaterR6Additions_rel7_descr_ = { "@GSM_RestOctets.SI2quaterR6Additions.rel7", NULL, &SI2quaterR6Additions_rel7_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR6Additions_rel7_default_coding("RAW");
UNIVERSAL_CHARSTRING SI2quaterR6Additions_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterR5Additions_rel6_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterR5Additions_rel6
const TTCN_Typedescriptor_t SI2quaterR5Additions_rel6_descr_ = { "@GSM_RestOctets.SI2quaterR5Additions.rel6", NULL, &SI2quaterR5Additions_rel6_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterR5Additions_rel6_default_coding("RAW");
UNIVERSAL_CHARSTRING SI2quaterR5Additions_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterAdditions_rel5_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterAdditions_rel5
const TTCN_Typedescriptor_t SI2quaterAdditions_rel5_descr_ = { "@GSM_RestOctets.SI2quaterAdditions.rel5", NULL, &SI2quaterAdditions_rel5_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterAdditions_rel5_default_coding("RAW");
UNIVERSAL_CHARSTRING SI2quaterAdditions_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_rel__additions_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets_rel__additions
const TTCN_Typedescriptor_t SI2quaterRestOctets_rel__additions_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets.rel_additions", NULL, &SI2quaterRestOctets_rel__additions_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_rel__additions_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctets_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,8,0,0,8,8,pp_0,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctets
const TTCN_Typedescriptor_t SI2quaterRestOctets_descr_ = { "@GSM_RestOctets.SI2quaterRestOctets", NULL, &SI2quaterRestOctets_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctets_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterRestOctetsList_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctetsList
const TTCN_Typedescriptor_t SI2quaterRestOctetsList_descr_ = { "@GSM_RestOctets.SI2quaterRestOctetsList", NULL, &SI2quaterRestOctetsList_raw_, NULL, NULL, NULL, NULL, NULL, &SI2quaterRestOctetsList_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI2quaterRestOctetsList_0_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,8,0,0,8,8,pp_0,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterRestOctetsList_0
const TTCN_Typedescriptor_t SI2quaterRestOctetsList_0_descr_ = { "@GSM_RestOctets.SI2quaterRestOctetsList.<oftype>", NULL, &SI2quaterRestOctetsList_0_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterRestOctetsList_0_default_coding("RAW");
UNIVERSAL_CHARSTRING SI2quaterRestOctetsList_default_coding("RAW");
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDesc2_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UMTS__AddMeasParamsDesc2_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UMTS__AddMeasParamsDesc2_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDesc2_presence_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDesc2.presence", &BITSTRING_ber_, &UMTS__AddMeasParamsDesc2_presence_raw_, NULL, &UMTS__AddMeasParamsDesc2_presence_xer_, &BITSTRING_json_, &UMTS__AddMeasParamsDesc2_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDesc2_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDesc2_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for UMTS__AddMeasParamsDesc2
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDesc2_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDesc2", NULL, &UMTS__AddMeasParamsDesc2_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t UMTS__AddMeasParamsDesc2_threshold_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       UMTS__AddMeasParamsDesc2_threshold_xer_ = { {"threshold>\n", "threshold>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t UMTS__AddMeasParamsDesc2_threshold_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t UMTS__AddMeasParamsDesc2_threshold_descr_ = { "@GSM_RestOctets.UMTS_AddMeasParamsDesc2.threshold", &INTEGER_ber_, &UMTS__AddMeasParamsDesc2_threshold_raw_, &INTEGER_text_, &UMTS__AddMeasParamsDesc2_threshold_xer_, &INTEGER_json_, &UMTS__AddMeasParamsDesc2_threshold_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDesc2_threshold_default_coding("RAW");
UNIVERSAL_CHARSTRING UMTS__AddMeasParamsDesc2_default_coding("RAW");
SI2quaterRestOctets_template template_tra__SI2quaterRestOctets__base;
const SI2quaterRestOctets_template& tra__SI2quaterRestOctets__base = template_tra__SI2quaterRestOctets__base;
SI2quaterRestOctets_template template_tro__SI2quaterRestOctets__base;
const SI2quaterRestOctets_template& tro__SI2quaterRestOctets__base = template_tro__SI2quaterRestOctets__base;
SI2quaterRestOctets_template template_tro__SI2quaterRestOctets__rel8__EUTRAN;
const SI2quaterRestOctets_template& tro__SI2quaterRestOctets__rel8__EUTRAN = template_tro__SI2quaterRestOctets__rel8__EUTRAN;
INTEGER_template template_tr__EUTRAN__CellDesc_e__arfcn_defval;
const INTEGER_template& tr__EUTRAN__CellDesc_e__arfcn_defval = template_tr__EUTRAN__CellDesc_e__arfcn_defval;
BITSTRING_template template_tr__EUTRAN__CellDesc_meas__bw__presence_defval;
const BITSTRING_template& tr__EUTRAN__CellDesc_meas__bw__presence_defval = template_tr__EUTRAN__CellDesc_meas__bw__presence_defval;
INTEGER_template template_tr__EUTRAN__CellDesc_meas__bw_defval;
const INTEGER_template& tr__EUTRAN__CellDesc_meas__bw_defval = template_tr__EUTRAN__CellDesc_meas__bw_defval;
EUTRAN__CellDescs_template template_tr__EUTRAN__NeighbourCells_cell__desc__list_defval;
const EUTRAN__CellDescs_template& tr__EUTRAN__NeighbourCells_cell__desc__list_defval = template_tr__EUTRAN__NeighbourCells_cell__desc__list_defval;
BITSTRING_template template_tr__EUTRAN__NeighbourCells_prio__presence_defval;
const BITSTRING_template& tr__EUTRAN__NeighbourCells_prio__presence_defval = template_tr__EUTRAN__NeighbourCells_prio__presence_defval;
INTEGER_template template_tr__EUTRAN__NeighbourCells_prio_defval;
const INTEGER_template& tr__EUTRAN__NeighbourCells_prio_defval = template_tr__EUTRAN__NeighbourCells_prio_defval;
INTEGER_template template_tr__EUTRAN__NeighbourCells_thresh__high_defval;
const INTEGER_template& tr__EUTRAN__NeighbourCells_thresh__high_defval = template_tr__EUTRAN__NeighbourCells_thresh__high_defval;
BITSTRING_template template_tr__EUTRAN__NeighbourCells_thresh__low__presence_defval;
const BITSTRING_template& tr__EUTRAN__NeighbourCells_thresh__low__presence_defval = template_tr__EUTRAN__NeighbourCells_thresh__low__presence_defval;
INTEGER_template template_tr__EUTRAN__NeighbourCells_thresh__low_defval;
const INTEGER_template& tr__EUTRAN__NeighbourCells_thresh__low_defval = template_tr__EUTRAN__NeighbourCells_thresh__low_defval;
BITSTRING_template template_tr__EUTRAN__NeighbourCells_qrxlevmin__presence_defval;
const BITSTRING_template& tr__EUTRAN__NeighbourCells_qrxlevmin__presence_defval = template_tr__EUTRAN__NeighbourCells_qrxlevmin__presence_defval;
INTEGER_template template_tr__EUTRAN__NeighbourCells_qrxlevmin_defval;
const INTEGER_template& tr__EUTRAN__NeighbourCells_qrxlevmin_defval = template_tr__EUTRAN__NeighbourCells_qrxlevmin_defval;
INTEGER_template template_tr__SI2quaterRestOctets__EUTRAN_index_defval;
const INTEGER_template& tr__SI2quaterRestOctets__EUTRAN_index_defval = template_tr__SI2quaterRestOctets__EUTRAN_index_defval;
INTEGER_template template_tr__SI2quaterRestOctets__EUTRAN_count_defval;
const INTEGER_template& tr__SI2quaterRestOctets__EUTRAN_count_defval = template_tr__SI2quaterRestOctets__EUTRAN_count_defval;
EUTRAN__RepeatedNeighbourCells_template template_tr__SI2quaterRestOctets__EUTRAN_repeated__neigh__cells_defval;
const EUTRAN__RepeatedNeighbourCells_template& tr__SI2quaterRestOctets__EUTRAN_repeated__neigh__cells_defval = template_tr__SI2quaterRestOctets__EUTRAN_repeated__neigh__cells_defval;
const TTCN_RAWdescriptor_t SelectionParamsOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SelectionParamsOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SelectionParamsOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SelectionParamsOpt_presence_descr_ = { "@GSM_RestOctets.SelectionParamsOpt.presence", &BITSTRING_ber_, &SelectionParamsOpt_presence_raw_, NULL, &SelectionParamsOpt_presence_xer_, &BITSTRING_json_, &SelectionParamsOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SelectionParamsOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SelectionParamsOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SelectionParamsOpt
const TTCN_Typedescriptor_t SelectionParamsOpt_descr_ = { "@GSM_RestOctets.SelectionParamsOpt", NULL, &SelectionParamsOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SelectionParams_cbq_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SelectionParams_cbq_xer_ = { {"cbq>\n", "cbq>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const int SelectionParams_cbq_oer_ext_arr_[0] = {};
const int SelectionParams_cbq_oer_p_[0] = {};
const TTCN_OERdescriptor_t SelectionParams_cbq_oer_ = { -1, TRUE, -1, FALSE, 0, 0, SelectionParams_cbq_oer_ext_arr_, 0, SelectionParams_cbq_oer_p_};
const TTCN_Typedescriptor_t SelectionParams_cbq_descr_ = { "@GSM_RestOctets.SelectionParams.cbq", &BOOLEAN_ber_, &SelectionParams_cbq_raw_, &BOOLEAN_text_, &SelectionParams_cbq_xer_, &BOOLEAN_json_, &SelectionParams_cbq_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SelectionParams_cbq_default_coding("RAW");
const TTCN_RAWdescriptor_t SelectionParams_cr__offset_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SelectionParams_cr__offset_xer_ = { {"cr_offset>\n", "cr_offset>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SelectionParams_cr__offset_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SelectionParams_cr__offset_descr_ = { "@GSM_RestOctets.SelectionParams.cr_offset", &INTEGER_ber_, &SelectionParams_cr__offset_raw_, &INTEGER_text_, &SelectionParams_cr__offset_xer_, &INTEGER_json_, &SelectionParams_cr__offset_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SelectionParams_cr__offset_default_coding("RAW");
const TTCN_RAWdescriptor_t SelectionParams_temp__offset_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SelectionParams_temp__offset_xer_ = { {"temp_offset>\n", "temp_offset>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SelectionParams_temp__offset_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SelectionParams_temp__offset_descr_ = { "@GSM_RestOctets.SelectionParams.temp_offset", &INTEGER_ber_, &SelectionParams_temp__offset_raw_, &INTEGER_text_, &SelectionParams_temp__offset_xer_, &INTEGER_json_, &SelectionParams_temp__offset_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SelectionParams_temp__offset_default_coding("RAW");
const TTCN_RAWdescriptor_t SelectionParams_penalty__time_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SelectionParams_penalty__time_xer_ = { {"penalty_time>\n", "penalty_time>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SelectionParams_penalty__time_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SelectionParams_penalty__time_descr_ = { "@GSM_RestOctets.SelectionParams.penalty_time", &INTEGER_ber_, &SelectionParams_penalty__time_raw_, &INTEGER_text_, &SelectionParams_penalty__time_xer_, &INTEGER_json_, &SelectionParams_penalty__time_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SelectionParams_penalty__time_default_coding("RAW");
const TTCN_RAWdescriptor_t SelectionParams_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SelectionParams
const TTCN_Typedescriptor_t SelectionParams_descr_ = { "@GSM_RestOctets.SelectionParams", NULL, &SelectionParams_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SelectionParams_default_coding("RAW");
const TTCN_RAWdescriptor_t SelectionParamsOpt_params_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SelectionParamsOpt_params
const TTCN_Typedescriptor_t SelectionParamsOpt_params_descr_ = { "@GSM_RestOctets.SelectionParamsOpt.params", NULL, &SelectionParamsOpt_params_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SelectionParamsOpt_params_default_coding("RAW");
UNIVERSAL_CHARSTRING SelectionParamsOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_sel__params_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI3RestOctets_sel__params
const TTCN_Typedescriptor_t SI3RestOctets_sel__params_descr_ = { "@GSM_RestOctets.SI3RestOctets.sel_params", NULL, &SI3RestOctets_sel__params_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_sel__params_default_coding("RAW");
const TTCN_RAWdescriptor_t PowerOffsetOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       PowerOffsetOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PowerOffsetOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PowerOffsetOpt_presence_descr_ = { "@GSM_RestOctets.PowerOffsetOpt.presence", &BITSTRING_ber_, &PowerOffsetOpt_presence_raw_, NULL, &PowerOffsetOpt_presence_xer_, &BITSTRING_json_, &PowerOffsetOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PowerOffsetOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t PowerOffsetOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PowerOffsetOpt
const TTCN_Typedescriptor_t PowerOffsetOpt_descr_ = { "@GSM_RestOctets.PowerOffsetOpt", NULL, &PowerOffsetOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t PowerOffsetOpt_offset_raw_ = {2,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PowerOffsetOpt_offset_xer_ = { {"offset>\n", "offset>\n"}, {8, 8}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PowerOffsetOpt_offset_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PowerOffsetOpt_offset_descr_ = { "@GSM_RestOctets.PowerOffsetOpt.offset", &INTEGER_ber_, &PowerOffsetOpt_offset_raw_, &INTEGER_text_, &PowerOffsetOpt_offset_xer_, &INTEGER_json_, &PowerOffsetOpt_offset_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PowerOffsetOpt_offset_default_coding("RAW");
UNIVERSAL_CHARSTRING PowerOffsetOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_pwr__offset_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI3RestOctets_pwr__offset
const TTCN_Typedescriptor_t SI3RestOctets_pwr__offset_descr_ = { "@GSM_RestOctets.SI3RestOctets.pwr_offset", NULL, &SI3RestOctets_pwr__offset_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_pwr__offset_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_si__2ter__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI3RestOctets_si__2ter__ind_xer_ = { {"si_2ter_ind>\n", "si_2ter_ind>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI3RestOctets_si__2ter__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI3RestOctets_si__2ter__ind_descr_ = { "@GSM_RestOctets.SI3RestOctets.si_2ter_ind", &BITSTRING_ber_, &SI3RestOctets_si__2ter__ind_raw_, NULL, &SI3RestOctets_si__2ter__ind_xer_, &BITSTRING_json_, &SI3RestOctets_si__2ter__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_si__2ter__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_early__cm__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI3RestOctets_early__cm__ind_xer_ = { {"early_cm_ind>\n", "early_cm_ind>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI3RestOctets_early__cm__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI3RestOctets_early__cm__ind_descr_ = { "@GSM_RestOctets.SI3RestOctets.early_cm_ind", &BITSTRING_ber_, &SI3RestOctets_early__cm__ind_raw_, NULL, &SI3RestOctets_early__cm__ind_xer_, &BITSTRING_json_, &SI3RestOctets_early__cm__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_early__cm__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SchedIfAndWhere_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SchedIfAndWhere_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SchedIfAndWhere_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SchedIfAndWhere_presence_descr_ = { "@GSM_RestOctets.SchedIfAndWhere.presence", &BITSTRING_ber_, &SchedIfAndWhere_presence_raw_, NULL, &SchedIfAndWhere_presence_xer_, &BITSTRING_json_, &SchedIfAndWhere_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SchedIfAndWhere_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SchedIfAndWhere_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SchedIfAndWhere
const TTCN_Typedescriptor_t SchedIfAndWhere_descr_ = { "@GSM_RestOctets.SchedIfAndWhere", NULL, &SchedIfAndWhere_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SchedIfAndWhere_where_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SchedIfAndWhere_where_xer_ = { {"where>\n", "where>\n"}, {7, 7}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SchedIfAndWhere_where_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SchedIfAndWhere_where_descr_ = { "@GSM_RestOctets.SchedIfAndWhere.where", &INTEGER_ber_, &SchedIfAndWhere_where_raw_, &INTEGER_text_, &SchedIfAndWhere_where_xer_, &INTEGER_json_, &SchedIfAndWhere_where_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SchedIfAndWhere_where_default_coding("RAW");
UNIVERSAL_CHARSTRING SchedIfAndWhere_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_sched__where_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI3RestOctets_sched__where
const TTCN_Typedescriptor_t SI3RestOctets_sched__where_descr_ = { "@GSM_RestOctets.SI3RestOctets.sched_where", NULL, &SI3RestOctets_sched__where_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_sched__where_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRSIndicatorOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       GPRSIndicatorOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t GPRSIndicatorOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t GPRSIndicatorOpt_presence_descr_ = { "@GSM_RestOctets.GPRSIndicatorOpt.presence", &BITSTRING_ber_, &GPRSIndicatorOpt_presence_raw_, NULL, &GPRSIndicatorOpt_presence_xer_, &BITSTRING_json_, &GPRSIndicatorOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRSIndicatorOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRSIndicatorOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for GPRSIndicatorOpt
const TTCN_Typedescriptor_t GPRSIndicatorOpt_descr_ = { "@GSM_RestOctets.GPRSIndicatorOpt", NULL, &GPRSIndicatorOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t GPRSIndicator_ra__colour_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       GPRSIndicator_ra__colour_xer_ = { {"ra_colour>\n", "ra_colour>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t GPRSIndicator_ra__colour_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t GPRSIndicator_ra__colour_descr_ = { "@GSM_RestOctets.GPRSIndicator.ra_colour", &INTEGER_ber_, &GPRSIndicator_ra__colour_raw_, &INTEGER_text_, &GPRSIndicator_ra__colour_xer_, &INTEGER_json_, &GPRSIndicator_ra__colour_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRSIndicator_ra__colour_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRSIndicator_si13__pos_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       GPRSIndicator_si13__pos_xer_ = { {"si13_pos>\n", "si13_pos>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t GPRSIndicator_si13__pos_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t GPRSIndicator_si13__pos_descr_ = { "@GSM_RestOctets.GPRSIndicator.si13_pos", &BITSTRING_ber_, &GPRSIndicator_si13__pos_raw_, NULL, &GPRSIndicator_si13__pos_xer_, &BITSTRING_json_, &GPRSIndicator_si13__pos_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRSIndicator_si13__pos_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRSIndicator_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for GPRSIndicator
const TTCN_Typedescriptor_t GPRSIndicator_descr_ = { "@GSM_RestOctets.GPRSIndicator", NULL, &GPRSIndicator_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRSIndicator_default_coding("RAW");
const TTCN_RAWdescriptor_t GPRSIndicatorOpt_ind_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for GPRSIndicatorOpt_ind
const TTCN_Typedescriptor_t GPRSIndicatorOpt_ind_descr_ = { "@GSM_RestOctets.GPRSIndicatorOpt.ind", NULL, &GPRSIndicatorOpt_ind_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING GPRSIndicatorOpt_ind_default_coding("RAW");
UNIVERSAL_CHARSTRING GPRSIndicatorOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_gprs__ind_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI3RestOctets_gprs__ind
const TTCN_Typedescriptor_t SI3RestOctets_gprs__ind_descr_ = { "@GSM_RestOctets.SI3RestOctets.gprs_ind", NULL, &SI3RestOctets_gprs__ind_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_gprs__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_umts__early__cm__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI3RestOctets_umts__early__cm__ind_xer_ = { {"umts_early_cm_ind>\n", "umts_early_cm_ind>\n"}, {19, 19}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI3RestOctets_umts__early__cm__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI3RestOctets_umts__early__cm__ind_descr_ = { "@GSM_RestOctets.SI3RestOctets.umts_early_cm_ind", &BITSTRING_ber_, &SI3RestOctets_umts__early__cm__ind_raw_, NULL, &SI3RestOctets_umts__early__cm__ind_xer_, &BITSTRING_json_, &SI3RestOctets_umts__early__cm__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_umts__early__cm__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterIndicatorOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI2quaterIndicatorOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterIndicatorOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterIndicatorOpt_presence_descr_ = { "@GSM_RestOctets.SI2quaterIndicatorOpt.presence", &BITSTRING_ber_, &SI2quaterIndicatorOpt_presence_raw_, NULL, &SI2quaterIndicatorOpt_presence_xer_, &BITSTRING_json_, &SI2quaterIndicatorOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterIndicatorOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI2quaterIndicatorOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI2quaterIndicatorOpt
const TTCN_Typedescriptor_t SI2quaterIndicatorOpt_descr_ = { "@GSM_RestOctets.SI2quaterIndicatorOpt", NULL, &SI2quaterIndicatorOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI2quaterIndicatorOpt_ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI2quaterIndicatorOpt_ind_xer_ = { {"ind>\n", "ind>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI2quaterIndicatorOpt_ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI2quaterIndicatorOpt_ind_descr_ = { "@GSM_RestOctets.SI2quaterIndicatorOpt.ind", &BITSTRING_ber_, &SI2quaterIndicatorOpt_ind_raw_, NULL, &SI2quaterIndicatorOpt_ind_xer_, &BITSTRING_json_, &SI2quaterIndicatorOpt_ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI2quaterIndicatorOpt_ind_default_coding("RAW");
UNIVERSAL_CHARSTRING SI2quaterIndicatorOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_si2__quater__ind_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI3RestOctets_si2__quater__ind
const TTCN_Typedescriptor_t SI3RestOctets_si2__quater__ind_descr_ = { "@GSM_RestOctets.SI3RestOctets.si2_quater_ind", NULL, &SI3RestOctets_si2__quater__ind_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_si2__quater__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,8,0,0,8,8,pp_0,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI3RestOctets
const TTCN_Typedescriptor_t SI3RestOctets_descr_ = { "@GSM_RestOctets.SI3RestOctets", NULL, &SI3RestOctets_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI3RestOctets_iu__mode__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI3RestOctets_iu__mode__ind_xer_ = { {"iu_mode_ind>\n", "iu_mode_ind>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI3RestOctets_iu__mode__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI3RestOctets_iu__mode__ind_descr_ = { "@GSM_RestOctets.SI3RestOctets.iu_mode_ind", &BITSTRING_ber_, &SI3RestOctets_iu__mode__ind_raw_, NULL, &SI3RestOctets_iu__mode__ind_xer_, &BITSTRING_json_, &SI3RestOctets_iu__mode__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_iu__mode__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI21IndicatorOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI21IndicatorOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI21IndicatorOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI21IndicatorOpt_presence_descr_ = { "@GSM_RestOctets.SI21IndicatorOpt.presence", &BITSTRING_ber_, &SI21IndicatorOpt_presence_raw_, NULL, &SI21IndicatorOpt_presence_xer_, &BITSTRING_json_, &SI21IndicatorOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI21IndicatorOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI21IndicatorOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI21IndicatorOpt
const TTCN_Typedescriptor_t SI21IndicatorOpt_descr_ = { "@GSM_RestOctets.SI21IndicatorOpt", NULL, &SI21IndicatorOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI21IndicatorOpt_pos_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI21IndicatorOpt_pos_xer_ = { {"pos>\n", "pos>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI21IndicatorOpt_pos_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI21IndicatorOpt_pos_descr_ = { "@GSM_RestOctets.SI21IndicatorOpt.pos", &BITSTRING_ber_, &SI21IndicatorOpt_pos_raw_, NULL, &SI21IndicatorOpt_pos_xer_, &BITSTRING_json_, &SI21IndicatorOpt_pos_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI21IndicatorOpt_pos_default_coding("RAW");
UNIVERSAL_CHARSTRING SI21IndicatorOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI3RestOctets_si21__ind_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI3RestOctets_si21__ind
const TTCN_Typedescriptor_t SI3RestOctets_si21__ind_descr_ = { "@GSM_RestOctets.SI3RestOctets.si21_ind", NULL, &SI3RestOctets_si21__ind_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI3RestOctets_si21__ind_default_coding("RAW");
UNIVERSAL_CHARSTRING SI3RestOctets_default_coding("RAW");
const TTCN_RAWdescriptor_t SI4RestOctets_sel__params_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI4RestOctets_sel__params
const TTCN_Typedescriptor_t SI4RestOctets_sel__params_descr_ = { "@GSM_RestOctets.SI4RestOctets.sel_params", NULL, &SI4RestOctets_sel__params_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI4RestOctets_sel__params_default_coding("RAW");
const TTCN_RAWdescriptor_t SI4RestOctets_pwr__offset_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI4RestOctets_pwr__offset
const TTCN_Typedescriptor_t SI4RestOctets_pwr__offset_descr_ = { "@GSM_RestOctets.SI4RestOctets.pwr_offset", NULL, &SI4RestOctets_pwr__offset_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI4RestOctets_pwr__offset_default_coding("RAW");
const TTCN_RAWdescriptor_t SI4RestOctets_gprs__ind_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI4RestOctets_gprs__ind
const TTCN_Typedescriptor_t SI4RestOctets_gprs__ind_descr_ = { "@GSM_RestOctets.SI4RestOctets.gprs_ind", NULL, &SI4RestOctets_gprs__ind_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI4RestOctets_gprs__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI4RestOctets_s__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI4RestOctets_s__presence_xer_ = { {"s_presence>\n", "s_presence>\n"}, {12, 12}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI4RestOctets_s__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI4RestOctets_s__presence_descr_ = { "@GSM_RestOctets.SI4RestOctets.s_presence", &BITSTRING_ber_, &SI4RestOctets_s__presence_raw_, NULL, &SI4RestOctets_s__presence_xer_, &BITSTRING_json_, &SI4RestOctets_s__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI4RestOctets_s__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI4RestOctets_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,8,0,0,8,8,pp_0,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI4RestOctets
const TTCN_Typedescriptor_t SI4RestOctets_descr_ = { "@GSM_RestOctets.SI4RestOctets", NULL, &SI4RestOctets_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI4RestOctets_s_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI4RestOctets_s_xer_ = { {"s>\n", "s>\n"}, {3, 3}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_Typedescriptor_t SI4RestOctets_s_descr_ = { "@GSM_RestOctets.SI4RestOctets.s", &BITSTRING_ber_, &SI4RestOctets_s_raw_, NULL, &SI4RestOctets_s_xer_, &BITSTRING_json_, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI4RestOctets_s_default_coding("RAW");
UNIVERSAL_CHARSTRING SI4RestOctets_default_coding("RAW");
const TTCN_RAWdescriptor_t PchAndNchInfoOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       PchAndNchInfoOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PchAndNchInfoOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PchAndNchInfoOpt_presence_descr_ = { "@GSM_RestOctets.PchAndNchInfoOpt.presence", &BITSTRING_ber_, &PchAndNchInfoOpt_presence_raw_, NULL, &PchAndNchInfoOpt_presence_xer_, &BITSTRING_json_, &PchAndNchInfoOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PchAndNchInfoOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t PchAndNchInfoOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PchAndNchInfoOpt
const TTCN_Typedescriptor_t PchAndNchInfoOpt_descr_ = { "@GSM_RestOctets.PchAndNchInfoOpt", NULL, &PchAndNchInfoOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t PchAndNchInfo_pag__chan__restruct_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PchAndNchInfo_pag__chan__restruct_xer_ = { {"pag_chan_restruct>\n", "pag_chan_restruct>\n"}, {19, 19}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PchAndNchInfo_pag__chan__restruct_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PchAndNchInfo_pag__chan__restruct_descr_ = { "@GSM_RestOctets.PchAndNchInfo.pag_chan_restruct", &BITSTRING_ber_, &PchAndNchInfo_pag__chan__restruct_raw_, NULL, &PchAndNchInfo_pag__chan__restruct_xer_, &BITSTRING_json_, &PchAndNchInfo_pag__chan__restruct_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PchAndNchInfo_pag__chan__restruct_default_coding("RAW");
const TTCN_RAWdescriptor_t PchAndNchInfo_nln__sacch_raw_ = {2,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PchAndNchInfo_nln__sacch_xer_ = { {"nln_sacch>\n", "nln_sacch>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PchAndNchInfo_nln__sacch_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PchAndNchInfo_nln__sacch_descr_ = { "@GSM_RestOctets.PchAndNchInfo.nln_sacch", &INTEGER_ber_, &PchAndNchInfo_nln__sacch_raw_, &INTEGER_text_, &PchAndNchInfo_nln__sacch_xer_, &INTEGER_json_, &PchAndNchInfo_nln__sacch_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PchAndNchInfo_nln__sacch_default_coding("RAW");
const TTCN_RAWdescriptor_t PchAndNchInfo_call__prio__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PchAndNchInfo_call__prio__presence_xer_ = { {"call_prio_presence>\n", "call_prio_presence>\n"}, {20, 20}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PchAndNchInfo_call__prio__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PchAndNchInfo_call__prio__presence_descr_ = { "@GSM_RestOctets.PchAndNchInfo.call_prio_presence", &BITSTRING_ber_, &PchAndNchInfo_call__prio__presence_raw_, NULL, &PchAndNchInfo_call__prio__presence_xer_, &BITSTRING_json_, &PchAndNchInfo_call__prio__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PchAndNchInfo_call__prio__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t PchAndNchInfo_nln__status__sacch_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PchAndNchInfo_nln__status__sacch_xer_ = { {"nln_status_sacch>\n", "nln_status_sacch>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PchAndNchInfo_nln__status__sacch_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PchAndNchInfo_nln__status__sacch_descr_ = { "@GSM_RestOctets.PchAndNchInfo.nln_status_sacch", &BITSTRING_ber_, &PchAndNchInfo_nln__status__sacch_raw_, NULL, &PchAndNchInfo_nln__status__sacch_xer_, &BITSTRING_json_, &PchAndNchInfo_nln__status__sacch_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PchAndNchInfo_nln__status__sacch_default_coding("RAW");
const TTCN_RAWdescriptor_t PchAndNchInfo_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PchAndNchInfo
const TTCN_Typedescriptor_t PchAndNchInfo_descr_ = { "@GSM_RestOctets.PchAndNchInfo", NULL, &PchAndNchInfo_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t PchAndNchInfo_call__prio_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       PchAndNchInfo_call__prio_xer_ = { {"call_prio>\n", "call_prio>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t PchAndNchInfo_call__prio_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t PchAndNchInfo_call__prio_descr_ = { "@GSM_RestOctets.PchAndNchInfo.call_prio", &INTEGER_ber_, &PchAndNchInfo_call__prio_raw_, &INTEGER_text_, &PchAndNchInfo_call__prio_xer_, &INTEGER_json_, &PchAndNchInfo_call__prio_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PchAndNchInfo_call__prio_default_coding("RAW");
UNIVERSAL_CHARSTRING PchAndNchInfo_default_coding("RAW");
const TTCN_RAWdescriptor_t PchAndNchInfoOpt_info_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for PchAndNchInfoOpt_info
const TTCN_Typedescriptor_t PchAndNchInfoOpt_info_descr_ = { "@GSM_RestOctets.PchAndNchInfoOpt.info", NULL, &PchAndNchInfoOpt_info_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING PchAndNchInfoOpt_info_default_coding("RAW");
UNIVERSAL_CHARSTRING PchAndNchInfoOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI6RestOctets_pch__nch__info_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI6RestOctets_pch__nch__info
const TTCN_Typedescriptor_t SI6RestOctets_pch__nch__info_descr_ = { "@GSM_RestOctets.SI6RestOctets.pch_nch_info", NULL, &SI6RestOctets_pch__nch__info_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI6RestOctets_pch__nch__info_default_coding("RAW");
const TTCN_RAWdescriptor_t VbsVgcsOptionsOpt_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       VbsVgcsOptionsOpt_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t VbsVgcsOptionsOpt_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t VbsVgcsOptionsOpt_presence_descr_ = { "@GSM_RestOctets.VbsVgcsOptionsOpt.presence", &BITSTRING_ber_, &VbsVgcsOptionsOpt_presence_raw_, NULL, &VbsVgcsOptionsOpt_presence_xer_, &BITSTRING_json_, &VbsVgcsOptionsOpt_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING VbsVgcsOptionsOpt_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t VbsVgcsOptionsOpt_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for VbsVgcsOptionsOpt
const TTCN_Typedescriptor_t VbsVgcsOptionsOpt_descr_ = { "@GSM_RestOctets.VbsVgcsOptionsOpt", NULL, &VbsVgcsOptionsOpt_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t VbsVgcsOptionsOpt_options_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       VbsVgcsOptionsOpt_options_xer_ = { {"options>\n", "options>\n"}, {9, 9}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t VbsVgcsOptionsOpt_options_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t VbsVgcsOptionsOpt_options_descr_ = { "@GSM_RestOctets.VbsVgcsOptionsOpt.options", &BITSTRING_ber_, &VbsVgcsOptionsOpt_options_raw_, NULL, &VbsVgcsOptionsOpt_options_xer_, &BITSTRING_json_, &VbsVgcsOptionsOpt_options_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING VbsVgcsOptionsOpt_options_default_coding("RAW");
UNIVERSAL_CHARSTRING VbsVgcsOptionsOpt_default_coding("RAW");
const TTCN_RAWdescriptor_t SI6RestOctets_vbs__vgcs__options_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI6RestOctets_vbs__vgcs__options
const TTCN_Typedescriptor_t SI6RestOctets_vbs__vgcs__options_descr_ = { "@GSM_RestOctets.SI6RestOctets.vbs_vgcs_options", NULL, &SI6RestOctets_vbs__vgcs__options_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI6RestOctets_vbs__vgcs__options_default_coding("RAW");
const TTCN_RAWdescriptor_t SI6RestOctets_dtm__support_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI6RestOctets_dtm__support_xer_ = { {"dtm_support>\n", "dtm_support>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI6RestOctets_dtm__support_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI6RestOctets_dtm__support_descr_ = { "@GSM_RestOctets.SI6RestOctets.dtm_support", &BITSTRING_ber_, &SI6RestOctets_dtm__support_raw_, NULL, &SI6RestOctets_dtm__support_xer_, &BITSTRING_json_, &SI6RestOctets_dtm__support_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI6RestOctets_dtm__support_default_coding("RAW");
const TTCN_RAWdescriptor_t SI6RestOctets_band__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI6RestOctets_band__ind_xer_ = { {"band_ind>\n", "band_ind>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI6RestOctets_band__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI6RestOctets_band__ind_descr_ = { "@GSM_RestOctets.SI6RestOctets.band_ind", &BITSTRING_ber_, &SI6RestOctets_band__ind_raw_, NULL, &SI6RestOctets_band__ind_xer_, &BITSTRING_json_, &SI6RestOctets_band__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI6RestOctets_band__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI6RestOctets_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,8,0,0,8,8,pp_0,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI6RestOctets
const TTCN_Typedescriptor_t SI6RestOctets_descr_ = { "@GSM_RestOctets.SI6RestOctets", NULL, &SI6RestOctets_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI6RestOctets_rac_raw_ = {8,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI6RestOctets_rac_xer_ = { {"rac>\n", "rac>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI6RestOctets_rac_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI6RestOctets_rac_descr_ = { "@GSM_RestOctets.SI6RestOctets.rac", &INTEGER_ber_, &SI6RestOctets_rac_raw_, &INTEGER_text_, &SI6RestOctets_rac_xer_, &INTEGER_json_, &SI6RestOctets_rac_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI6RestOctets_rac_default_coding("RAW");
const TTCN_RAWdescriptor_t SI6RestOctets_max__lapdm_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI6RestOctets_max__lapdm_xer_ = { {"max_lapdm>\n", "max_lapdm>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI6RestOctets_max__lapdm_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI6RestOctets_max__lapdm_descr_ = { "@GSM_RestOctets.SI6RestOctets.max_lapdm", &INTEGER_ber_, &SI6RestOctets_max__lapdm_raw_, &INTEGER_text_, &SI6RestOctets_max__lapdm_xer_, &INTEGER_json_, &SI6RestOctets_max__lapdm_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI6RestOctets_max__lapdm_default_coding("RAW");
UNIVERSAL_CHARSTRING SI6RestOctets_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI13RestOctets_presence_xer_ = { {"presence>\n", "presence>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_presence_descr_ = { "@GSM_RestOctets.SI13RestOctets.presence", &BITSTRING_ber_, &SI13RestOctets_presence_raw_, NULL, &SI13RestOctets_presence_xer_, &BITSTRING_json_, &SI13RestOctets_presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_bcch__change__mark_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI13RestOctets_bcch__change__mark_xer_ = { {"bcch_change_mark>\n", "bcch_change_mark>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_bcch__change__mark_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_bcch__change__mark_descr_ = { "@GSM_RestOctets.SI13RestOctets.bcch_change_mark", &INTEGER_ber_, &SI13RestOctets_bcch__change__mark_raw_, &INTEGER_text_, &SI13RestOctets_bcch__change__mark_xer_, &INTEGER_json_, &SI13RestOctets_bcch__change__mark_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_bcch__change__mark_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_si__change__field_raw_ = {4,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,4,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI13RestOctets_si__change__field_xer_ = { {"si_change_field>\n", "si_change_field>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_si__change__field_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_si__change__field_descr_ = { "@GSM_RestOctets.SI13RestOctets.si_change_field", &BITSTRING_ber_, &SI13RestOctets_si__change__field_raw_, NULL, &SI13RestOctets_si__change__field_xer_, &BITSTRING_json_, &SI13RestOctets_si__change__field_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_si__change__field_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_presence2_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI13RestOctets_presence2_xer_ = { {"presence2>\n", "presence2>\n"}, {11, 11}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_presence2_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_presence2_descr_ = { "@GSM_RestOctets.SI13RestOctets.presence2", &BITSTRING_ber_, &SI13RestOctets_presence2_raw_, NULL, &SI13RestOctets_presence2_xer_, &BITSTRING_json_, &SI13RestOctets_presence2_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_presence2_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_zero_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI13RestOctets_zero_xer_ = { {"zero>\n", "zero>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_zero_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_zero_descr_ = { "@GSM_RestOctets.SI13RestOctets.zero", &BITSTRING_ber_, &SI13RestOctets_zero_raw_, NULL, &SI13RestOctets_zero_xer_, &BITSTRING_json_, &SI13RestOctets_zero_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_zero_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_rac_raw_ = {8,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI13RestOctets_rac_xer_ = { {"rac>\n", "rac>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_rac_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_rac_descr_ = { "@GSM_RestOctets.SI13RestOctets.rac", &INTEGER_ber_, &SI13RestOctets_rac_raw_, &INTEGER_text_, &SI13RestOctets_rac_xer_, &INTEGER_json_, &SI13RestOctets_rac_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_rac_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_spgc__ccch__sup_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI13RestOctets_spgc__ccch__sup_xer_ = { {"spgc_ccch_sup>\n", "spgc_ccch_sup>\n"}, {15, 15}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_spgc__ccch__sup_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_spgc__ccch__sup_descr_ = { "@GSM_RestOctets.SI13RestOctets.spgc_ccch_sup", &BITSTRING_ber_, &SI13RestOctets_spgc__ccch__sup_raw_, NULL, &SI13RestOctets_spgc__ccch__sup_xer_, &BITSTRING_json_, &SI13RestOctets_spgc__ccch__sup_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_spgc__ccch__sup_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_priority__access__thr_raw_ = {3,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,3,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI13RestOctets_priority__access__thr_xer_ = { {"priority_access_thr>\n", "priority_access_thr>\n"}, {21, 21}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_priority__access__thr_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_priority__access__thr_descr_ = { "@GSM_RestOctets.SI13RestOctets.priority_access_thr", &BITSTRING_ber_, &SI13RestOctets_priority__access__thr_raw_, NULL, &SI13RestOctets_priority__access__thr_xer_, &BITSTRING_json_, &SI13RestOctets_priority__access__thr_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_priority__access__thr_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_network__control__order_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI13RestOctets_network__control__order_xer_ = { {"network_control_order>\n", "network_control_order>\n"}, {23, 23}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_network__control__order_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_network__control__order_descr_ = { "@GSM_RestOctets.SI13RestOctets.network_control_order", &BITSTRING_ber_, &SI13RestOctets_network__control__order_raw_, NULL, &SI13RestOctets_network__control__order_xer_, &BITSTRING_json_, &SI13RestOctets_network__control__order_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_network__control__order_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_gprs__cell__opts_raw_ = {0,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI13RestOctets_gprs__cell__opts
const TTCN_Typedescriptor_t SI13RestOctets_gprs__cell__opts_descr_ = { "@GSM_RestOctets.SI13RestOctets.gprs_cell_opts", NULL, &SI13RestOctets_gprs__cell__opts_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_gprs__cell__opts_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_gprs__pwr__ctrl__params_raw_ = {0,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI13RestOctets_gprs__pwr__ctrl__params
const TTCN_Typedescriptor_t SI13RestOctets_gprs__pwr__ctrl__params_descr_ = { "@GSM_RestOctets.SI13RestOctets.gprs_pwr_ctrl_params", NULL, &SI13RestOctets_gprs__pwr__ctrl__params_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_gprs__pwr__ctrl__params_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,8,0,0,8,8,pp_0,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI13RestOctets
const TTCN_Typedescriptor_t SI13RestOctets_descr_ = { "@GSM_RestOctets.SI13RestOctets", NULL, &SI13RestOctets_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI13RestOctets_si13__change__mark_raw_ = {2,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,2,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI13RestOctets_si13__change__mark_xer_ = { {"si13_change_mark>\n", "si13_change_mark>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI13RestOctets_si13__change__mark_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI13RestOctets_si13__change__mark_descr_ = { "@GSM_RestOctets.SI13RestOctets.si13_change_mark", &BITSTRING_ber_, &SI13RestOctets_si13__change__mark_raw_, NULL, &SI13RestOctets_si13__change__mark_xer_, &BITSTRING_json_, &SI13RestOctets_si13__change__mark_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_si13__change__mark_default_coding("RAW");
const TTCN_RAWdescriptor_t SI13RestOctets_gprs__ma_raw_ = {0,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI13RestOctets_gprs__ma
const TTCN_Typedescriptor_t SI13RestOctets_gprs__ma_descr_ = { "@GSM_RestOctets.SI13RestOctets.gprs_ma", NULL, &SI13RestOctets_gprs__ma_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI13RestOctets_gprs__ma_default_coding("RAW");
UNIVERSAL_CHARSTRING SI13RestOctets_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10RestOctets_ba__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10RestOctets_ba__ind_xer_ = { {"ba_ind>\n", "ba_ind>\n"}, {8, 8}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10RestOctets_ba__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10RestOctets_ba__ind_descr_ = { "@GSM_RestOctets.SI10RestOctets.ba_ind", &BITSTRING_ber_, &SI10RestOctets_ba__ind_raw_, NULL, &SI10RestOctets_ba__ind_xer_, &BITSTRING_json_, &SI10RestOctets_ba__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10RestOctets_ba__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10RestOctets_neigh__info__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10RestOctets_neigh__info__presence_xer_ = { {"neigh_info_presence>\n", "neigh_info_presence>\n"}, {21, 21}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10RestOctets_neigh__info__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10RestOctets_neigh__info__presence_descr_ = { "@GSM_RestOctets.SI10RestOctets.neigh_info_presence", &BITSTRING_ber_, &SI10RestOctets_neigh__info__presence_raw_, NULL, &SI10RestOctets_neigh__info__presence_xer_, &BITSTRING_json_, &SI10RestOctets_neigh__info__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10RestOctets_neigh__info__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10RestOctets_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,8,0,0,8,8,pp_0,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10RestOctets
const TTCN_Typedescriptor_t SI10RestOctets_descr_ = { "@GSM_RestOctets.SI10RestOctets", NULL, &SI10RestOctets_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10NeighInfo_first__freq_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10NeighInfo_first__freq_xer_ = { {"first_freq>\n", "first_freq>\n"}, {12, 12}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10NeighInfo_first__freq_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10NeighInfo_first__freq_descr_ = { "@GSM_RestOctets.SI10NeighInfo.first_freq", &INTEGER_ber_, &SI10NeighInfo_first__freq_raw_, &INTEGER_text_, &SI10NeighInfo_first__freq_xer_, &INTEGER_json_, &SI10NeighInfo_first__freq_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10NeighInfo_first__freq_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10CellInfo_bsic_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10CellInfo_bsic_xer_ = { {"bsic>\n", "bsic>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10CellInfo_bsic_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10CellInfo_bsic_descr_ = { "@GSM_RestOctets.SI10CellInfo.bsic", &INTEGER_ber_, &SI10CellInfo_bsic_raw_, &INTEGER_text_, &SI10CellInfo_bsic_xer_, &INTEGER_json_, &SI10CellInfo_bsic_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10CellInfo_bsic_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10CellInfo_cell__params__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10CellInfo_cell__params__presence_xer_ = { {"cell_params_presence>\n", "cell_params_presence>\n"}, {22, 22}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10CellInfo_cell__params__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10CellInfo_cell__params__presence_descr_ = { "@GSM_RestOctets.SI10CellInfo.cell_params_presence", &BITSTRING_ber_, &SI10CellInfo_cell__params__presence_raw_, NULL, &SI10CellInfo_cell__params__presence_xer_, &BITSTRING_json_, &SI10CellInfo_cell__params__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10CellInfo_cell__params__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10CellInfo_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10CellInfo
const TTCN_Typedescriptor_t SI10CellInfo_descr_ = { "@GSM_RestOctets.SI10CellInfo", NULL, &SI10CellInfo_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10CellParams_cell__barred_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10CellParams_cell__barred_xer_ = { {"cell_barred>\n", "cell_barred>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10CellParams_cell__barred_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10CellParams_cell__barred_descr_ = { "@GSM_RestOctets.SI10CellParams.cell_barred", &BITSTRING_ber_, &SI10CellParams_cell__barred_raw_, NULL, &SI10CellParams_cell__barred_xer_, &BITSTRING_json_, &SI10CellParams_cell__barred_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10CellParams_cell__barred_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10CellParams_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10CellParams
const TTCN_Typedescriptor_t SI10CellParams_descr_ = { "@GSM_RestOctets.SI10CellParams", NULL, &SI10CellParams_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10FurtherCellInfo_la__different_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10FurtherCellInfo_la__different_xer_ = { {"la_different>\n", "la_different>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherCellInfo_la__different_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherCellInfo_la__different_descr_ = { "@GSM_RestOctets.SI10FurtherCellInfo.la_different", &BITSTRING_ber_, &SI10FurtherCellInfo_la__different_raw_, NULL, &SI10FurtherCellInfo_la__different_xer_, &BITSTRING_json_, &SI10FurtherCellInfo_la__different_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherCellInfo_la__different_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherCellInfo_ms__txpwr__max__cch_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherCellInfo_ms__txpwr__max__cch_xer_ = { {"ms_txpwr_max_cch>\n", "ms_txpwr_max_cch>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherCellInfo_ms__txpwr__max__cch_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherCellInfo_ms__txpwr__max__cch_descr_ = { "@GSM_RestOctets.SI10FurtherCellInfo.ms_txpwr_max_cch", &INTEGER_ber_, &SI10FurtherCellInfo_ms__txpwr__max__cch_raw_, &INTEGER_text_, &SI10FurtherCellInfo_ms__txpwr__max__cch_xer_, &INTEGER_json_, &SI10FurtherCellInfo_ms__txpwr__max__cch_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherCellInfo_ms__txpwr__max__cch_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherCellInfo_rxlev__access__min_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherCellInfo_rxlev__access__min_xer_ = { {"rxlev_access_min>\n", "rxlev_access_min>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherCellInfo_rxlev__access__min_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherCellInfo_rxlev__access__min_descr_ = { "@GSM_RestOctets.SI10FurtherCellInfo.rxlev_access_min", &INTEGER_ber_, &SI10FurtherCellInfo_rxlev__access__min_raw_, &INTEGER_text_, &SI10FurtherCellInfo_rxlev__access__min_xer_, &INTEGER_json_, &SI10FurtherCellInfo_rxlev__access__min_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherCellInfo_rxlev__access__min_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherCellInfo_cell__resel__offset_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherCellInfo_cell__resel__offset_xer_ = { {"cell_resel_offset>\n", "cell_resel_offset>\n"}, {19, 19}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherCellInfo_cell__resel__offset_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherCellInfo_cell__resel__offset_descr_ = { "@GSM_RestOctets.SI10FurtherCellInfo.cell_resel_offset", &INTEGER_ber_, &SI10FurtherCellInfo_cell__resel__offset_raw_, &INTEGER_text_, &SI10FurtherCellInfo_cell__resel__offset_xer_, &INTEGER_json_, &SI10FurtherCellInfo_cell__resel__offset_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherCellInfo_cell__resel__offset_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherCellInfo_temp__offset_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherCellInfo_temp__offset_xer_ = { {"temp_offset>\n", "temp_offset>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherCellInfo_temp__offset_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherCellInfo_temp__offset_descr_ = { "@GSM_RestOctets.SI10FurtherCellInfo.temp_offset", &INTEGER_ber_, &SI10FurtherCellInfo_temp__offset_raw_, &INTEGER_text_, &SI10FurtherCellInfo_temp__offset_xer_, &INTEGER_json_, &SI10FurtherCellInfo_temp__offset_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherCellInfo_temp__offset_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherCellInfo_penalty__time_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherCellInfo_penalty__time_xer_ = { {"penalty_time>\n", "penalty_time>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherCellInfo_penalty__time_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherCellInfo_penalty__time_descr_ = { "@GSM_RestOctets.SI10FurtherCellInfo.penalty_time", &INTEGER_ber_, &SI10FurtherCellInfo_penalty__time_raw_, &INTEGER_text_, &SI10FurtherCellInfo_penalty__time_xer_, &INTEGER_json_, &SI10FurtherCellInfo_penalty__time_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherCellInfo_penalty__time_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherCellInfo_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10FurtherCellInfo
const TTCN_Typedescriptor_t SI10FurtherCellInfo_descr_ = { "@GSM_RestOctets.SI10FurtherCellInfo", NULL, &SI10FurtherCellInfo_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10FurtherCellInfo_cell__resel__hyst_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherCellInfo_cell__resel__hyst_xer_ = { {"cell_resel_hyst>\n", "cell_resel_hyst>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherCellInfo_cell__resel__hyst_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherCellInfo_cell__resel__hyst_descr_ = { "@GSM_RestOctets.SI10FurtherCellInfo.cell_resel_hyst", &INTEGER_ber_, &SI10FurtherCellInfo_cell__resel__hyst_raw_, &INTEGER_text_, &SI10FurtherCellInfo_cell__resel__hyst_xer_, &INTEGER_json_, &SI10FurtherCellInfo_cell__resel__hyst_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherCellInfo_cell__resel__hyst_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10FurtherCellInfo_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10CellParams_further__cell__info_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10CellParams_further__cell__info
const TTCN_Typedescriptor_t SI10CellParams_further__cell__info_descr_ = { "@GSM_RestOctets.SI10CellParams.further_cell_info", NULL, &SI10CellParams_further__cell__info_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10CellParams_further__cell__info_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10CellParams_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10CellInfo_cell__params_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10CellInfo_cell__params
const TTCN_Typedescriptor_t SI10CellInfo_cell__params_descr_ = { "@GSM_RestOctets.SI10CellInfo.cell_params", NULL, &SI10CellInfo_cell__params_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10CellInfo_cell__params_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10CellInfo_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10NeighInfo_cell__info_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10NeighInfo_cell__info
const TTCN_Typedescriptor_t SI10NeighInfo_cell__info_descr_ = { "@GSM_RestOctets.SI10NeighInfo.cell_info", NULL, &SI10NeighInfo_cell__info_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10NeighInfo_cell__info_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10NeighInfo_info__field__term_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10NeighInfo_info__field__term_xer_ = { {"info_field_term>\n", "info_field_term>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10NeighInfo_info__field__term_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10NeighInfo_info__field__term_descr_ = { "@GSM_RestOctets.SI10NeighInfo.info_field_term", &BITSTRING_ber_, &SI10NeighInfo_info__field__term_raw_, NULL, &SI10NeighInfo_info__field__term_xer_, &BITSTRING_json_, &SI10NeighInfo_info__field__term_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10NeighInfo_info__field__term_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10NeighInfo_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10NeighInfo
const TTCN_Typedescriptor_t SI10NeighInfo_descr_ = { "@GSM_RestOctets.SI10NeighInfo", NULL, &SI10NeighInfo_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10InfoFieldList_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10InfoFieldList
const TTCN_Typedescriptor_t SI10InfoFieldList_descr_ = { "@GSM_RestOctets.SI10InfoFieldList", NULL, &SI10InfoFieldList_raw_, NULL, NULL, NULL, NULL, NULL, &SI10InfoFieldList_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10InfoField_item__ind_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10InfoField_item__ind_xer_ = { {"item_ind>\n", "item_ind>\n"}, {10, 10}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10InfoField_item__ind_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10InfoField_item__ind_descr_ = { "@GSM_RestOctets.SI10InfoField.item_ind", &BITSTRING_ber_, &SI10InfoField_item__ind_raw_, NULL, &SI10InfoField_item__ind_xer_, &BITSTRING_json_, &SI10InfoField_item__ind_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10InfoField_item__ind_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10InfoField_next__freq__term_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10InfoField_next__freq__term_xer_ = { {"next_freq_term>\n", "next_freq_term>\n"}, {16, 16}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10InfoField_next__freq__term_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10InfoField_next__freq__term_descr_ = { "@GSM_RestOctets.SI10InfoField.next_freq_term", &BITSTRING_ber_, &SI10InfoField_next__freq__term_raw_, NULL, &SI10InfoField_next__freq__term_xer_, &BITSTRING_json_, &SI10InfoField_next__freq__term_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10InfoField_next__freq__term_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10DiffCellInfo_bcc__or__bsic_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10DiffCellInfo_bcc__or__bsic_xer_ = { {"bcc_or_bsic>\n", "bcc_or_bsic>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10DiffCellInfo_bcc__or__bsic_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10DiffCellInfo_bcc__or__bsic_descr_ = { "@GSM_RestOctets.SI10DiffCellInfo.bcc_or_bsic", &BITSTRING_ber_, &SI10DiffCellInfo_bcc__or__bsic_raw_, NULL, &SI10DiffCellInfo_bcc__or__bsic_xer_, &BITSTRING_json_, &SI10DiffCellInfo_bcc__or__bsic_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10DiffCellInfo_bcc__or__bsic_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10DiffCellInfo_diff__cell__params__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10DiffCellInfo_diff__cell__params__presence_xer_ = { {"diff_cell_params_presence>\n", "diff_cell_params_presence>\n"}, {27, 27}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10DiffCellInfo_diff__cell__params__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10DiffCellInfo_diff__cell__params__presence_descr_ = { "@GSM_RestOctets.SI10DiffCellInfo.diff_cell_params_presence", &BITSTRING_ber_, &SI10DiffCellInfo_diff__cell__params__presence_raw_, NULL, &SI10DiffCellInfo_diff__cell__params__presence_xer_, &BITSTRING_json_, &SI10DiffCellInfo_diff__cell__params__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10DiffCellInfo_diff__cell__params__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10DiffCellInfo_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10DiffCellInfo
const TTCN_Typedescriptor_t SI10DiffCellInfo_descr_ = { "@GSM_RestOctets.SI10DiffCellInfo", NULL, &SI10DiffCellInfo_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10DiffCellInfo_bcc_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10DiffCellInfo_bcc_xer_ = { {"bcc>\n", "bcc>\n"}, {5, 5}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10DiffCellInfo_bcc_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10DiffCellInfo_bcc_descr_ = { "@GSM_RestOctets.SI10DiffCellInfo.bcc", &INTEGER_ber_, &SI10DiffCellInfo_bcc_raw_, &INTEGER_text_, &SI10DiffCellInfo_bcc_xer_, &INTEGER_json_, &SI10DiffCellInfo_bcc_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10DiffCellInfo_bcc_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10DiffCellInfo_bsic_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10DiffCellInfo_bsic_xer_ = { {"bsic>\n", "bsic>\n"}, {6, 6}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10DiffCellInfo_bsic_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10DiffCellInfo_bsic_descr_ = { "@GSM_RestOctets.SI10DiffCellInfo.bsic", &INTEGER_ber_, &SI10DiffCellInfo_bsic_raw_, &INTEGER_text_, &SI10DiffCellInfo_bsic_xer_, &INTEGER_json_, &SI10DiffCellInfo_bsic_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10DiffCellInfo_bsic_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10DiffCellParams_cell__barred_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10DiffCellParams_cell__barred_xer_ = { {"cell_barred>\n", "cell_barred>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10DiffCellParams_cell__barred_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10DiffCellParams_cell__barred_descr_ = { "@GSM_RestOctets.SI10DiffCellParams.cell_barred", &BITSTRING_ber_, &SI10DiffCellParams_cell__barred_raw_, NULL, &SI10DiffCellParams_cell__barred_xer_, &BITSTRING_json_, &SI10DiffCellParams_cell__barred_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10DiffCellParams_cell__barred_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10DiffCellParams_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10DiffCellParams
const TTCN_Typedescriptor_t SI10DiffCellParams_descr_ = { "@GSM_RestOctets.SI10DiffCellParams", NULL, &SI10DiffCellParams_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_la__different_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10FurtherDiffCellInfo_la__different_xer_ = { {"la_different>\n", "la_different>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_la__different_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_la__different_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.la_different", &BITSTRING_ber_, &SI10FurtherDiffCellInfo_la__different_raw_, NULL, &SI10FurtherDiffCellInfo_la__different_xer_, &BITSTRING_json_, &SI10FurtherDiffCellInfo_la__different_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_la__different_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_ms__txpwr__max__cch__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10FurtherDiffCellInfo_ms__txpwr__max__cch__presence_xer_ = { {"ms_txpwr_max_cch_presence>\n", "ms_txpwr_max_cch_presence>\n"}, {27, 27}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_ms__txpwr__max__cch__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_ms__txpwr__max__cch__presence_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.ms_txpwr_max_cch_presence", &BITSTRING_ber_, &SI10FurtherDiffCellInfo_ms__txpwr__max__cch__presence_raw_, NULL, &SI10FurtherDiffCellInfo_ms__txpwr__max__cch__presence_xer_, &BITSTRING_json_, &SI10FurtherDiffCellInfo_ms__txpwr__max__cch__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_ms__txpwr__max__cch__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_rxlev__access__min__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10FurtherDiffCellInfo_rxlev__access__min__presence_xer_ = { {"rxlev_access_min_presence>\n", "rxlev_access_min_presence>\n"}, {27, 27}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_rxlev__access__min__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_rxlev__access__min__presence_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.rxlev_access_min_presence", &BITSTRING_ber_, &SI10FurtherDiffCellInfo_rxlev__access__min__presence_raw_, NULL, &SI10FurtherDiffCellInfo_rxlev__access__min__presence_xer_, &BITSTRING_json_, &SI10FurtherDiffCellInfo_rxlev__access__min__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_rxlev__access__min__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_cell__resel__offset__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10FurtherDiffCellInfo_cell__resel__offset__presence_xer_ = { {"cell_resel_offset_presence>\n", "cell_resel_offset_presence>\n"}, {28, 28}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_cell__resel__offset__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_cell__resel__offset__presence_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.cell_resel_offset_presence", &BITSTRING_ber_, &SI10FurtherDiffCellInfo_cell__resel__offset__presence_raw_, NULL, &SI10FurtherDiffCellInfo_cell__resel__offset__presence_xer_, &BITSTRING_json_, &SI10FurtherDiffCellInfo_cell__resel__offset__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_cell__resel__offset__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_temp__offset__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10FurtherDiffCellInfo_temp__offset__presence_xer_ = { {"temp_offset_presence>\n", "temp_offset_presence>\n"}, {22, 22}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_temp__offset__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_temp__offset__presence_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.temp_offset_presence", &BITSTRING_ber_, &SI10FurtherDiffCellInfo_temp__offset__presence_raw_, NULL, &SI10FurtherDiffCellInfo_temp__offset__presence_xer_, &BITSTRING_json_, &SI10FurtherDiffCellInfo_temp__offset__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_temp__offset__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_penalty__time__presence_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10FurtherDiffCellInfo_penalty__time__presence_xer_ = { {"penalty_time_presence>\n", "penalty_time_presence>\n"}, {23, 23}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_penalty__time__presence_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_penalty__time__presence_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.penalty_time_presence", &BITSTRING_ber_, &SI10FurtherDiffCellInfo_penalty__time__presence_raw_, NULL, &SI10FurtherDiffCellInfo_penalty__time__presence_xer_, &BITSTRING_json_, &SI10FurtherDiffCellInfo_penalty__time__presence_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_penalty__time__presence_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10FurtherDiffCellInfo
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo", NULL, &SI10FurtherDiffCellInfo_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_cell__resel__hyst_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherDiffCellInfo_cell__resel__hyst_xer_ = { {"cell_resel_hyst>\n", "cell_resel_hyst>\n"}, {17, 17}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_cell__resel__hyst_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_cell__resel__hyst_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.cell_resel_hyst", &INTEGER_ber_, &SI10FurtherDiffCellInfo_cell__resel__hyst_raw_, &INTEGER_text_, &SI10FurtherDiffCellInfo_cell__resel__hyst_xer_, &INTEGER_json_, &SI10FurtherDiffCellInfo_cell__resel__hyst_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_cell__resel__hyst_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_ms__txpwr__max__cch_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherDiffCellInfo_ms__txpwr__max__cch_xer_ = { {"ms_txpwr_max_cch>\n", "ms_txpwr_max_cch>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_ms__txpwr__max__cch_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_ms__txpwr__max__cch_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.ms_txpwr_max_cch", &INTEGER_ber_, &SI10FurtherDiffCellInfo_ms__txpwr__max__cch_raw_, &INTEGER_text_, &SI10FurtherDiffCellInfo_ms__txpwr__max__cch_xer_, &INTEGER_json_, &SI10FurtherDiffCellInfo_ms__txpwr__max__cch_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_ms__txpwr__max__cch_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_rxlev__access__min_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherDiffCellInfo_rxlev__access__min_xer_ = { {"rxlev_access_min>\n", "rxlev_access_min>\n"}, {18, 18}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_rxlev__access__min_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_rxlev__access__min_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.rxlev_access_min", &INTEGER_ber_, &SI10FurtherDiffCellInfo_rxlev__access__min_raw_, &INTEGER_text_, &SI10FurtherDiffCellInfo_rxlev__access__min_xer_, &INTEGER_json_, &SI10FurtherDiffCellInfo_rxlev__access__min_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_rxlev__access__min_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_cell__resel__offset_raw_ = {6,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherDiffCellInfo_cell__resel__offset_xer_ = { {"cell_resel_offset>\n", "cell_resel_offset>\n"}, {19, 19}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_cell__resel__offset_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_cell__resel__offset_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.cell_resel_offset", &INTEGER_ber_, &SI10FurtherDiffCellInfo_cell__resel__offset_raw_, &INTEGER_text_, &SI10FurtherDiffCellInfo_cell__resel__offset_xer_, &INTEGER_json_, &SI10FurtherDiffCellInfo_cell__resel__offset_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_cell__resel__offset_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_temp__offset_raw_ = {3,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherDiffCellInfo_temp__offset_xer_ = { {"temp_offset>\n", "temp_offset>\n"}, {13, 13}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_temp__offset_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_temp__offset_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.temp_offset", &INTEGER_ber_, &SI10FurtherDiffCellInfo_temp__offset_raw_, &INTEGER_text_, &SI10FurtherDiffCellInfo_temp__offset_xer_, &INTEGER_json_, &SI10FurtherDiffCellInfo_temp__offset_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_temp__offset_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10FurtherDiffCellInfo_penalty__time_raw_ = {5,SG_NO,ORDER_MSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
const XERdescriptor_t       SI10FurtherDiffCellInfo_penalty__time_xer_ = { {"penalty_time>\n", "penalty_time>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED |XER_OPTIONAL, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10FurtherDiffCellInfo_penalty__time_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10FurtherDiffCellInfo_penalty__time_descr_ = { "@GSM_RestOctets.SI10FurtherDiffCellInfo.penalty_time", &INTEGER_ber_, &SI10FurtherDiffCellInfo_penalty__time_raw_, &INTEGER_text_, &SI10FurtherDiffCellInfo_penalty__time_xer_, &INTEGER_json_, &SI10FurtherDiffCellInfo_penalty__time_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_penalty__time_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10FurtherDiffCellInfo_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10DiffCellParams_further__diff__cell__info_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10DiffCellParams_further__diff__cell__info
const TTCN_Typedescriptor_t SI10DiffCellParams_further__diff__cell__info_descr_ = { "@GSM_RestOctets.SI10DiffCellParams.further_diff_cell_info", NULL, &SI10DiffCellParams_further__diff__cell__info_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10DiffCellParams_further__diff__cell__info_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10DiffCellParams_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10DiffCellInfo_diff__cell__params_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10DiffCellInfo_diff__cell__params
const TTCN_Typedescriptor_t SI10DiffCellInfo_diff__cell__params_descr_ = { "@GSM_RestOctets.SI10DiffCellInfo.diff_cell_params", NULL, &SI10DiffCellInfo_diff__cell__params_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10DiffCellInfo_diff__cell__params_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10DiffCellInfo_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10InfoField_diff__cell__info_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10InfoField_diff__cell__info
const TTCN_Typedescriptor_t SI10InfoField_diff__cell__info_descr_ = { "@GSM_RestOctets.SI10InfoField.diff_cell_info", NULL, &SI10InfoField_diff__cell__info_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10InfoField_diff__cell__info_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10InfoField_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10InfoField
const TTCN_Typedescriptor_t SI10InfoField_descr_ = { "@GSM_RestOctets.SI10InfoField", NULL, &SI10InfoField_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10NextFreqList_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10NextFreqList
const TTCN_Typedescriptor_t SI10NextFreqList_descr_ = { "@GSM_RestOctets.SI10NextFreqList", NULL, &SI10NextFreqList_raw_, NULL, NULL, NULL, NULL, NULL, &SI10NextFreqList_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
const TTCN_RAWdescriptor_t SI10NextFreq_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10NextFreq_xer_ = { {"SI10NextFreq>\n", "SI10NextFreq>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10NextFreq_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10NextFreq_descr_ = { "@GSM_RestOctets.SI10NextFreq", &BITSTRING_ber_, &SI10NextFreq_raw_, NULL, &SI10NextFreq_xer_, &BITSTRING_json_, &SI10NextFreq_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10NextFreq_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10NextFreqList_0_raw_ = {1,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,1,CharCoding::UNKNOWN_CHAR_CODING,NULL,true};
const XERdescriptor_t       SI10NextFreqList_0_xer_ = { {"SI10NextFreq>\n", "SI10NextFreq>\n"}, {14, 14}, 0 |FORM_UNQUALIFIED, WHITESPACE_PRESERVE,  NULL, &module_object, -1, 0, NULL, NULL, -1, XSD_NONE };
const TTCN_OERdescriptor_t SI10NextFreqList_0_oer_ = { -1, FALSE, -1, FALSE, 0, 0, NULL, 0, NULL };
const TTCN_Typedescriptor_t SI10NextFreqList_0_descr_ = { "@GSM_RestOctets.SI10NextFreqList.<oftype>", &BITSTRING_ber_, &SI10NextFreqList_0_raw_, NULL, &SI10NextFreqList_0_xer_, &BITSTRING_json_, &SI10NextFreqList_0_oer_, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10NextFreqList_0_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10NextFreqList_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10InfoField_next__freq_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10InfoField_next__freq
const TTCN_Typedescriptor_t SI10InfoField_next__freq_descr_ = { "@GSM_RestOctets.SI10InfoField.next_freq", NULL, &SI10InfoField_next__freq_raw_, NULL, NULL, NULL, NULL, NULL, &SI10NextFreqList_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10InfoField_next__freq_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10InfoField_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10InfoFieldList_0_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10InfoFieldList_0
const TTCN_Typedescriptor_t SI10InfoFieldList_0_descr_ = { "@GSM_RestOctets.SI10InfoFieldList.<oftype>", NULL, &SI10InfoFieldList_0_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10InfoFieldList_0_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10InfoFieldList_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10NeighInfo_info__field_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10NeighInfo_info__field
const TTCN_Typedescriptor_t SI10NeighInfo_info__field_descr_ = { "@GSM_RestOctets.SI10NeighInfo.info_field", NULL, &SI10NeighInfo_info__field_raw_, NULL, NULL, NULL, NULL, NULL, &SI10InfoFieldList_0_descr_, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10NeighInfo_info__field_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10NeighInfo_default_coding("RAW");
const TTCN_RAWdescriptor_t SI10RestOctets_neigh__info_raw_ = {0,SG_NO,ORDER_LSB,ORDER_LSB,ORDER_LSB,ORDER_LSB,EXT_BIT_NO,ORDER_LSB,ORDER_MSB,TOP_BIT_INHERITED,0,0,0,8,0,NULL,-1,CharCoding::UNKNOWN_CHAR_CODING,NULL,false};
// No XER for SI10RestOctets_neigh__info
const TTCN_Typedescriptor_t SI10RestOctets_neigh__info_descr_ = { "@GSM_RestOctets.SI10RestOctets.neigh_info", NULL, &SI10RestOctets_neigh__info_raw_, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
UNIVERSAL_CHARSTRING SI10RestOctets_neigh__info_default_coding("RAW");
UNIVERSAL_CHARSTRING SI10RestOctets_default_coding("RAW");
SI3RestOctets_template template_ts__SI3RestOctets;
const SI3RestOctets_template& ts__SI3RestOctets = template_ts__SI3RestOctets;
SI4RestOctets_template template_ts__SI4RestOctets;
const SI4RestOctets_template& ts__SI4RestOctets = template_ts__SI4RestOctets;
TTCN_Module module_object("GSM_RestOctets", __DATE__, __TIME__, module_checksum, pre_init_module, NULL, 0U, 4294967295U, 4294967295U, 4294967295U, NULL, 0LU, 0, post_init_module, NULL, NULL, NULL, NULL, NULL, NULL, NULL);

const RuntimeVersionChecker ver_checker(  current_runtime_version.requires_major_version_11,
  current_runtime_version.requires_minor_version_1,
  current_runtime_version.requires_patch_level_0,  current_runtime_version.requires_runtime_1);

/* Member functions of C++ classes */

IaRestOctets::IaRestOctets()
{
}

IaRestOctets::IaRestOctets(const BITSTRING& par_presence,
    const OPTIONAL< IaRestOctLL >& par_ll,
    const OPTIONAL< IaRestOctLH >& par_lh,
    const OPTIONAL< IaRestOctHL >& par_hl,
    const OPTIONAL< IaRestOctHH >& par_hh)
  :   field_presence(par_presence),
  field_ll(par_ll),
  field_lh(par_lh),
  field_hl(par_hl),
  field_hh(par_hh)
{
}

IaRestOctets::IaRestOctets(const IaRestOctets& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.IaRestOctets.");
if (other_value.presence().is_bound()) field_presence = other_value.presence();
else field_presence.clean_up();
if (other_value.ll().is_bound()) field_ll = other_value.ll();
else field_ll.clean_up();
if (other_value.lh().is_bound()) field_lh = other_value.lh();
else field_lh.clean_up();
if (other_value.hl().is_bound()) field_hl = other_value.hl();
else field_hl.clean_up();
if (other_value.hh().is_bound()) field_hh = other_value.hh();
else field_hh.clean_up();
}

void IaRestOctets::clean_up()
{
field_presence.clean_up();
field_ll.clean_up();
field_lh.clean_up();
field_hl.clean_up();
field_hh.clean_up();
}

const TTCN_Typedescriptor_t* IaRestOctets::get_descriptor() const { return &IaRestOctets_descr_; }
IaRestOctets& IaRestOctets::operator=(const IaRestOctets& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.IaRestOctets.");
  if (other_value.presence().is_bound()) field_presence = other_value.presence();
  else field_presence.clean_up();
  if (other_value.ll().is_bound()) field_ll = other_value.ll();
  else field_ll.clean_up();
  if (other_value.lh().is_bound()) field_lh = other_value.lh();
  else field_lh.clean_up();
  if (other_value.hl().is_bound()) field_hl = other_value.hl();
  else field_hl.clean_up();
  if (other_value.hh().is_bound()) field_hh = other_value.hh();
  else field_hh.clean_up();
}
return *this;
}

boolean IaRestOctets::operator==(const IaRestOctets& other_value) const
{
return field_presence==other_value.field_presence
  && field_ll==other_value.field_ll
  && field_lh==other_value.field_lh
  && field_hl==other_value.field_hl
  && field_hh==other_value.field_hh;
}

boolean IaRestOctets::is_bound() const
{
return (field_presence.is_bound())
  || (OPTIONAL_OMIT == field_ll.get_selection() || field_ll.is_bound())
  || (OPTIONAL_OMIT == field_lh.get_selection() || field_lh.is_bound())
  || (OPTIONAL_OMIT == field_hl.get_selection() || field_hl.is_bound())
  || (OPTIONAL_OMIT == field_hh.get_selection() || field_hh.is_bound());
}
boolean IaRestOctets::is_value() const
{
return field_presence.is_value()
  && (OPTIONAL_OMIT == field_ll.get_selection() || field_ll.is_value())
  && (OPTIONAL_OMIT == field_lh.get_selection() || field_lh.is_value())
  && (OPTIONAL_OMIT == field_hl.get_selection() || field_hl.is_value())
  && (OPTIONAL_OMIT == field_hh.get_selection() || field_hh.is_value());
}
int IaRestOctets::size_of() const
{
  int ret_val = 1;
  if (field_ll.ispresent()) ret_val++;
  if (field_lh.ispresent()) ret_val++;
  if (field_hl.ispresent()) ret_val++;
  if (field_hh.ispresent()) ret_val++;
  return ret_val;
}

void IaRestOctets::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ presence := ");
field_presence.log();
TTCN_Logger::log_event_str(", ll := ");
field_ll.log();
TTCN_Logger::log_event_str(", lh := ");
field_lh.log();
TTCN_Logger::log_event_str(", hl := ");
field_hl.log();
TTCN_Logger::log_event_str(", hh := ");
field_hh.log();
TTCN_Logger::log_event_str(" }");
}

void IaRestOctets::set_implicit_omit()
{
if (presence().is_bound()) presence().set_implicit_omit();
if (!ll().is_bound()) ll() = OMIT_VALUE;
else ll().set_implicit_omit();
if (!lh().is_bound()) lh() = OMIT_VALUE;
else lh().set_implicit_omit();
if (!hl().is_bound()) hl() = OMIT_VALUE;
else hl().set_implicit_omit();
if (!hh().is_bound()) hh() = OMIT_VALUE;
else hh().set_implicit_omit();
}

void IaRestOctets::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (5<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.IaRestOctets has 5 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) ll().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) lh().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) hl().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) hh().set_param(*param.get_elem(4));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ll")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ll().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "lh")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          lh().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "hl")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          hl().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "hh")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          hh().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctets: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.IaRestOctets");
  }
}

void IaRestOctets::encode_text(Text_Buf& text_buf) const
{
field_presence.encode_text(text_buf);
field_ll.encode_text(text_buf);
field_lh.encode_text(text_buf);
field_hl.encode_text(text_buf);
field_hh.encode_text(text_buf);
}

void IaRestOctets::decode_text(Text_Buf& text_buf)
{
field_presence.decode_text(text_buf);
field_ll.decode_text(text_buf);
field_lh.decode_text(text_buf);
field_hl.decode_text(text_buf);
field_hh.decode_text(text_buf);
}

void IaRestOctets::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void IaRestOctets::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int IaRestOctets::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, IaRestOctets_presence_descr_.raw->forceomit);
  decoded_field_length = field_presence.RAW_decode(IaRestOctets_presence_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_presence ==  bs_2){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_ll = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, IaRestOctets_ll_descr_.raw->forceomit);
  decoded_field_length = field_ll().RAW_decode(IaRestOctets_ll_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_ll = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_ll=OMIT_VALUE;
  if (limit > 0 && field_presence ==  bs_3){
  if (force_omit != NULL && (*force_omit)(2)) {
    field_lh = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_2_force_omit(2, force_omit, IaRestOctets_lh_descr_.raw->forceomit);
  decoded_field_length = field_lh().RAW_decode(IaRestOctets_lh_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 1) {
  field_lh = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_lh=OMIT_VALUE;
  if (limit > 0 && field_presence ==  bs_4){
  if (force_omit != NULL && (*force_omit)(3)) {
    field_hl = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_3_force_omit(3, force_omit, IaRestOctets_hl_descr_.raw->forceomit);
  decoded_field_length = field_hl().RAW_decode(IaRestOctets_hl_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_3_force_omit);
  if (decoded_field_length < 1) {
  field_hl = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_hl=OMIT_VALUE;
  if (limit > 0 && field_presence ==  bs_5){
  if (force_omit != NULL && (*force_omit)(4)) {
    field_hh = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_4_force_omit(4, force_omit, IaRestOctets_hh_descr_.raw->forceomit);
  decoded_field_length = field_hh().RAW_decode(IaRestOctets_hh_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_4_force_omit);
  if (decoded_field_length < 1) {
  field_hh = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_hh=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int IaRestOctets::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 5;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(5);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, IaRestOctets_presence_descr_.raw);
  if (field_ll.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, IaRestOctets_ll_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  if (field_lh.ispresent()) {
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, IaRestOctets_lh_descr_.raw);
  }
  else myleaf.body.node.nodes[2] = NULL;
  if (field_hl.ispresent()) {
  myleaf.body.node.nodes[3] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 3, IaRestOctets_hl_descr_.raw);
  }
  else myleaf.body.node.nodes[3] = NULL;
  if (field_hh.ispresent()) {
  myleaf.body.node.nodes[4] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 4, IaRestOctets_hh_descr_.raw);
  }
  else myleaf.body.node.nodes[4] = NULL;
  encoded_length += field_presence.RAW_encode(IaRestOctets_presence_descr_, *myleaf.body.node.nodes[0]);
  if (field_ll.ispresent()) {
  encoded_length += field_ll().RAW_encode(IaRestOctets_ll_descr_, *myleaf.body.node.nodes[1]);
  }
  if (field_lh.ispresent()) {
  encoded_length += field_lh().RAW_encode(IaRestOctets_lh_descr_, *myleaf.body.node.nodes[2]);
  }
  if (field_hl.ispresent()) {
  encoded_length += field_hl().RAW_encode(IaRestOctets_hl_descr_, *myleaf.body.node.nodes[3]);
  }
  if (field_hh.ispresent()) {
  encoded_length += field_hh().RAW_encode(IaRestOctets_hh_descr_, *myleaf.body.node.nodes[4]);
  }
  if (field_ll.ispresent() && (field_presence !=  bs_2)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_2.RAW_encode(IaRestOctets_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_lh.ispresent() && (field_presence !=  bs_3)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_3.RAW_encode(IaRestOctets_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_hl.ispresent() && (field_presence !=  bs_4)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_4.RAW_encode(IaRestOctets_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_hh.ispresent() && (field_presence !=  bs_5)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_5.RAW_encode(IaRestOctets_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct IaRestOctets_template::single_value_struct {
BITSTRING_template field_presence;
IaRestOctLL_template field_ll;
IaRestOctLH_template field_lh;
IaRestOctHL_template field_hl;
IaRestOctHH_template field_hh;
};

void IaRestOctets_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_presence = ANY_VALUE;
single_value->field_ll = ANY_OR_OMIT;
single_value->field_lh = ANY_OR_OMIT;
single_value->field_hl = ANY_OR_OMIT;
single_value->field_hh = ANY_OR_OMIT;
}
}
}

void IaRestOctets_template::copy_value(const IaRestOctets& other_value)
{
single_value = new single_value_struct;
if (other_value.presence().is_bound()) {
  single_value->field_presence = other_value.presence();
} else {
  single_value->field_presence.clean_up();
}
if (other_value.ll().is_bound()) {
  if (other_value.ll().ispresent()) single_value->field_ll = other_value.ll()();
  else single_value->field_ll = OMIT_VALUE;
} else {
  single_value->field_ll.clean_up();
}
if (other_value.lh().is_bound()) {
  if (other_value.lh().ispresent()) single_value->field_lh = other_value.lh()();
  else single_value->field_lh = OMIT_VALUE;
} else {
  single_value->field_lh.clean_up();
}
if (other_value.hl().is_bound()) {
  if (other_value.hl().ispresent()) single_value->field_hl = other_value.hl()();
  else single_value->field_hl = OMIT_VALUE;
} else {
  single_value->field_hl.clean_up();
}
if (other_value.hh().is_bound()) {
  if (other_value.hh().ispresent()) single_value->field_hh = other_value.hh()();
  else single_value->field_hh = OMIT_VALUE;
} else {
  single_value->field_hh.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void IaRestOctets_template::copy_template(const IaRestOctets_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.presence().get_selection()) {
single_value->field_presence = other_value.presence();
} else {
single_value->field_presence.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ll().get_selection()) {
single_value->field_ll = other_value.ll();
} else {
single_value->field_ll.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.lh().get_selection()) {
single_value->field_lh = other_value.lh();
} else {
single_value->field_lh.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.hl().get_selection()) {
single_value->field_hl = other_value.hl();
} else {
single_value->field_hl.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.hh().get_selection()) {
single_value->field_hh = other_value.hh();
} else {
single_value->field_hh.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new IaRestOctets_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new IaRestOctets_template(*other_value.implication_.precondition);
implication_.implied_template = new IaRestOctets_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctets.");
break;
}
set_selection(other_value);
}

IaRestOctets_template::IaRestOctets_template()
{
}

IaRestOctets_template::IaRestOctets_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

IaRestOctets_template::IaRestOctets_template(const IaRestOctets& other_value)
{
copy_value(other_value);
}

IaRestOctets_template::IaRestOctets_template(const OPTIONAL<IaRestOctets>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctets&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.IaRestOctets from an unbound optional field.");
}
}

IaRestOctets_template::IaRestOctets_template(IaRestOctets_template* p_precondition, IaRestOctets_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

IaRestOctets_template::IaRestOctets_template(Dynamic_Match_Interface<IaRestOctets>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<IaRestOctets>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

IaRestOctets_template::IaRestOctets_template(const IaRestOctets_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

IaRestOctets_template::~IaRestOctets_template()
{
clean_up();
}

IaRestOctets_template& IaRestOctets_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

IaRestOctets_template& IaRestOctets_template::operator=(const IaRestOctets& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

IaRestOctets_template& IaRestOctets_template::operator=(const OPTIONAL<IaRestOctets>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctets&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.IaRestOctets.");
}
return *this;
}

IaRestOctets_template& IaRestOctets_template::operator=(const IaRestOctets_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean IaRestOctets_template::match(const IaRestOctets& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.presence().is_bound()) return FALSE;
if(!single_value->field_presence.match(other_value.presence(), legacy))return FALSE;
if(!other_value.ll().is_bound()) return FALSE;
if((other_value.ll().ispresent() ? !single_value->field_ll.match((const IaRestOctLL&)other_value.ll(), legacy) : !single_value->field_ll.match_omit(legacy)))return FALSE;
if(!other_value.lh().is_bound()) return FALSE;
if((other_value.lh().ispresent() ? !single_value->field_lh.match((const IaRestOctLH&)other_value.lh(), legacy) : !single_value->field_lh.match_omit(legacy)))return FALSE;
if(!other_value.hl().is_bound()) return FALSE;
if((other_value.hl().ispresent() ? !single_value->field_hl.match((const IaRestOctHL&)other_value.hl(), legacy) : !single_value->field_hl.match_omit(legacy)))return FALSE;
if(!other_value.hh().is_bound()) return FALSE;
if((other_value.hh().ispresent() ? !single_value->field_hh.match((const IaRestOctHH&)other_value.hh(), legacy) : !single_value->field_hh.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctets.");
}
return FALSE;
}

boolean IaRestOctets_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_presence.is_bound()
 || (single_value->field_ll.is_omit() || single_value->field_ll.is_bound())
 || (single_value->field_lh.is_omit() || single_value->field_lh.is_bound())
 || (single_value->field_hl.is_omit() || single_value->field_hl.is_bound())
 || (single_value->field_hh.is_omit() || single_value->field_hh.is_bound());
}

boolean IaRestOctets_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_presence.is_value()
 && (single_value->field_ll.is_omit() || single_value->field_ll.is_value())
 && (single_value->field_lh.is_omit() || single_value->field_lh.is_value())
 && (single_value->field_hl.is_omit() || single_value->field_hl.is_value())
 && (single_value->field_hh.is_omit() || single_value->field_hh.is_value());
}

void IaRestOctets_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

IaRestOctets IaRestOctets_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.IaRestOctets.");
IaRestOctets ret_val;
if (single_value->field_presence.is_bound()) {
ret_val.presence() = single_value->field_presence.valueof();
}
if (single_value->field_ll.is_omit()) ret_val.ll() = OMIT_VALUE;
else if (single_value->field_ll.is_bound()) {
ret_val.ll() = single_value->field_ll.valueof();
}
if (single_value->field_lh.is_omit()) ret_val.lh() = OMIT_VALUE;
else if (single_value->field_lh.is_bound()) {
ret_val.lh() = single_value->field_lh.valueof();
}
if (single_value->field_hl.is_omit()) ret_val.hl() = OMIT_VALUE;
else if (single_value->field_hl.is_bound()) {
ret_val.hl() = single_value->field_hl.valueof();
}
if (single_value->field_hh.is_omit()) ret_val.hh() = OMIT_VALUE;
else if (single_value->field_hh.is_bound()) {
ret_val.hh() = single_value->field_hh.valueof();
}
return ret_val;
}

void IaRestOctets_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.IaRestOctets.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new IaRestOctets_template[list_length];
}

IaRestOctets_template& IaRestOctets_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.IaRestOctets.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.IaRestOctets.");
return value_list.list_value[list_index];
}

BITSTRING_template& IaRestOctets_template::presence()
{
set_specific();
return single_value->field_presence;
}

const BITSTRING_template& IaRestOctets_template::presence() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field presence of a non-specific template of type @GSM_RestOctets.IaRestOctets.");
return single_value->field_presence;
}

IaRestOctLL_template& IaRestOctets_template::ll()
{
set_specific();
return single_value->field_ll;
}

const IaRestOctLL_template& IaRestOctets_template::ll() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ll of a non-specific template of type @GSM_RestOctets.IaRestOctets.");
return single_value->field_ll;
}

IaRestOctLH_template& IaRestOctets_template::lh()
{
set_specific();
return single_value->field_lh;
}

const IaRestOctLH_template& IaRestOctets_template::lh() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field lh of a non-specific template of type @GSM_RestOctets.IaRestOctets.");
return single_value->field_lh;
}

IaRestOctHL_template& IaRestOctets_template::hl()
{
set_specific();
return single_value->field_hl;
}

const IaRestOctHL_template& IaRestOctets_template::hl() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field hl of a non-specific template of type @GSM_RestOctets.IaRestOctets.");
return single_value->field_hl;
}

IaRestOctHH_template& IaRestOctets_template::hh()
{
set_specific();
return single_value->field_hh;
}

const IaRestOctHH_template& IaRestOctets_template::hh() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field hh of a non-specific template of type @GSM_RestOctets.IaRestOctets.");
return single_value->field_hh;
}

int IaRestOctets_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctets which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 1;
      if (single_value->field_ll.is_present()) ret_val++;
      if (single_value->field_lh.is_present()) ret_val++;
      if (single_value->field_hl.is_present()) ret_val++;
      if (single_value->field_hh.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctets containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctets containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctets containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctets containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctets containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctets containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctets containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctets containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctets.");
  }
  return 0;
}

void IaRestOctets_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log();
TTCN_Logger::log_event_str(", ll := ");
single_value->field_ll.log();
TTCN_Logger::log_event_str(", lh := ");
single_value->field_lh.log();
TTCN_Logger::log_event_str(", hl := ");
single_value->field_hl.log();
TTCN_Logger::log_event_str(", hh := ");
single_value->field_hh.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void IaRestOctets_template::log_match(const IaRestOctets& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_presence.match(match_value.presence(), legacy)){
TTCN_Logger::log_logmatch_info(".presence");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.ll().ispresent()){
if(!single_value->field_ll.match(match_value.ll(), legacy)){
TTCN_Logger::log_logmatch_info(".ll");
single_value->field_ll.log_match(match_value.ll(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_ll.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".ll := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_ll.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.lh().ispresent()){
if(!single_value->field_lh.match(match_value.lh(), legacy)){
TTCN_Logger::log_logmatch_info(".lh");
single_value->field_lh.log_match(match_value.lh(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_lh.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".lh := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_lh.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.hl().ispresent()){
if(!single_value->field_hl.match(match_value.hl(), legacy)){
TTCN_Logger::log_logmatch_info(".hl");
single_value->field_hl.log_match(match_value.hl(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_hl.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".hl := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_hl.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.hh().ispresent()){
if(!single_value->field_hh.match(match_value.hh(), legacy)){
TTCN_Logger::log_logmatch_info(".hh");
single_value->field_hh.log_match(match_value.hh(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_hh.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".hh := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_hh.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::log_event_str(", ll := ");
if (match_value.ll().ispresent()) {
single_value->field_ll.log_match(match_value.ll(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_ll.log();
if (single_value->field_ll.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", lh := ");
if (match_value.lh().ispresent()) {
single_value->field_lh.log_match(match_value.lh(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_lh.log();
if (single_value->field_lh.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", hl := ");
if (match_value.hl().ispresent()) {
single_value->field_hl.log_match(match_value.hl(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_hl.log();
if (single_value->field_hl.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", hh := ");
if (match_value.hh().ispresent()) {
single_value->field_hh.log_match(match_value.hh(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_hh.log();
if (single_value->field_hh.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void IaRestOctets_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (presence().is_bound()) presence().set_implicit_omit();
if (!ll().is_bound()) ll() = OMIT_VALUE;
else ll().set_implicit_omit();
if (!lh().is_bound()) lh() = OMIT_VALUE;
else lh().set_implicit_omit();
if (!hl().is_bound()) hl() = OMIT_VALUE;
else hl().set_implicit_omit();
if (!hh().is_bound()) hh() = OMIT_VALUE;
else hh().set_implicit_omit();
}

void IaRestOctets_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_presence.encode_text(text_buf);
single_value->field_ll.encode_text(text_buf);
single_value->field_lh.encode_text(text_buf);
single_value->field_hl.encode_text(text_buf);
single_value->field_hh.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctets.");
}
}

void IaRestOctets_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_presence.decode_text(text_buf);
single_value->field_ll.decode_text(text_buf);
single_value->field_lh.decode_text(text_buf);
single_value->field_hl.decode_text(text_buf);
single_value->field_hh.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new IaRestOctets_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.IaRestOctets.");
}
}

void IaRestOctets_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    IaRestOctets_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (5<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.IaRestOctets has 5 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) ll().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) lh().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) hl().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) hh().set_param(*param.get_elem(4));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ll")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ll().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "lh")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          lh().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "hl")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          hl().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "hh")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          hh().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctets: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    IaRestOctets_template* precondition = new IaRestOctets_template;
    precondition->set_param(*param.get_elem(0));
    IaRestOctets_template* implied_template = new IaRestOctets_template;
    implied_template->set_param(*param.get_elem(1));
    *this = IaRestOctets_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.IaRestOctets");
  }
  is_ifpresent = param.get_ifpresent();
}

void IaRestOctets_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_presence.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctets");
single_value->field_ll.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctets");
single_value->field_lh.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctets");
single_value->field_hl.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctets");
single_value->field_hh.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctets");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.IaRestOctets");
}

boolean IaRestOctets_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean IaRestOctets_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

IaRestOctLL::IaRestOctLL()
{
}

IaRestOctLL::IaRestOctLL(const BITSTRING& par_compressed__irat__ho__info__ind)
  :   field_compressed__irat__ho__info__ind(par_compressed__irat__ho__info__ind)
{
}

IaRestOctLL::IaRestOctLL(const IaRestOctLL& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.IaRestOctLL.");
if (other_value.compressed__irat__ho__info__ind().is_bound()) field_compressed__irat__ho__info__ind = other_value.compressed__irat__ho__info__ind();
else field_compressed__irat__ho__info__ind.clean_up();
}

void IaRestOctLL::clean_up()
{
field_compressed__irat__ho__info__ind.clean_up();
}

const TTCN_Typedescriptor_t* IaRestOctLL::get_descriptor() const { return &IaRestOctLL_descr_; }
IaRestOctLL& IaRestOctLL::operator=(const IaRestOctLL& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.IaRestOctLL.");
  if (other_value.compressed__irat__ho__info__ind().is_bound()) field_compressed__irat__ho__info__ind = other_value.compressed__irat__ho__info__ind();
  else field_compressed__irat__ho__info__ind.clean_up();
}
return *this;
}

boolean IaRestOctLL::operator==(const IaRestOctLL& other_value) const
{
return field_compressed__irat__ho__info__ind==other_value.field_compressed__irat__ho__info__ind;
}

boolean IaRestOctLL::is_bound() const
{
return (field_compressed__irat__ho__info__ind.is_bound());
}
boolean IaRestOctLL::is_value() const
{
return field_compressed__irat__ho__info__ind.is_value();
}
void IaRestOctLL::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ compressed_irat_ho_info_ind := ");
field_compressed__irat__ho__info__ind.log();
TTCN_Logger::log_event_str(" }");
}

void IaRestOctLL::set_implicit_omit()
{
if (compressed__irat__ho__info__ind().is_bound()) compressed__irat__ho__info__ind().set_implicit_omit();
}

void IaRestOctLL::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (1<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.IaRestOctLL has 1 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) compressed__irat__ho__info__ind().set_param(*param.get_elem(0));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "compressed_irat_ho_info_ind")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          compressed__irat__ho__info__ind().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctLL: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.IaRestOctLL");
  }
}

void IaRestOctLL::encode_text(Text_Buf& text_buf) const
{
field_compressed__irat__ho__info__ind.encode_text(text_buf);
}

void IaRestOctLL::decode_text(Text_Buf& text_buf)
{
field_compressed__irat__ho__info__ind.decode_text(text_buf);
}

void IaRestOctLL::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void IaRestOctLL::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int IaRestOctLL::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, IaRestOctLL_compressed__irat__ho__info__ind_descr_.raw->forceomit);
  decoded_field_length = field_compressed__irat__ho__info__ind.RAW_decode(IaRestOctLL_compressed__irat__ho__info__ind_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int IaRestOctLL::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 1;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(1);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, IaRestOctLL_compressed__irat__ho__info__ind_descr_.raw);
  encoded_length += field_compressed__irat__ho__info__ind.RAW_encode(IaRestOctLL_compressed__irat__ho__info__ind_descr_, *myleaf.body.node.nodes[0]);
  return myleaf.length = encoded_length;
}

struct IaRestOctLL_template::single_value_struct {
BITSTRING_template field_compressed__irat__ho__info__ind;
};

void IaRestOctLL_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_compressed__irat__ho__info__ind = ANY_VALUE;
}
}
}

void IaRestOctLL_template::copy_value(const IaRestOctLL& other_value)
{
single_value = new single_value_struct;
if (other_value.compressed__irat__ho__info__ind().is_bound()) {
  single_value->field_compressed__irat__ho__info__ind = other_value.compressed__irat__ho__info__ind();
} else {
  single_value->field_compressed__irat__ho__info__ind.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void IaRestOctLL_template::copy_template(const IaRestOctLL_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.compressed__irat__ho__info__ind().get_selection()) {
single_value->field_compressed__irat__ho__info__ind = other_value.compressed__irat__ho__info__ind();
} else {
single_value->field_compressed__irat__ho__info__ind.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new IaRestOctLL_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new IaRestOctLL_template(*other_value.implication_.precondition);
implication_.implied_template = new IaRestOctLL_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctLL.");
break;
}
set_selection(other_value);
}

IaRestOctLL_template::IaRestOctLL_template()
{
}

IaRestOctLL_template::IaRestOctLL_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

IaRestOctLL_template::IaRestOctLL_template(const IaRestOctLL& other_value)
{
copy_value(other_value);
}

IaRestOctLL_template::IaRestOctLL_template(const OPTIONAL<IaRestOctLL>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctLL&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.IaRestOctLL from an unbound optional field.");
}
}

IaRestOctLL_template::IaRestOctLL_template(IaRestOctLL_template* p_precondition, IaRestOctLL_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

IaRestOctLL_template::IaRestOctLL_template(Dynamic_Match_Interface<IaRestOctLL>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<IaRestOctLL>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

IaRestOctLL_template::IaRestOctLL_template(const IaRestOctLL_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

IaRestOctLL_template::~IaRestOctLL_template()
{
clean_up();
}

IaRestOctLL_template& IaRestOctLL_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

IaRestOctLL_template& IaRestOctLL_template::operator=(const IaRestOctLL& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

IaRestOctLL_template& IaRestOctLL_template::operator=(const OPTIONAL<IaRestOctLL>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctLL&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.IaRestOctLL.");
}
return *this;
}

IaRestOctLL_template& IaRestOctLL_template::operator=(const IaRestOctLL_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean IaRestOctLL_template::match(const IaRestOctLL& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.compressed__irat__ho__info__ind().is_bound()) return FALSE;
if(!single_value->field_compressed__irat__ho__info__ind.match(other_value.compressed__irat__ho__info__ind(), legacy))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctLL.");
}
return FALSE;
}

boolean IaRestOctLL_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_compressed__irat__ho__info__ind.is_bound();
}

boolean IaRestOctLL_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_compressed__irat__ho__info__ind.is_value();
}

void IaRestOctLL_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

IaRestOctLL IaRestOctLL_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.IaRestOctLL.");
IaRestOctLL ret_val;
if (single_value->field_compressed__irat__ho__info__ind.is_bound()) {
ret_val.compressed__irat__ho__info__ind() = single_value->field_compressed__irat__ho__info__ind.valueof();
}
return ret_val;
}

void IaRestOctLL_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.IaRestOctLL.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new IaRestOctLL_template[list_length];
}

IaRestOctLL_template& IaRestOctLL_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.IaRestOctLL.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.IaRestOctLL.");
return value_list.list_value[list_index];
}

BITSTRING_template& IaRestOctLL_template::compressed__irat__ho__info__ind()
{
set_specific();
return single_value->field_compressed__irat__ho__info__ind;
}

const BITSTRING_template& IaRestOctLL_template::compressed__irat__ho__info__ind() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field compressed_irat_ho_info_ind of a non-specific template of type @GSM_RestOctets.IaRestOctLL.");
return single_value->field_compressed__irat__ho__info__ind;
}

int IaRestOctLL_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLL which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
    return 1;
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLL containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLL containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLL containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLL containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLL containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLL containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLL containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLL containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctLL.");
  }
  return 0;
}

void IaRestOctLL_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ compressed_irat_ho_info_ind := ");
single_value->field_compressed__irat__ho__info__ind.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void IaRestOctLL_template::log_match(const IaRestOctLL& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_compressed__irat__ho__info__ind.match(match_value.compressed__irat__ho__info__ind(), legacy)){
TTCN_Logger::log_logmatch_info(".compressed_irat_ho_info_ind");
single_value->field_compressed__irat__ho__info__ind.log_match(match_value.compressed__irat__ho__info__ind(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ compressed_irat_ho_info_ind := ");
single_value->field_compressed__irat__ho__info__ind.log_match(match_value.compressed__irat__ho__info__ind(), legacy);
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void IaRestOctLL_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (compressed__irat__ho__info__ind().is_bound()) compressed__irat__ho__info__ind().set_implicit_omit();
}

void IaRestOctLL_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_compressed__irat__ho__info__ind.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctLL.");
}
}

void IaRestOctLL_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_compressed__irat__ho__info__ind.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new IaRestOctLL_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.IaRestOctLL.");
}
}

void IaRestOctLL_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    IaRestOctLL_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (1<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.IaRestOctLL has 1 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) compressed__irat__ho__info__ind().set_param(*param.get_elem(0));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "compressed_irat_ho_info_ind")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          compressed__irat__ho__info__ind().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctLL: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    IaRestOctLL_template* precondition = new IaRestOctLL_template;
    precondition->set_param(*param.get_elem(0));
    IaRestOctLL_template* implied_template = new IaRestOctLL_template;
    implied_template->set_param(*param.get_elem(1));
    *this = IaRestOctLL_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.IaRestOctLL");
  }
  is_ifpresent = param.get_ifpresent();
}

void IaRestOctLL_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_compressed__irat__ho__info__ind.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctLL");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.IaRestOctLL");
}

boolean IaRestOctLL_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean IaRestOctLL_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

IaRestOctLH::IaRestOctLH()
{
}

IaRestOctLH::IaRestOctLH(const BITSTRING& par_presence,
    const OPTIONAL< EgprsUlAss >& par_egprs__ul,
    const OPTIONAL< OCTETSTRING >& par_multiblock__dl__ass)
  :   field_presence(par_presence),
  field_egprs__ul(par_egprs__ul),
  field_multiblock__dl__ass(par_multiblock__dl__ass)
{
}

IaRestOctLH::IaRestOctLH(const IaRestOctLH& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.IaRestOctLH.");
if (other_value.presence().is_bound()) field_presence = other_value.presence();
else field_presence.clean_up();
if (other_value.egprs__ul().is_bound()) field_egprs__ul = other_value.egprs__ul();
else field_egprs__ul.clean_up();
if (other_value.multiblock__dl__ass().is_bound()) field_multiblock__dl__ass = other_value.multiblock__dl__ass();
else field_multiblock__dl__ass.clean_up();
}

void IaRestOctLH::clean_up()
{
field_presence.clean_up();
field_egprs__ul.clean_up();
field_multiblock__dl__ass.clean_up();
}

const TTCN_Typedescriptor_t* IaRestOctLH::get_descriptor() const { return &IaRestOctLH_descr_; }
IaRestOctLH& IaRestOctLH::operator=(const IaRestOctLH& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.IaRestOctLH.");
  if (other_value.presence().is_bound()) field_presence = other_value.presence();
  else field_presence.clean_up();
  if (other_value.egprs__ul().is_bound()) field_egprs__ul = other_value.egprs__ul();
  else field_egprs__ul.clean_up();
  if (other_value.multiblock__dl__ass().is_bound()) field_multiblock__dl__ass = other_value.multiblock__dl__ass();
  else field_multiblock__dl__ass.clean_up();
}
return *this;
}

boolean IaRestOctLH::operator==(const IaRestOctLH& other_value) const
{
return field_presence==other_value.field_presence
  && field_egprs__ul==other_value.field_egprs__ul
  && field_multiblock__dl__ass==other_value.field_multiblock__dl__ass;
}

boolean IaRestOctLH::is_bound() const
{
return (field_presence.is_bound())
  || (OPTIONAL_OMIT == field_egprs__ul.get_selection() || field_egprs__ul.is_bound())
  || (OPTIONAL_OMIT == field_multiblock__dl__ass.get_selection() || field_multiblock__dl__ass.is_bound());
}
boolean IaRestOctLH::is_value() const
{
return field_presence.is_value()
  && (OPTIONAL_OMIT == field_egprs__ul.get_selection() || field_egprs__ul.is_value())
  && (OPTIONAL_OMIT == field_multiblock__dl__ass.get_selection() || field_multiblock__dl__ass.is_value());
}
int IaRestOctLH::size_of() const
{
  int ret_val = 1;
  if (field_egprs__ul.ispresent()) ret_val++;
  if (field_multiblock__dl__ass.ispresent()) ret_val++;
  return ret_val;
}

void IaRestOctLH::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ presence := ");
field_presence.log();
TTCN_Logger::log_event_str(", egprs_ul := ");
field_egprs__ul.log();
TTCN_Logger::log_event_str(", multiblock_dl_ass := ");
field_multiblock__dl__ass.log();
TTCN_Logger::log_event_str(" }");
}

void IaRestOctLH::set_implicit_omit()
{
if (presence().is_bound()) presence().set_implicit_omit();
if (!egprs__ul().is_bound()) egprs__ul() = OMIT_VALUE;
else egprs__ul().set_implicit_omit();
if (!multiblock__dl__ass().is_bound()) multiblock__dl__ass() = OMIT_VALUE;
else multiblock__dl__ass().set_implicit_omit();
}

void IaRestOctLH::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.IaRestOctLH has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) egprs__ul().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) multiblock__dl__ass().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "egprs_ul")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          egprs__ul().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "multiblock_dl_ass")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          multiblock__dl__ass().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctLH: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.IaRestOctLH");
  }
}

void IaRestOctLH::encode_text(Text_Buf& text_buf) const
{
field_presence.encode_text(text_buf);
field_egprs__ul.encode_text(text_buf);
field_multiblock__dl__ass.encode_text(text_buf);
}

void IaRestOctLH::decode_text(Text_Buf& text_buf)
{
field_presence.decode_text(text_buf);
field_egprs__ul.decode_text(text_buf);
field_multiblock__dl__ass.decode_text(text_buf);
}

void IaRestOctLH::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void IaRestOctLH::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int IaRestOctLH::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, IaRestOctLH_presence_descr_.raw->forceomit);
  decoded_field_length = field_presence.RAW_decode(IaRestOctLH_presence_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_presence ==  bs_2){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_egprs__ul = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, IaRestOctLH_egprs__ul_descr_.raw->forceomit);
  decoded_field_length = field_egprs__ul().RAW_decode(IaRestOctLH_egprs__ul_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_egprs__ul = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_egprs__ul=OMIT_VALUE;
  if (limit > 0 && field_presence ==  bs_3){
  if (force_omit != NULL && (*force_omit)(2)) {
    field_multiblock__dl__ass = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_2_force_omit(2, force_omit, IaRestOctLH_multiblock__dl__ass_descr_.raw->forceomit);
  decoded_field_length = field_multiblock__dl__ass().RAW_decode(IaRestOctLH_multiblock__dl__ass_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 1) {
  field_multiblock__dl__ass = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_multiblock__dl__ass=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int IaRestOctLH::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 3;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(3);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, IaRestOctLH_presence_descr_.raw);
  if (field_egprs__ul.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, IaRestOctLH_egprs__ul_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  if (field_multiblock__dl__ass.ispresent()) {
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, IaRestOctLH_multiblock__dl__ass_descr_.raw);
  }
  else myleaf.body.node.nodes[2] = NULL;
  encoded_length += field_presence.RAW_encode(IaRestOctLH_presence_descr_, *myleaf.body.node.nodes[0]);
  if (field_egprs__ul.ispresent()) {
  encoded_length += field_egprs__ul().RAW_encode(IaRestOctLH_egprs__ul_descr_, *myleaf.body.node.nodes[1]);
  }
  if (field_multiblock__dl__ass.ispresent()) {
  encoded_length += field_multiblock__dl__ass().RAW_encode(IaRestOctLH_multiblock__dl__ass_descr_, *myleaf.body.node.nodes[2]);
  }
  if (field_egprs__ul.ispresent() && (field_presence !=  bs_2)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_2.RAW_encode(IaRestOctLH_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_multiblock__dl__ass.ispresent() && (field_presence !=  bs_3)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_3.RAW_encode(IaRestOctLH_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct IaRestOctLH_template::single_value_struct {
BITSTRING_template field_presence;
EgprsUlAss_template field_egprs__ul;
OCTETSTRING_template field_multiblock__dl__ass;
};

void IaRestOctLH_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_presence = ANY_VALUE;
single_value->field_egprs__ul = ANY_OR_OMIT;
single_value->field_multiblock__dl__ass = ANY_OR_OMIT;
}
}
}

void IaRestOctLH_template::copy_value(const IaRestOctLH& other_value)
{
single_value = new single_value_struct;
if (other_value.presence().is_bound()) {
  single_value->field_presence = other_value.presence();
} else {
  single_value->field_presence.clean_up();
}
if (other_value.egprs__ul().is_bound()) {
  if (other_value.egprs__ul().ispresent()) single_value->field_egprs__ul = other_value.egprs__ul()();
  else single_value->field_egprs__ul = OMIT_VALUE;
} else {
  single_value->field_egprs__ul.clean_up();
}
if (other_value.multiblock__dl__ass().is_bound()) {
  if (other_value.multiblock__dl__ass().ispresent()) single_value->field_multiblock__dl__ass = other_value.multiblock__dl__ass()();
  else single_value->field_multiblock__dl__ass = OMIT_VALUE;
} else {
  single_value->field_multiblock__dl__ass.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void IaRestOctLH_template::copy_template(const IaRestOctLH_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.presence().get_selection()) {
single_value->field_presence = other_value.presence();
} else {
single_value->field_presence.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.egprs__ul().get_selection()) {
single_value->field_egprs__ul = other_value.egprs__ul();
} else {
single_value->field_egprs__ul.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.multiblock__dl__ass().get_selection()) {
single_value->field_multiblock__dl__ass = other_value.multiblock__dl__ass();
} else {
single_value->field_multiblock__dl__ass.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new IaRestOctLH_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new IaRestOctLH_template(*other_value.implication_.precondition);
implication_.implied_template = new IaRestOctLH_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctLH.");
break;
}
set_selection(other_value);
}

IaRestOctLH_template::IaRestOctLH_template()
{
}

IaRestOctLH_template::IaRestOctLH_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

IaRestOctLH_template::IaRestOctLH_template(const IaRestOctLH& other_value)
{
copy_value(other_value);
}

IaRestOctLH_template::IaRestOctLH_template(const OPTIONAL<IaRestOctLH>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctLH&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.IaRestOctLH from an unbound optional field.");
}
}

IaRestOctLH_template::IaRestOctLH_template(IaRestOctLH_template* p_precondition, IaRestOctLH_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

IaRestOctLH_template::IaRestOctLH_template(Dynamic_Match_Interface<IaRestOctLH>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<IaRestOctLH>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

IaRestOctLH_template::IaRestOctLH_template(const IaRestOctLH_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

IaRestOctLH_template::~IaRestOctLH_template()
{
clean_up();
}

IaRestOctLH_template& IaRestOctLH_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

IaRestOctLH_template& IaRestOctLH_template::operator=(const IaRestOctLH& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

IaRestOctLH_template& IaRestOctLH_template::operator=(const OPTIONAL<IaRestOctLH>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctLH&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.IaRestOctLH.");
}
return *this;
}

IaRestOctLH_template& IaRestOctLH_template::operator=(const IaRestOctLH_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean IaRestOctLH_template::match(const IaRestOctLH& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.presence().is_bound()) return FALSE;
if(!single_value->field_presence.match(other_value.presence(), legacy))return FALSE;
if(!other_value.egprs__ul().is_bound()) return FALSE;
if((other_value.egprs__ul().ispresent() ? !single_value->field_egprs__ul.match((const EgprsUlAss&)other_value.egprs__ul(), legacy) : !single_value->field_egprs__ul.match_omit(legacy)))return FALSE;
if(!other_value.multiblock__dl__ass().is_bound()) return FALSE;
if((other_value.multiblock__dl__ass().ispresent() ? !single_value->field_multiblock__dl__ass.match((const OCTETSTRING&)other_value.multiblock__dl__ass(), legacy) : !single_value->field_multiblock__dl__ass.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctLH.");
}
return FALSE;
}

boolean IaRestOctLH_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_presence.is_bound()
 || (single_value->field_egprs__ul.is_omit() || single_value->field_egprs__ul.is_bound())
 || (single_value->field_multiblock__dl__ass.is_omit() || single_value->field_multiblock__dl__ass.is_bound());
}

boolean IaRestOctLH_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_presence.is_value()
 && (single_value->field_egprs__ul.is_omit() || single_value->field_egprs__ul.is_value())
 && (single_value->field_multiblock__dl__ass.is_omit() || single_value->field_multiblock__dl__ass.is_value());
}

void IaRestOctLH_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

IaRestOctLH IaRestOctLH_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.IaRestOctLH.");
IaRestOctLH ret_val;
if (single_value->field_presence.is_bound()) {
ret_val.presence() = single_value->field_presence.valueof();
}
if (single_value->field_egprs__ul.is_omit()) ret_val.egprs__ul() = OMIT_VALUE;
else if (single_value->field_egprs__ul.is_bound()) {
ret_val.egprs__ul() = single_value->field_egprs__ul.valueof();
}
if (single_value->field_multiblock__dl__ass.is_omit()) ret_val.multiblock__dl__ass() = OMIT_VALUE;
else if (single_value->field_multiblock__dl__ass.is_bound()) {
ret_val.multiblock__dl__ass() = single_value->field_multiblock__dl__ass.valueof();
}
return ret_val;
}

void IaRestOctLH_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.IaRestOctLH.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new IaRestOctLH_template[list_length];
}

IaRestOctLH_template& IaRestOctLH_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.IaRestOctLH.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.IaRestOctLH.");
return value_list.list_value[list_index];
}

BITSTRING_template& IaRestOctLH_template::presence()
{
set_specific();
return single_value->field_presence;
}

const BITSTRING_template& IaRestOctLH_template::presence() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field presence of a non-specific template of type @GSM_RestOctets.IaRestOctLH.");
return single_value->field_presence;
}

EgprsUlAss_template& IaRestOctLH_template::egprs__ul()
{
set_specific();
return single_value->field_egprs__ul;
}

const EgprsUlAss_template& IaRestOctLH_template::egprs__ul() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field egprs_ul of a non-specific template of type @GSM_RestOctets.IaRestOctLH.");
return single_value->field_egprs__ul;
}

OCTETSTRING_template& IaRestOctLH_template::multiblock__dl__ass()
{
set_specific();
return single_value->field_multiblock__dl__ass;
}

const OCTETSTRING_template& IaRestOctLH_template::multiblock__dl__ass() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field multiblock_dl_ass of a non-specific template of type @GSM_RestOctets.IaRestOctLH.");
return single_value->field_multiblock__dl__ass;
}

int IaRestOctLH_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLH which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 1;
      if (single_value->field_egprs__ul.is_present()) ret_val++;
      if (single_value->field_multiblock__dl__ass.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLH containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLH containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLH containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLH containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLH containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLH containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLH containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctLH containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctLH.");
  }
  return 0;
}

void IaRestOctLH_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log();
TTCN_Logger::log_event_str(", egprs_ul := ");
single_value->field_egprs__ul.log();
TTCN_Logger::log_event_str(", multiblock_dl_ass := ");
single_value->field_multiblock__dl__ass.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void IaRestOctLH_template::log_match(const IaRestOctLH& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_presence.match(match_value.presence(), legacy)){
TTCN_Logger::log_logmatch_info(".presence");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.egprs__ul().ispresent()){
if(!single_value->field_egprs__ul.match(match_value.egprs__ul(), legacy)){
TTCN_Logger::log_logmatch_info(".egprs_ul");
single_value->field_egprs__ul.log_match(match_value.egprs__ul(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_egprs__ul.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".egprs_ul := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_egprs__ul.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.multiblock__dl__ass().ispresent()){
if(!single_value->field_multiblock__dl__ass.match(match_value.multiblock__dl__ass(), legacy)){
TTCN_Logger::log_logmatch_info(".multiblock_dl_ass");
single_value->field_multiblock__dl__ass.log_match(match_value.multiblock__dl__ass(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_multiblock__dl__ass.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".multiblock_dl_ass := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_multiblock__dl__ass.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::log_event_str(", egprs_ul := ");
if (match_value.egprs__ul().ispresent()) {
single_value->field_egprs__ul.log_match(match_value.egprs__ul(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_egprs__ul.log();
if (single_value->field_egprs__ul.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", multiblock_dl_ass := ");
if (match_value.multiblock__dl__ass().ispresent()) {
single_value->field_multiblock__dl__ass.log_match(match_value.multiblock__dl__ass(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_multiblock__dl__ass.log();
if (single_value->field_multiblock__dl__ass.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void IaRestOctLH_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (presence().is_bound()) presence().set_implicit_omit();
if (!egprs__ul().is_bound()) egprs__ul() = OMIT_VALUE;
else egprs__ul().set_implicit_omit();
if (!multiblock__dl__ass().is_bound()) multiblock__dl__ass() = OMIT_VALUE;
else multiblock__dl__ass().set_implicit_omit();
}

void IaRestOctLH_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_presence.encode_text(text_buf);
single_value->field_egprs__ul.encode_text(text_buf);
single_value->field_multiblock__dl__ass.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctLH.");
}
}

void IaRestOctLH_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_presence.decode_text(text_buf);
single_value->field_egprs__ul.decode_text(text_buf);
single_value->field_multiblock__dl__ass.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new IaRestOctLH_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.IaRestOctLH.");
}
}

void IaRestOctLH_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    IaRestOctLH_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.IaRestOctLH has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) egprs__ul().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) multiblock__dl__ass().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "egprs_ul")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          egprs__ul().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "multiblock_dl_ass")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          multiblock__dl__ass().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctLH: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    IaRestOctLH_template* precondition = new IaRestOctLH_template;
    precondition->set_param(*param.get_elem(0));
    IaRestOctLH_template* implied_template = new IaRestOctLH_template;
    implied_template->set_param(*param.get_elem(1));
    *this = IaRestOctLH_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.IaRestOctLH");
  }
  is_ifpresent = param.get_ifpresent();
}

void IaRestOctLH_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_presence.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctLH");
single_value->field_egprs__ul.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctLH");
single_value->field_multiblock__dl__ass.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctLH");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.IaRestOctLH");
}

boolean IaRestOctLH_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean IaRestOctLH_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

EgprsUlAss::EgprsUlAss()
{
}

EgprsUlAss::EgprsUlAss(const BITSTRING& par_ext__ra,
    const BITSTRING& par_ats__present,
    const OPTIONAL< RLCMAC__CSN1__Types::AccessTechnologiesRequestRepetition >& par_ats,
    const BITSTRING& par_presence,
    const OPTIONAL< EgprsUlAssignDyn >& par_dynamic,
    const OPTIONAL< EgprsUlAssignMultiblock >& par_multiblock)
  :   field_ext__ra(par_ext__ra),
  field_ats__present(par_ats__present),
  field_ats(par_ats),
  field_presence(par_presence),
  field_dynamic(par_dynamic),
  field_multiblock(par_multiblock)
{
}

EgprsUlAss::EgprsUlAss(const EgprsUlAss& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.EgprsUlAss.");
if (other_value.ext__ra().is_bound()) field_ext__ra = other_value.ext__ra();
else field_ext__ra.clean_up();
if (other_value.ats__present().is_bound()) field_ats__present = other_value.ats__present();
else field_ats__present.clean_up();
if (other_value.ats().is_bound()) field_ats = other_value.ats();
else field_ats.clean_up();
if (other_value.presence().is_bound()) field_presence = other_value.presence();
else field_presence.clean_up();
if (other_value.dynamic().is_bound()) field_dynamic = other_value.dynamic();
else field_dynamic.clean_up();
if (other_value.multiblock().is_bound()) field_multiblock = other_value.multiblock();
else field_multiblock.clean_up();
}

void EgprsUlAss::clean_up()
{
field_ext__ra.clean_up();
field_ats__present.clean_up();
field_ats.clean_up();
field_presence.clean_up();
field_dynamic.clean_up();
field_multiblock.clean_up();
}

const TTCN_Typedescriptor_t* EgprsUlAss::get_descriptor() const { return &EgprsUlAss_descr_; }
EgprsUlAss& EgprsUlAss::operator=(const EgprsUlAss& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.EgprsUlAss.");
  if (other_value.ext__ra().is_bound()) field_ext__ra = other_value.ext__ra();
  else field_ext__ra.clean_up();
  if (other_value.ats__present().is_bound()) field_ats__present = other_value.ats__present();
  else field_ats__present.clean_up();
  if (other_value.ats().is_bound()) field_ats = other_value.ats();
  else field_ats.clean_up();
  if (other_value.presence().is_bound()) field_presence = other_value.presence();
  else field_presence.clean_up();
  if (other_value.dynamic().is_bound()) field_dynamic = other_value.dynamic();
  else field_dynamic.clean_up();
  if (other_value.multiblock().is_bound()) field_multiblock = other_value.multiblock();
  else field_multiblock.clean_up();
}
return *this;
}

boolean EgprsUlAss::operator==(const EgprsUlAss& other_value) const
{
return field_ext__ra==other_value.field_ext__ra
  && field_ats__present==other_value.field_ats__present
  && field_ats==other_value.field_ats
  && field_presence==other_value.field_presence
  && field_dynamic==other_value.field_dynamic
  && field_multiblock==other_value.field_multiblock;
}

boolean EgprsUlAss::is_bound() const
{
return (field_ext__ra.is_bound())
  || (field_ats__present.is_bound())
  || (OPTIONAL_OMIT == field_ats.get_selection() || field_ats.is_bound())
  || (field_presence.is_bound())
  || (OPTIONAL_OMIT == field_dynamic.get_selection() || field_dynamic.is_bound())
  || (OPTIONAL_OMIT == field_multiblock.get_selection() || field_multiblock.is_bound());
}
boolean EgprsUlAss::is_value() const
{
return field_ext__ra.is_value()
  && field_ats__present.is_value()
  && (OPTIONAL_OMIT == field_ats.get_selection() || field_ats.is_value())
  && field_presence.is_value()
  && (OPTIONAL_OMIT == field_dynamic.get_selection() || field_dynamic.is_value())
  && (OPTIONAL_OMIT == field_multiblock.get_selection() || field_multiblock.is_value());
}
int EgprsUlAss::size_of() const
{
  int ret_val = 3;
  if (field_ats.ispresent()) ret_val++;
  if (field_dynamic.ispresent()) ret_val++;
  if (field_multiblock.ispresent()) ret_val++;
  return ret_val;
}

void EgprsUlAss::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ ext_ra := ");
field_ext__ra.log();
TTCN_Logger::log_event_str(", ats_present := ");
field_ats__present.log();
TTCN_Logger::log_event_str(", ats := ");
field_ats.log();
TTCN_Logger::log_event_str(", presence := ");
field_presence.log();
TTCN_Logger::log_event_str(", dynamic := ");
field_dynamic.log();
TTCN_Logger::log_event_str(", multiblock := ");
field_multiblock.log();
TTCN_Logger::log_event_str(" }");
}

void EgprsUlAss::set_implicit_omit()
{
if (ext__ra().is_bound()) ext__ra().set_implicit_omit();
if (ats__present().is_bound()) ats__present().set_implicit_omit();
if (!ats().is_bound()) ats() = OMIT_VALUE;
else ats().set_implicit_omit();
if (presence().is_bound()) presence().set_implicit_omit();
if (!dynamic().is_bound()) dynamic() = OMIT_VALUE;
else dynamic().set_implicit_omit();
if (!multiblock().is_bound()) multiblock() = OMIT_VALUE;
else multiblock().set_implicit_omit();
}

void EgprsUlAss::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (6<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.EgprsUlAss has 6 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) ext__ra().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) ats__present().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) ats().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) dynamic().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) multiblock().set_param(*param.get_elem(5));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ext_ra")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ext__ra().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ats_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ats__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ats")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ats().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "dynamic")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          dynamic().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "multiblock")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          multiblock().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.EgprsUlAss: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.EgprsUlAss");
  }
}

void EgprsUlAss::encode_text(Text_Buf& text_buf) const
{
field_ext__ra.encode_text(text_buf);
field_ats__present.encode_text(text_buf);
field_ats.encode_text(text_buf);
field_presence.encode_text(text_buf);
field_dynamic.encode_text(text_buf);
field_multiblock.encode_text(text_buf);
}

void EgprsUlAss::decode_text(Text_Buf& text_buf)
{
field_ext__ra.decode_text(text_buf);
field_ats__present.decode_text(text_buf);
field_ats.decode_text(text_buf);
field_presence.decode_text(text_buf);
field_dynamic.decode_text(text_buf);
field_multiblock.decode_text(text_buf);
}

void EgprsUlAss::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void EgprsUlAss::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int EgprsUlAss::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, EgprsUlAss_ext__ra_descr_.raw->forceomit);
  decoded_field_length = field_ext__ra.RAW_decode(EgprsUlAss_ext__ra_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_1_force_omit(1, force_omit, EgprsUlAss_ats__present_descr_.raw->forceomit);
  decoded_field_length = field_ats__present.RAW_decode(EgprsUlAss_ats__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_ats__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(2)) {
    field_ats = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_2_force_omit(2, force_omit, EgprsUlAss_ats_descr_.raw->forceomit);
  decoded_field_length = field_ats().RAW_decode(EgprsUlAss_ats_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 1) {
  field_ats = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_ats=OMIT_VALUE;
  RAW_Force_Omit field_3_force_omit(3, force_omit, EgprsUlAss_presence_descr_.raw->forceomit);
  decoded_field_length = field_presence.RAW_decode(EgprsUlAss_presence_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_3_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_presence ==  bs_0){
  if (force_omit != NULL && (*force_omit)(4)) {
    field_dynamic = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_4_force_omit(4, force_omit, EgprsUlAss_dynamic_descr_.raw->forceomit);
  decoded_field_length = field_dynamic().RAW_decode(EgprsUlAss_dynamic_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_4_force_omit);
  if (decoded_field_length < 1) {
  field_dynamic = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_dynamic=OMIT_VALUE;
  if (limit > 0 && field_presence ==  bs_1){
  if (force_omit != NULL && (*force_omit)(5)) {
    field_multiblock = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_5_force_omit(5, force_omit, EgprsUlAss_multiblock_descr_.raw->forceomit);
  decoded_field_length = field_multiblock().RAW_decode(EgprsUlAss_multiblock_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_5_force_omit);
  if (decoded_field_length < 1) {
  field_multiblock = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_multiblock=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int EgprsUlAss::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 6;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(6);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, EgprsUlAss_ext__ra_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, EgprsUlAss_ats__present_descr_.raw);
  if (field_ats.ispresent()) {
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, EgprsUlAss_ats_descr_.raw);
  }
  else myleaf.body.node.nodes[2] = NULL;
  myleaf.body.node.nodes[3] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 3, EgprsUlAss_presence_descr_.raw);
  if (field_dynamic.ispresent()) {
  myleaf.body.node.nodes[4] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 4, EgprsUlAss_dynamic_descr_.raw);
  }
  else myleaf.body.node.nodes[4] = NULL;
  if (field_multiblock.ispresent()) {
  myleaf.body.node.nodes[5] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 5, EgprsUlAss_multiblock_descr_.raw);
  }
  else myleaf.body.node.nodes[5] = NULL;
  encoded_length += field_ext__ra.RAW_encode(EgprsUlAss_ext__ra_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_ats__present.RAW_encode(EgprsUlAss_ats__present_descr_, *myleaf.body.node.nodes[1]);
  if (field_ats.ispresent()) {
  encoded_length += field_ats().RAW_encode(EgprsUlAss_ats_descr_, *myleaf.body.node.nodes[2]);
  }
  encoded_length += field_presence.RAW_encode(EgprsUlAss_presence_descr_, *myleaf.body.node.nodes[3]);
  if (field_dynamic.ispresent()) {
  encoded_length += field_dynamic().RAW_encode(EgprsUlAss_dynamic_descr_, *myleaf.body.node.nodes[4]);
  }
  if (field_multiblock.ispresent()) {
  encoded_length += field_multiblock().RAW_encode(EgprsUlAss_multiblock_descr_, *myleaf.body.node.nodes[5]);
  }
  if (field_ats.ispresent() && (field_ats__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={1};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAss_ats__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_dynamic.ispresent() && (field_presence !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={3};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAss_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_multiblock.ispresent() && (field_presence !=  bs_1)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={3};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_1.RAW_encode(EgprsUlAss_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct EgprsUlAss_template::single_value_struct {
BITSTRING_template field_ext__ra;
BITSTRING_template field_ats__present;
RLCMAC__CSN1__Types::AccessTechnologiesRequestRepetition_template field_ats;
BITSTRING_template field_presence;
EgprsUlAssignDyn_template field_dynamic;
EgprsUlAssignMultiblock_template field_multiblock;
};

void EgprsUlAss_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_ext__ra = ANY_VALUE;
single_value->field_ats__present = ANY_VALUE;
single_value->field_ats = ANY_OR_OMIT;
single_value->field_presence = ANY_VALUE;
single_value->field_dynamic = ANY_OR_OMIT;
single_value->field_multiblock = ANY_OR_OMIT;
}
}
}

void EgprsUlAss_template::copy_value(const EgprsUlAss& other_value)
{
single_value = new single_value_struct;
if (other_value.ext__ra().is_bound()) {
  single_value->field_ext__ra = other_value.ext__ra();
} else {
  single_value->field_ext__ra.clean_up();
}
if (other_value.ats__present().is_bound()) {
  single_value->field_ats__present = other_value.ats__present();
} else {
  single_value->field_ats__present.clean_up();
}
if (other_value.ats().is_bound()) {
  if (other_value.ats().ispresent()) single_value->field_ats = other_value.ats()();
  else single_value->field_ats = OMIT_VALUE;
} else {
  single_value->field_ats.clean_up();
}
if (other_value.presence().is_bound()) {
  single_value->field_presence = other_value.presence();
} else {
  single_value->field_presence.clean_up();
}
if (other_value.dynamic().is_bound()) {
  if (other_value.dynamic().ispresent()) single_value->field_dynamic = other_value.dynamic()();
  else single_value->field_dynamic = OMIT_VALUE;
} else {
  single_value->field_dynamic.clean_up();
}
if (other_value.multiblock().is_bound()) {
  if (other_value.multiblock().ispresent()) single_value->field_multiblock = other_value.multiblock()();
  else single_value->field_multiblock = OMIT_VALUE;
} else {
  single_value->field_multiblock.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void EgprsUlAss_template::copy_template(const EgprsUlAss_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.ext__ra().get_selection()) {
single_value->field_ext__ra = other_value.ext__ra();
} else {
single_value->field_ext__ra.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ats__present().get_selection()) {
single_value->field_ats__present = other_value.ats__present();
} else {
single_value->field_ats__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ats().get_selection()) {
single_value->field_ats = other_value.ats();
} else {
single_value->field_ats.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.presence().get_selection()) {
single_value->field_presence = other_value.presence();
} else {
single_value->field_presence.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.dynamic().get_selection()) {
single_value->field_dynamic = other_value.dynamic();
} else {
single_value->field_dynamic.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.multiblock().get_selection()) {
single_value->field_multiblock = other_value.multiblock();
} else {
single_value->field_multiblock.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new EgprsUlAss_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new EgprsUlAss_template(*other_value.implication_.precondition);
implication_.implied_template = new EgprsUlAss_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAss.");
break;
}
set_selection(other_value);
}

EgprsUlAss_template::EgprsUlAss_template()
{
}

EgprsUlAss_template::EgprsUlAss_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

EgprsUlAss_template::EgprsUlAss_template(const EgprsUlAss& other_value)
{
copy_value(other_value);
}

EgprsUlAss_template::EgprsUlAss_template(const OPTIONAL<EgprsUlAss>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const EgprsUlAss&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.EgprsUlAss from an unbound optional field.");
}
}

EgprsUlAss_template::EgprsUlAss_template(EgprsUlAss_template* p_precondition, EgprsUlAss_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

EgprsUlAss_template::EgprsUlAss_template(Dynamic_Match_Interface<EgprsUlAss>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<EgprsUlAss>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

EgprsUlAss_template::EgprsUlAss_template(const EgprsUlAss_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

EgprsUlAss_template::~EgprsUlAss_template()
{
clean_up();
}

EgprsUlAss_template& EgprsUlAss_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

EgprsUlAss_template& EgprsUlAss_template::operator=(const EgprsUlAss& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

EgprsUlAss_template& EgprsUlAss_template::operator=(const OPTIONAL<EgprsUlAss>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const EgprsUlAss&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.EgprsUlAss.");
}
return *this;
}

EgprsUlAss_template& EgprsUlAss_template::operator=(const EgprsUlAss_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean EgprsUlAss_template::match(const EgprsUlAss& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.ext__ra().is_bound()) return FALSE;
if(!single_value->field_ext__ra.match(other_value.ext__ra(), legacy))return FALSE;
if(!other_value.ats__present().is_bound()) return FALSE;
if(!single_value->field_ats__present.match(other_value.ats__present(), legacy))return FALSE;
if(!other_value.ats().is_bound()) return FALSE;
if((other_value.ats().ispresent() ? !single_value->field_ats.match((const RLCMAC__CSN1__Types::AccessTechnologiesRequestRepetition&)other_value.ats(), legacy) : !single_value->field_ats.match_omit(legacy)))return FALSE;
if(!other_value.presence().is_bound()) return FALSE;
if(!single_value->field_presence.match(other_value.presence(), legacy))return FALSE;
if(!other_value.dynamic().is_bound()) return FALSE;
if((other_value.dynamic().ispresent() ? !single_value->field_dynamic.match((const EgprsUlAssignDyn&)other_value.dynamic(), legacy) : !single_value->field_dynamic.match_omit(legacy)))return FALSE;
if(!other_value.multiblock().is_bound()) return FALSE;
if((other_value.multiblock().ispresent() ? !single_value->field_multiblock.match((const EgprsUlAssignMultiblock&)other_value.multiblock(), legacy) : !single_value->field_multiblock.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAss.");
}
return FALSE;
}

boolean EgprsUlAss_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_ext__ra.is_bound()
 || single_value->field_ats__present.is_bound()
 || (single_value->field_ats.is_omit() || single_value->field_ats.is_bound())
 || single_value->field_presence.is_bound()
 || (single_value->field_dynamic.is_omit() || single_value->field_dynamic.is_bound())
 || (single_value->field_multiblock.is_omit() || single_value->field_multiblock.is_bound());
}

boolean EgprsUlAss_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_ext__ra.is_value()
 && single_value->field_ats__present.is_value()
 && (single_value->field_ats.is_omit() || single_value->field_ats.is_value())
 && single_value->field_presence.is_value()
 && (single_value->field_dynamic.is_omit() || single_value->field_dynamic.is_value())
 && (single_value->field_multiblock.is_omit() || single_value->field_multiblock.is_value());
}

void EgprsUlAss_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

EgprsUlAss EgprsUlAss_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.EgprsUlAss.");
EgprsUlAss ret_val;
if (single_value->field_ext__ra.is_bound()) {
ret_val.ext__ra() = single_value->field_ext__ra.valueof();
}
if (single_value->field_ats__present.is_bound()) {
ret_val.ats__present() = single_value->field_ats__present.valueof();
}
if (single_value->field_ats.is_omit()) ret_val.ats() = OMIT_VALUE;
else if (single_value->field_ats.is_bound()) {
ret_val.ats() = single_value->field_ats.valueof();
}
if (single_value->field_presence.is_bound()) {
ret_val.presence() = single_value->field_presence.valueof();
}
if (single_value->field_dynamic.is_omit()) ret_val.dynamic() = OMIT_VALUE;
else if (single_value->field_dynamic.is_bound()) {
ret_val.dynamic() = single_value->field_dynamic.valueof();
}
if (single_value->field_multiblock.is_omit()) ret_val.multiblock() = OMIT_VALUE;
else if (single_value->field_multiblock.is_bound()) {
ret_val.multiblock() = single_value->field_multiblock.valueof();
}
return ret_val;
}

void EgprsUlAss_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.EgprsUlAss.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new EgprsUlAss_template[list_length];
}

EgprsUlAss_template& EgprsUlAss_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.EgprsUlAss.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.EgprsUlAss.");
return value_list.list_value[list_index];
}

BITSTRING_template& EgprsUlAss_template::ext__ra()
{
set_specific();
return single_value->field_ext__ra;
}

const BITSTRING_template& EgprsUlAss_template::ext__ra() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ext_ra of a non-specific template of type @GSM_RestOctets.EgprsUlAss.");
return single_value->field_ext__ra;
}

BITSTRING_template& EgprsUlAss_template::ats__present()
{
set_specific();
return single_value->field_ats__present;
}

const BITSTRING_template& EgprsUlAss_template::ats__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ats_present of a non-specific template of type @GSM_RestOctets.EgprsUlAss.");
return single_value->field_ats__present;
}

RLCMAC__CSN1__Types::AccessTechnologiesRequestRepetition_template& EgprsUlAss_template::ats()
{
set_specific();
return single_value->field_ats;
}

const RLCMAC__CSN1__Types::AccessTechnologiesRequestRepetition_template& EgprsUlAss_template::ats() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ats of a non-specific template of type @GSM_RestOctets.EgprsUlAss.");
return single_value->field_ats;
}

BITSTRING_template& EgprsUlAss_template::presence()
{
set_specific();
return single_value->field_presence;
}

const BITSTRING_template& EgprsUlAss_template::presence() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field presence of a non-specific template of type @GSM_RestOctets.EgprsUlAss.");
return single_value->field_presence;
}

EgprsUlAssignDyn_template& EgprsUlAss_template::dynamic()
{
set_specific();
return single_value->field_dynamic;
}

const EgprsUlAssignDyn_template& EgprsUlAss_template::dynamic() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field dynamic of a non-specific template of type @GSM_RestOctets.EgprsUlAss.");
return single_value->field_dynamic;
}

EgprsUlAssignMultiblock_template& EgprsUlAss_template::multiblock()
{
set_specific();
return single_value->field_multiblock;
}

const EgprsUlAssignMultiblock_template& EgprsUlAss_template::multiblock() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field multiblock of a non-specific template of type @GSM_RestOctets.EgprsUlAss.");
return single_value->field_multiblock;
}

int EgprsUlAss_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAss which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 3;
      if (single_value->field_ats.is_present()) ret_val++;
      if (single_value->field_dynamic.is_present()) ret_val++;
      if (single_value->field_multiblock.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAss containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAss containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAss containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAss containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAss containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAss containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAss containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAss containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAss.");
  }
  return 0;
}

void EgprsUlAss_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ ext_ra := ");
single_value->field_ext__ra.log();
TTCN_Logger::log_event_str(", ats_present := ");
single_value->field_ats__present.log();
TTCN_Logger::log_event_str(", ats := ");
single_value->field_ats.log();
TTCN_Logger::log_event_str(", presence := ");
single_value->field_presence.log();
TTCN_Logger::log_event_str(", dynamic := ");
single_value->field_dynamic.log();
TTCN_Logger::log_event_str(", multiblock := ");
single_value->field_multiblock.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void EgprsUlAss_template::log_match(const EgprsUlAss& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_ext__ra.match(match_value.ext__ra(), legacy)){
TTCN_Logger::log_logmatch_info(".ext_ra");
single_value->field_ext__ra.log_match(match_value.ext__ra(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_ats__present.match(match_value.ats__present(), legacy)){
TTCN_Logger::log_logmatch_info(".ats_present");
single_value->field_ats__present.log_match(match_value.ats__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.ats().ispresent()){
if(!single_value->field_ats.match(match_value.ats(), legacy)){
TTCN_Logger::log_logmatch_info(".ats");
single_value->field_ats.log_match(match_value.ats(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_ats.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".ats := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_ats.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_presence.match(match_value.presence(), legacy)){
TTCN_Logger::log_logmatch_info(".presence");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.dynamic().ispresent()){
if(!single_value->field_dynamic.match(match_value.dynamic(), legacy)){
TTCN_Logger::log_logmatch_info(".dynamic");
single_value->field_dynamic.log_match(match_value.dynamic(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_dynamic.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".dynamic := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_dynamic.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.multiblock().ispresent()){
if(!single_value->field_multiblock.match(match_value.multiblock(), legacy)){
TTCN_Logger::log_logmatch_info(".multiblock");
single_value->field_multiblock.log_match(match_value.multiblock(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_multiblock.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".multiblock := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_multiblock.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ ext_ra := ");
single_value->field_ext__ra.log_match(match_value.ext__ra(), legacy);
TTCN_Logger::log_event_str(", ats_present := ");
single_value->field_ats__present.log_match(match_value.ats__present(), legacy);
TTCN_Logger::log_event_str(", ats := ");
if (match_value.ats().ispresent()) {
single_value->field_ats.log_match(match_value.ats(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_ats.log();
if (single_value->field_ats.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", presence := ");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::log_event_str(", dynamic := ");
if (match_value.dynamic().ispresent()) {
single_value->field_dynamic.log_match(match_value.dynamic(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_dynamic.log();
if (single_value->field_dynamic.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", multiblock := ");
if (match_value.multiblock().ispresent()) {
single_value->field_multiblock.log_match(match_value.multiblock(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_multiblock.log();
if (single_value->field_multiblock.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void EgprsUlAss_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (ext__ra().is_bound()) ext__ra().set_implicit_omit();
if (ats__present().is_bound()) ats__present().set_implicit_omit();
if (!ats().is_bound()) ats() = OMIT_VALUE;
else ats().set_implicit_omit();
if (presence().is_bound()) presence().set_implicit_omit();
if (!dynamic().is_bound()) dynamic() = OMIT_VALUE;
else dynamic().set_implicit_omit();
if (!multiblock().is_bound()) multiblock() = OMIT_VALUE;
else multiblock().set_implicit_omit();
}

void EgprsUlAss_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_ext__ra.encode_text(text_buf);
single_value->field_ats__present.encode_text(text_buf);
single_value->field_ats.encode_text(text_buf);
single_value->field_presence.encode_text(text_buf);
single_value->field_dynamic.encode_text(text_buf);
single_value->field_multiblock.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAss.");
}
}

void EgprsUlAss_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_ext__ra.decode_text(text_buf);
single_value->field_ats__present.decode_text(text_buf);
single_value->field_ats.decode_text(text_buf);
single_value->field_presence.decode_text(text_buf);
single_value->field_dynamic.decode_text(text_buf);
single_value->field_multiblock.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new EgprsUlAss_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.EgprsUlAss.");
}
}

void EgprsUlAss_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    EgprsUlAss_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (6<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.EgprsUlAss has 6 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) ext__ra().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) ats__present().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) ats().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) dynamic().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) multiblock().set_param(*param.get_elem(5));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ext_ra")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ext__ra().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ats_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ats__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ats")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ats().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "dynamic")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          dynamic().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "multiblock")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          multiblock().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.EgprsUlAss: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    EgprsUlAss_template* precondition = new EgprsUlAss_template;
    precondition->set_param(*param.get_elem(0));
    EgprsUlAss_template* implied_template = new EgprsUlAss_template;
    implied_template->set_param(*param.get_elem(1));
    *this = EgprsUlAss_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.EgprsUlAss");
  }
  is_ifpresent = param.get_ifpresent();
}

void EgprsUlAss_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_ext__ra.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAss");
single_value->field_ats__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAss");
single_value->field_ats.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAss");
single_value->field_presence.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAss");
single_value->field_dynamic.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAss");
single_value->field_multiblock.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAss");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.EgprsUlAss");
}

boolean EgprsUlAss_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean EgprsUlAss_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

EgprsUlAssignDyn::EgprsUlAssignDyn()
{
}

EgprsUlAssignDyn::EgprsUlAssignDyn(const INTEGER& par_tfi__assignment,
    const BITSTRING& par_polling,
    const BITSTRING& par_spare,
    const INTEGER& par_usf,
    const BITSTRING& par_usf__granularity,
    const BITSTRING& par_p0__present,
    const OPTIONAL< INTEGER >& par_p0,
    const OPTIONAL< BITSTRING >& par_pr__mode,
    const RLCMAC__CSN1__Types::EgprsChCodingCommand& par_egprs__ch__coding__cmd,
    const BITSTRING& par_tlli__block__chan__coding,
    const BITSTRING& par_bep__period2__present,
    const OPTIONAL< BITSTRING >& par_bep__period2,
    const BITSTRING& par_resegment,
    const RLCMAC__CSN1__Types::EgprsWindowSize& par_egprs__window__size,
    const BITSTRING& par_alpha__present,
    const OPTIONAL< INTEGER >& par_alpha,
    const INTEGER& par_gamma,
    const BITSTRING& par_ta__index__present,
    const OPTIONAL< INTEGER >& par_ta__index,
    const BITSTRING& par_tbf__starting__time__present,
    const OPTIONAL< TbfStartingTime >& par_tbf__starting__time)
  :   field_tfi__assignment(par_tfi__assignment),
  field_polling(par_polling),
  field_spare(par_spare),
  field_usf(par_usf),
  field_usf__granularity(par_usf__granularity),
  field_p0__present(par_p0__present),
  field_p0(par_p0),
  field_pr__mode(par_pr__mode),
  field_egprs__ch__coding__cmd(par_egprs__ch__coding__cmd),
  field_tlli__block__chan__coding(par_tlli__block__chan__coding),
  field_bep__period2__present(par_bep__period2__present),
  field_bep__period2(par_bep__period2),
  field_resegment(par_resegment),
  field_egprs__window__size(par_egprs__window__size),
  field_alpha__present(par_alpha__present),
  field_alpha(par_alpha),
  field_gamma(par_gamma),
  field_ta__index__present(par_ta__index__present),
  field_ta__index(par_ta__index),
  field_tbf__starting__time__present(par_tbf__starting__time__present),
  field_tbf__starting__time(par_tbf__starting__time)
{
}

EgprsUlAssignDyn::EgprsUlAssignDyn(const EgprsUlAssignDyn& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.EgprsUlAssignDyn.");
if (other_value.tfi__assignment().is_bound()) field_tfi__assignment = other_value.tfi__assignment();
else field_tfi__assignment.clean_up();
if (other_value.polling().is_bound()) field_polling = other_value.polling();
else field_polling.clean_up();
if (other_value.spare().is_bound()) field_spare = other_value.spare();
else field_spare.clean_up();
if (other_value.usf().is_bound()) field_usf = other_value.usf();
else field_usf.clean_up();
if (other_value.usf__granularity().is_bound()) field_usf__granularity = other_value.usf__granularity();
else field_usf__granularity.clean_up();
if (other_value.p0__present().is_bound()) field_p0__present = other_value.p0__present();
else field_p0__present.clean_up();
if (other_value.p0().is_bound()) field_p0 = other_value.p0();
else field_p0.clean_up();
if (other_value.pr__mode().is_bound()) field_pr__mode = other_value.pr__mode();
else field_pr__mode.clean_up();
if (other_value.egprs__ch__coding__cmd().is_bound()) field_egprs__ch__coding__cmd = other_value.egprs__ch__coding__cmd();
else field_egprs__ch__coding__cmd.clean_up();
if (other_value.tlli__block__chan__coding().is_bound()) field_tlli__block__chan__coding = other_value.tlli__block__chan__coding();
else field_tlli__block__chan__coding.clean_up();
if (other_value.bep__period2__present().is_bound()) field_bep__period2__present = other_value.bep__period2__present();
else field_bep__period2__present.clean_up();
if (other_value.bep__period2().is_bound()) field_bep__period2 = other_value.bep__period2();
else field_bep__period2.clean_up();
if (other_value.resegment().is_bound()) field_resegment = other_value.resegment();
else field_resegment.clean_up();
if (other_value.egprs__window__size().is_bound()) field_egprs__window__size = other_value.egprs__window__size();
else field_egprs__window__size.clean_up();
if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
else field_alpha__present.clean_up();
if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
else field_alpha.clean_up();
if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
else field_gamma.clean_up();
if (other_value.ta__index__present().is_bound()) field_ta__index__present = other_value.ta__index__present();
else field_ta__index__present.clean_up();
if (other_value.ta__index().is_bound()) field_ta__index = other_value.ta__index();
else field_ta__index.clean_up();
if (other_value.tbf__starting__time__present().is_bound()) field_tbf__starting__time__present = other_value.tbf__starting__time__present();
else field_tbf__starting__time__present.clean_up();
if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
else field_tbf__starting__time.clean_up();
}

void EgprsUlAssignDyn::clean_up()
{
field_tfi__assignment.clean_up();
field_polling.clean_up();
field_spare.clean_up();
field_usf.clean_up();
field_usf__granularity.clean_up();
field_p0__present.clean_up();
field_p0.clean_up();
field_pr__mode.clean_up();
field_egprs__ch__coding__cmd.clean_up();
field_tlli__block__chan__coding.clean_up();
field_bep__period2__present.clean_up();
field_bep__period2.clean_up();
field_resegment.clean_up();
field_egprs__window__size.clean_up();
field_alpha__present.clean_up();
field_alpha.clean_up();
field_gamma.clean_up();
field_ta__index__present.clean_up();
field_ta__index.clean_up();
field_tbf__starting__time__present.clean_up();
field_tbf__starting__time.clean_up();
}

const TTCN_Typedescriptor_t* EgprsUlAssignDyn::get_descriptor() const { return &EgprsUlAssignDyn_descr_; }
EgprsUlAssignDyn& EgprsUlAssignDyn::operator=(const EgprsUlAssignDyn& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.EgprsUlAssignDyn.");
  if (other_value.tfi__assignment().is_bound()) field_tfi__assignment = other_value.tfi__assignment();
  else field_tfi__assignment.clean_up();
  if (other_value.polling().is_bound()) field_polling = other_value.polling();
  else field_polling.clean_up();
  if (other_value.spare().is_bound()) field_spare = other_value.spare();
  else field_spare.clean_up();
  if (other_value.usf().is_bound()) field_usf = other_value.usf();
  else field_usf.clean_up();
  if (other_value.usf__granularity().is_bound()) field_usf__granularity = other_value.usf__granularity();
  else field_usf__granularity.clean_up();
  if (other_value.p0__present().is_bound()) field_p0__present = other_value.p0__present();
  else field_p0__present.clean_up();
  if (other_value.p0().is_bound()) field_p0 = other_value.p0();
  else field_p0.clean_up();
  if (other_value.pr__mode().is_bound()) field_pr__mode = other_value.pr__mode();
  else field_pr__mode.clean_up();
  if (other_value.egprs__ch__coding__cmd().is_bound()) field_egprs__ch__coding__cmd = other_value.egprs__ch__coding__cmd();
  else field_egprs__ch__coding__cmd.clean_up();
  if (other_value.tlli__block__chan__coding().is_bound()) field_tlli__block__chan__coding = other_value.tlli__block__chan__coding();
  else field_tlli__block__chan__coding.clean_up();
  if (other_value.bep__period2__present().is_bound()) field_bep__period2__present = other_value.bep__period2__present();
  else field_bep__period2__present.clean_up();
  if (other_value.bep__period2().is_bound()) field_bep__period2 = other_value.bep__period2();
  else field_bep__period2.clean_up();
  if (other_value.resegment().is_bound()) field_resegment = other_value.resegment();
  else field_resegment.clean_up();
  if (other_value.egprs__window__size().is_bound()) field_egprs__window__size = other_value.egprs__window__size();
  else field_egprs__window__size.clean_up();
  if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
  else field_alpha__present.clean_up();
  if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
  else field_alpha.clean_up();
  if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
  else field_gamma.clean_up();
  if (other_value.ta__index__present().is_bound()) field_ta__index__present = other_value.ta__index__present();
  else field_ta__index__present.clean_up();
  if (other_value.ta__index().is_bound()) field_ta__index = other_value.ta__index();
  else field_ta__index.clean_up();
  if (other_value.tbf__starting__time__present().is_bound()) field_tbf__starting__time__present = other_value.tbf__starting__time__present();
  else field_tbf__starting__time__present.clean_up();
  if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
  else field_tbf__starting__time.clean_up();
}
return *this;
}

boolean EgprsUlAssignDyn::operator==(const EgprsUlAssignDyn& other_value) const
{
return field_tfi__assignment==other_value.field_tfi__assignment
  && field_polling==other_value.field_polling
  && field_spare==other_value.field_spare
  && field_usf==other_value.field_usf
  && field_usf__granularity==other_value.field_usf__granularity
  && field_p0__present==other_value.field_p0__present
  && field_p0==other_value.field_p0
  && field_pr__mode==other_value.field_pr__mode
  && field_egprs__ch__coding__cmd==other_value.field_egprs__ch__coding__cmd
  && field_tlli__block__chan__coding==other_value.field_tlli__block__chan__coding
  && field_bep__period2__present==other_value.field_bep__period2__present
  && field_bep__period2==other_value.field_bep__period2
  && field_resegment==other_value.field_resegment
  && field_egprs__window__size==other_value.field_egprs__window__size
  && field_alpha__present==other_value.field_alpha__present
  && field_alpha==other_value.field_alpha
  && field_gamma==other_value.field_gamma
  && field_ta__index__present==other_value.field_ta__index__present
  && field_ta__index==other_value.field_ta__index
  && field_tbf__starting__time__present==other_value.field_tbf__starting__time__present
  && field_tbf__starting__time==other_value.field_tbf__starting__time;
}

boolean EgprsUlAssignDyn::is_bound() const
{
return (field_tfi__assignment.is_bound())
  || (field_polling.is_bound())
  || (field_spare.is_bound())
  || (field_usf.is_bound())
  || (field_usf__granularity.is_bound())
  || (field_p0__present.is_bound())
  || (OPTIONAL_OMIT == field_p0.get_selection() || field_p0.is_bound())
  || (OPTIONAL_OMIT == field_pr__mode.get_selection() || field_pr__mode.is_bound())
  || (field_egprs__ch__coding__cmd.is_bound())
  || (field_tlli__block__chan__coding.is_bound())
  || (field_bep__period2__present.is_bound())
  || (OPTIONAL_OMIT == field_bep__period2.get_selection() || field_bep__period2.is_bound())
  || (field_resegment.is_bound())
  || (field_egprs__window__size.is_bound())
  || (field_alpha__present.is_bound())
  || (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_bound())
  || (field_gamma.is_bound())
  || (field_ta__index__present.is_bound())
  || (OPTIONAL_OMIT == field_ta__index.get_selection() || field_ta__index.is_bound())
  || (field_tbf__starting__time__present.is_bound())
  || (OPTIONAL_OMIT == field_tbf__starting__time.get_selection() || field_tbf__starting__time.is_bound());
}
boolean EgprsUlAssignDyn::is_value() const
{
return field_tfi__assignment.is_value()
  && field_polling.is_value()
  && field_spare.is_value()
  && field_usf.is_value()
  && field_usf__granularity.is_value()
  && field_p0__present.is_value()
  && (OPTIONAL_OMIT == field_p0.get_selection() || field_p0.is_value())
  && (OPTIONAL_OMIT == field_pr__mode.get_selection() || field_pr__mode.is_value())
  && field_egprs__ch__coding__cmd.is_value()
  && field_tlli__block__chan__coding.is_value()
  && field_bep__period2__present.is_value()
  && (OPTIONAL_OMIT == field_bep__period2.get_selection() || field_bep__period2.is_value())
  && field_resegment.is_value()
  && field_egprs__window__size.is_value()
  && field_alpha__present.is_value()
  && (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_value())
  && field_gamma.is_value()
  && field_ta__index__present.is_value()
  && (OPTIONAL_OMIT == field_ta__index.get_selection() || field_ta__index.is_value())
  && field_tbf__starting__time__present.is_value()
  && (OPTIONAL_OMIT == field_tbf__starting__time.get_selection() || field_tbf__starting__time.is_value());
}
int EgprsUlAssignDyn::size_of() const
{
  int ret_val = 15;
  if (field_p0.ispresent()) ret_val++;
  if (field_pr__mode.ispresent()) ret_val++;
  if (field_bep__period2.ispresent()) ret_val++;
  if (field_alpha.ispresent()) ret_val++;
  if (field_ta__index.ispresent()) ret_val++;
  if (field_tbf__starting__time.ispresent()) ret_val++;
  return ret_val;
}

void EgprsUlAssignDyn::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ tfi_assignment := ");
field_tfi__assignment.log();
TTCN_Logger::log_event_str(", polling := ");
field_polling.log();
TTCN_Logger::log_event_str(", spare := ");
field_spare.log();
TTCN_Logger::log_event_str(", usf := ");
field_usf.log();
TTCN_Logger::log_event_str(", usf_granularity := ");
field_usf__granularity.log();
TTCN_Logger::log_event_str(", p0_present := ");
field_p0__present.log();
TTCN_Logger::log_event_str(", p0 := ");
field_p0.log();
TTCN_Logger::log_event_str(", pr_mode := ");
field_pr__mode.log();
TTCN_Logger::log_event_str(", egprs_ch_coding_cmd := ");
field_egprs__ch__coding__cmd.log();
TTCN_Logger::log_event_str(", tlli_block_chan_coding := ");
field_tlli__block__chan__coding.log();
TTCN_Logger::log_event_str(", bep_period2_present := ");
field_bep__period2__present.log();
TTCN_Logger::log_event_str(", bep_period2 := ");
field_bep__period2.log();
TTCN_Logger::log_event_str(", resegment := ");
field_resegment.log();
TTCN_Logger::log_event_str(", egprs_window_size := ");
field_egprs__window__size.log();
TTCN_Logger::log_event_str(", alpha_present := ");
field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
field_gamma.log();
TTCN_Logger::log_event_str(", ta_index_present := ");
field_ta__index__present.log();
TTCN_Logger::log_event_str(", ta_index := ");
field_ta__index.log();
TTCN_Logger::log_event_str(", tbf_starting_time_present := ");
field_tbf__starting__time__present.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
field_tbf__starting__time.log();
TTCN_Logger::log_event_str(" }");
}

void EgprsUlAssignDyn::set_implicit_omit()
{
if (tfi__assignment().is_bound()) tfi__assignment().set_implicit_omit();
if (polling().is_bound()) polling().set_implicit_omit();
if (spare().is_bound()) spare().set_implicit_omit();
if (usf().is_bound()) usf().set_implicit_omit();
if (usf__granularity().is_bound()) usf__granularity().set_implicit_omit();
if (p0__present().is_bound()) p0__present().set_implicit_omit();
if (!p0().is_bound()) p0() = OMIT_VALUE;
else p0().set_implicit_omit();
if (!pr__mode().is_bound()) pr__mode() = OMIT_VALUE;
else pr__mode().set_implicit_omit();
if (egprs__ch__coding__cmd().is_bound()) egprs__ch__coding__cmd().set_implicit_omit();
if (tlli__block__chan__coding().is_bound()) tlli__block__chan__coding().set_implicit_omit();
if (bep__period2__present().is_bound()) bep__period2__present().set_implicit_omit();
if (!bep__period2().is_bound()) bep__period2() = OMIT_VALUE;
else bep__period2().set_implicit_omit();
if (resegment().is_bound()) resegment().set_implicit_omit();
if (egprs__window__size().is_bound()) egprs__window__size().set_implicit_omit();
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (ta__index__present().is_bound()) ta__index__present().set_implicit_omit();
if (!ta__index().is_bound()) ta__index() = OMIT_VALUE;
else ta__index().set_implicit_omit();
if (tbf__starting__time__present().is_bound()) tbf__starting__time__present().set_implicit_omit();
if (!tbf__starting__time().is_bound()) tbf__starting__time() = OMIT_VALUE;
else tbf__starting__time().set_implicit_omit();
}

void EgprsUlAssignDyn::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (21<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.EgprsUlAssignDyn has 21 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) tfi__assignment().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) polling().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) spare().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) usf().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) usf__granularity().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) p0__present().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) p0().set_param(*param.get_elem(6));
    if (param.get_size()>7 && param.get_elem(7)->get_type()!=Module_Param::MP_NotUsed) pr__mode().set_param(*param.get_elem(7));
    if (param.get_size()>8 && param.get_elem(8)->get_type()!=Module_Param::MP_NotUsed) egprs__ch__coding__cmd().set_param(*param.get_elem(8));
    if (param.get_size()>9 && param.get_elem(9)->get_type()!=Module_Param::MP_NotUsed) tlli__block__chan__coding().set_param(*param.get_elem(9));
    if (param.get_size()>10 && param.get_elem(10)->get_type()!=Module_Param::MP_NotUsed) bep__period2__present().set_param(*param.get_elem(10));
    if (param.get_size()>11 && param.get_elem(11)->get_type()!=Module_Param::MP_NotUsed) bep__period2().set_param(*param.get_elem(11));
    if (param.get_size()>12 && param.get_elem(12)->get_type()!=Module_Param::MP_NotUsed) resegment().set_param(*param.get_elem(12));
    if (param.get_size()>13 && param.get_elem(13)->get_type()!=Module_Param::MP_NotUsed) egprs__window__size().set_param(*param.get_elem(13));
    if (param.get_size()>14 && param.get_elem(14)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(14));
    if (param.get_size()>15 && param.get_elem(15)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(15));
    if (param.get_size()>16 && param.get_elem(16)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(16));
    if (param.get_size()>17 && param.get_elem(17)->get_type()!=Module_Param::MP_NotUsed) ta__index__present().set_param(*param.get_elem(17));
    if (param.get_size()>18 && param.get_elem(18)->get_type()!=Module_Param::MP_NotUsed) ta__index().set_param(*param.get_elem(18));
    if (param.get_size()>19 && param.get_elem(19)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time__present().set_param(*param.get_elem(19));
    if (param.get_size()>20 && param.get_elem(20)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(20));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tfi_assignment")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tfi__assignment().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "polling")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          polling().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "spare")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          spare().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "usf")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          usf().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "usf_granularity")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          usf__granularity().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pr_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pr__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "egprs_ch_coding_cmd")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          egprs__ch__coding__cmd().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tlli_block_chan_coding")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tlli__block__chan__coding().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "bep_period2_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          bep__period2__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "bep_period2")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          bep__period2().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "resegment")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          resegment().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "egprs_window_size")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          egprs__window__size().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.EgprsUlAssignDyn: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.EgprsUlAssignDyn");
  }
}

void EgprsUlAssignDyn::encode_text(Text_Buf& text_buf) const
{
field_tfi__assignment.encode_text(text_buf);
field_polling.encode_text(text_buf);
field_spare.encode_text(text_buf);
field_usf.encode_text(text_buf);
field_usf__granularity.encode_text(text_buf);
field_p0__present.encode_text(text_buf);
field_p0.encode_text(text_buf);
field_pr__mode.encode_text(text_buf);
field_egprs__ch__coding__cmd.encode_text(text_buf);
field_tlli__block__chan__coding.encode_text(text_buf);
field_bep__period2__present.encode_text(text_buf);
field_bep__period2.encode_text(text_buf);
field_resegment.encode_text(text_buf);
field_egprs__window__size.encode_text(text_buf);
field_alpha__present.encode_text(text_buf);
field_alpha.encode_text(text_buf);
field_gamma.encode_text(text_buf);
field_ta__index__present.encode_text(text_buf);
field_ta__index.encode_text(text_buf);
field_tbf__starting__time__present.encode_text(text_buf);
field_tbf__starting__time.encode_text(text_buf);
}

void EgprsUlAssignDyn::decode_text(Text_Buf& text_buf)
{
field_tfi__assignment.decode_text(text_buf);
field_polling.decode_text(text_buf);
field_spare.decode_text(text_buf);
field_usf.decode_text(text_buf);
field_usf__granularity.decode_text(text_buf);
field_p0__present.decode_text(text_buf);
field_p0.decode_text(text_buf);
field_pr__mode.decode_text(text_buf);
field_egprs__ch__coding__cmd.decode_text(text_buf);
field_tlli__block__chan__coding.decode_text(text_buf);
field_bep__period2__present.decode_text(text_buf);
field_bep__period2.decode_text(text_buf);
field_resegment.decode_text(text_buf);
field_egprs__window__size.decode_text(text_buf);
field_alpha__present.decode_text(text_buf);
field_alpha.decode_text(text_buf);
field_gamma.decode_text(text_buf);
field_ta__index__present.decode_text(text_buf);
field_ta__index.decode_text(text_buf);
field_tbf__starting__time__present.decode_text(text_buf);
field_tbf__starting__time.decode_text(text_buf);
}

void EgprsUlAssignDyn::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void EgprsUlAssignDyn::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int EgprsUlAssignDyn::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, EgprsUlAssignDyn_tfi__assignment_descr_.raw->forceomit);
  decoded_field_length = field_tfi__assignment.RAW_decode(EgprsUlAssignDyn_tfi__assignment_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_1_force_omit(1, force_omit, EgprsUlAssignDyn_polling_descr_.raw->forceomit);
  decoded_field_length = field_polling.RAW_decode(EgprsUlAssignDyn_polling_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_2_force_omit(2, force_omit, EgprsUlAssignDyn_spare_descr_.raw->forceomit);
  decoded_field_length = field_spare.RAW_decode(EgprsUlAssignDyn_spare_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_3_force_omit(3, force_omit, EgprsUlAssignDyn_usf_descr_.raw->forceomit);
  decoded_field_length = field_usf.RAW_decode(EgprsUlAssignDyn_usf_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_3_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_4_force_omit(4, force_omit, EgprsUlAssignDyn_usf__granularity_descr_.raw->forceomit);
  decoded_field_length = field_usf__granularity.RAW_decode(EgprsUlAssignDyn_usf__granularity_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_4_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_5_force_omit(5, force_omit, EgprsUlAssignDyn_p0__present_descr_.raw->forceomit);
  decoded_field_length = field_p0__present.RAW_decode(EgprsUlAssignDyn_p0__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_5_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_p0__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(6)) {
    field_p0 = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_6_force_omit(6, force_omit, EgprsUlAssignDyn_p0_descr_.raw->forceomit);
  decoded_field_length = field_p0().RAW_decode(EgprsUlAssignDyn_p0_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_6_force_omit);
  if (decoded_field_length < 1) {
  field_p0 = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_p0=OMIT_VALUE;
  if (limit > 0 && field_p0__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(7)) {
    field_pr__mode = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_7_force_omit(7, force_omit, EgprsUlAssignDyn_pr__mode_descr_.raw->forceomit);
  decoded_field_length = field_pr__mode().RAW_decode(EgprsUlAssignDyn_pr__mode_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_7_force_omit);
  if (decoded_field_length < 1) {
  field_pr__mode = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_pr__mode=OMIT_VALUE;
  RAW_Force_Omit field_8_force_omit(8, force_omit, EgprsUlAssignDyn_egprs__ch__coding__cmd_descr_.raw->forceomit);
  decoded_field_length = field_egprs__ch__coding__cmd.RAW_decode(EgprsUlAssignDyn_egprs__ch__coding__cmd_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_8_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_9_force_omit(9, force_omit, EgprsUlAssignDyn_tlli__block__chan__coding_descr_.raw->forceomit);
  decoded_field_length = field_tlli__block__chan__coding.RAW_decode(EgprsUlAssignDyn_tlli__block__chan__coding_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_9_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_10_force_omit(10, force_omit, EgprsUlAssignDyn_bep__period2__present_descr_.raw->forceomit);
  decoded_field_length = field_bep__period2__present.RAW_decode(EgprsUlAssignDyn_bep__period2__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_10_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_bep__period2__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(11)) {
    field_bep__period2 = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_11_force_omit(11, force_omit, EgprsUlAssignDyn_bep__period2_descr_.raw->forceomit);
  decoded_field_length = field_bep__period2().RAW_decode(EgprsUlAssignDyn_bep__period2_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_11_force_omit);
  if (decoded_field_length < 1) {
  field_bep__period2 = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_bep__period2=OMIT_VALUE;
  RAW_Force_Omit field_12_force_omit(12, force_omit, EgprsUlAssignDyn_resegment_descr_.raw->forceomit);
  decoded_field_length = field_resegment.RAW_decode(EgprsUlAssignDyn_resegment_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_12_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_13_force_omit(13, force_omit, EgprsUlAssignDyn_egprs__window__size_descr_.raw->forceomit);
  decoded_field_length = field_egprs__window__size.RAW_decode(EgprsUlAssignDyn_egprs__window__size_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_13_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_14_force_omit(14, force_omit, EgprsUlAssignDyn_alpha__present_descr_.raw->forceomit);
  decoded_field_length = field_alpha__present.RAW_decode(EgprsUlAssignDyn_alpha__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_14_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_alpha__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(15)) {
    field_alpha = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_15_force_omit(15, force_omit, EgprsUlAssignDyn_alpha_descr_.raw->forceomit);
  decoded_field_length = field_alpha().RAW_decode(EgprsUlAssignDyn_alpha_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_15_force_omit);
  if (decoded_field_length < 1) {
  field_alpha = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_alpha=OMIT_VALUE;
  RAW_Force_Omit field_16_force_omit(16, force_omit, EgprsUlAssignDyn_gamma_descr_.raw->forceomit);
  decoded_field_length = field_gamma.RAW_decode(EgprsUlAssignDyn_gamma_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_16_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_17_force_omit(17, force_omit, EgprsUlAssignDyn_ta__index__present_descr_.raw->forceomit);
  decoded_field_length = field_ta__index__present.RAW_decode(EgprsUlAssignDyn_ta__index__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_17_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_ta__index__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(18)) {
    field_ta__index = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_18_force_omit(18, force_omit, EgprsUlAssignDyn_ta__index_descr_.raw->forceomit);
  decoded_field_length = field_ta__index().RAW_decode(EgprsUlAssignDyn_ta__index_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_18_force_omit);
  if (decoded_field_length < 1) {
  field_ta__index = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_ta__index=OMIT_VALUE;
  RAW_Force_Omit field_19_force_omit(19, force_omit, EgprsUlAssignDyn_tbf__starting__time__present_descr_.raw->forceomit);
  decoded_field_length = field_tbf__starting__time__present.RAW_decode(EgprsUlAssignDyn_tbf__starting__time__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_19_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_tbf__starting__time__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(20)) {
    field_tbf__starting__time = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_20_force_omit(20, force_omit, EgprsUlAssignDyn_tbf__starting__time_descr_.raw->forceomit);
  decoded_field_length = field_tbf__starting__time().RAW_decode(EgprsUlAssignDyn_tbf__starting__time_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_20_force_omit);
  if (decoded_field_length < 1) {
  field_tbf__starting__time = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_tbf__starting__time=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int EgprsUlAssignDyn::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 21;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(21);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, EgprsUlAssignDyn_tfi__assignment_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, EgprsUlAssignDyn_polling_descr_.raw);
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, EgprsUlAssignDyn_spare_descr_.raw);
  myleaf.body.node.nodes[3] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 3, EgprsUlAssignDyn_usf_descr_.raw);
  myleaf.body.node.nodes[4] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 4, EgprsUlAssignDyn_usf__granularity_descr_.raw);
  myleaf.body.node.nodes[5] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 5, EgprsUlAssignDyn_p0__present_descr_.raw);
  if (field_p0.ispresent()) {
  myleaf.body.node.nodes[6] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 6, EgprsUlAssignDyn_p0_descr_.raw);
  }
  else myleaf.body.node.nodes[6] = NULL;
  if (field_pr__mode.ispresent()) {
  myleaf.body.node.nodes[7] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 7, EgprsUlAssignDyn_pr__mode_descr_.raw);
  }
  else myleaf.body.node.nodes[7] = NULL;
  myleaf.body.node.nodes[8] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 8, EgprsUlAssignDyn_egprs__ch__coding__cmd_descr_.raw);
  myleaf.body.node.nodes[9] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 9, EgprsUlAssignDyn_tlli__block__chan__coding_descr_.raw);
  myleaf.body.node.nodes[10] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 10, EgprsUlAssignDyn_bep__period2__present_descr_.raw);
  if (field_bep__period2.ispresent()) {
  myleaf.body.node.nodes[11] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 11, EgprsUlAssignDyn_bep__period2_descr_.raw);
  }
  else myleaf.body.node.nodes[11] = NULL;
  myleaf.body.node.nodes[12] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 12, EgprsUlAssignDyn_resegment_descr_.raw);
  myleaf.body.node.nodes[13] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 13, EgprsUlAssignDyn_egprs__window__size_descr_.raw);
  myleaf.body.node.nodes[14] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 14, EgprsUlAssignDyn_alpha__present_descr_.raw);
  if (field_alpha.ispresent()) {
  myleaf.body.node.nodes[15] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 15, EgprsUlAssignDyn_alpha_descr_.raw);
  }
  else myleaf.body.node.nodes[15] = NULL;
  myleaf.body.node.nodes[16] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 16, EgprsUlAssignDyn_gamma_descr_.raw);
  myleaf.body.node.nodes[17] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 17, EgprsUlAssignDyn_ta__index__present_descr_.raw);
  if (field_ta__index.ispresent()) {
  myleaf.body.node.nodes[18] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 18, EgprsUlAssignDyn_ta__index_descr_.raw);
  }
  else myleaf.body.node.nodes[18] = NULL;
  myleaf.body.node.nodes[19] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 19, EgprsUlAssignDyn_tbf__starting__time__present_descr_.raw);
  if (field_tbf__starting__time.ispresent()) {
  myleaf.body.node.nodes[20] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 20, EgprsUlAssignDyn_tbf__starting__time_descr_.raw);
  }
  else myleaf.body.node.nodes[20] = NULL;
  encoded_length += field_tfi__assignment.RAW_encode(EgprsUlAssignDyn_tfi__assignment_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_polling.RAW_encode(EgprsUlAssignDyn_polling_descr_, *myleaf.body.node.nodes[1]);
  encoded_length += field_spare.RAW_encode(EgprsUlAssignDyn_spare_descr_, *myleaf.body.node.nodes[2]);
  encoded_length += field_usf.RAW_encode(EgprsUlAssignDyn_usf_descr_, *myleaf.body.node.nodes[3]);
  encoded_length += field_usf__granularity.RAW_encode(EgprsUlAssignDyn_usf__granularity_descr_, *myleaf.body.node.nodes[4]);
  encoded_length += field_p0__present.RAW_encode(EgprsUlAssignDyn_p0__present_descr_, *myleaf.body.node.nodes[5]);
  if (field_p0.ispresent()) {
  encoded_length += field_p0().RAW_encode(EgprsUlAssignDyn_p0_descr_, *myleaf.body.node.nodes[6]);
  }
  if (field_pr__mode.ispresent()) {
  encoded_length += field_pr__mode().RAW_encode(EgprsUlAssignDyn_pr__mode_descr_, *myleaf.body.node.nodes[7]);
  }
  encoded_length += field_egprs__ch__coding__cmd.RAW_encode(EgprsUlAssignDyn_egprs__ch__coding__cmd_descr_, *myleaf.body.node.nodes[8]);
  encoded_length += field_tlli__block__chan__coding.RAW_encode(EgprsUlAssignDyn_tlli__block__chan__coding_descr_, *myleaf.body.node.nodes[9]);
  encoded_length += field_bep__period2__present.RAW_encode(EgprsUlAssignDyn_bep__period2__present_descr_, *myleaf.body.node.nodes[10]);
  if (field_bep__period2.ispresent()) {
  encoded_length += field_bep__period2().RAW_encode(EgprsUlAssignDyn_bep__period2_descr_, *myleaf.body.node.nodes[11]);
  }
  encoded_length += field_resegment.RAW_encode(EgprsUlAssignDyn_resegment_descr_, *myleaf.body.node.nodes[12]);
  encoded_length += field_egprs__window__size.RAW_encode(EgprsUlAssignDyn_egprs__window__size_descr_, *myleaf.body.node.nodes[13]);
  encoded_length += field_alpha__present.RAW_encode(EgprsUlAssignDyn_alpha__present_descr_, *myleaf.body.node.nodes[14]);
  if (field_alpha.ispresent()) {
  encoded_length += field_alpha().RAW_encode(EgprsUlAssignDyn_alpha_descr_, *myleaf.body.node.nodes[15]);
  }
  encoded_length += field_gamma.RAW_encode(EgprsUlAssignDyn_gamma_descr_, *myleaf.body.node.nodes[16]);
  encoded_length += field_ta__index__present.RAW_encode(EgprsUlAssignDyn_ta__index__present_descr_, *myleaf.body.node.nodes[17]);
  if (field_ta__index.ispresent()) {
  encoded_length += field_ta__index().RAW_encode(EgprsUlAssignDyn_ta__index_descr_, *myleaf.body.node.nodes[18]);
  }
  encoded_length += field_tbf__starting__time__present.RAW_encode(EgprsUlAssignDyn_tbf__starting__time__present_descr_, *myleaf.body.node.nodes[19]);
  if (field_tbf__starting__time.ispresent()) {
  encoded_length += field_tbf__starting__time().RAW_encode(EgprsUlAssignDyn_tbf__starting__time_descr_, *myleaf.body.node.nodes[20]);
  }
  if (field_p0.ispresent() && (field_p0__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={5};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignDyn_p0__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_pr__mode.ispresent() && (field_p0__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={5};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignDyn_p0__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_bep__period2.ispresent() && (field_bep__period2__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={10};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignDyn_bep__period2__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_alpha.ispresent() && (field_alpha__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={14};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignDyn_alpha__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_ta__index.ispresent() && (field_ta__index__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={17};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignDyn_ta__index__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_tbf__starting__time.ispresent() && (field_tbf__starting__time__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={19};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignDyn_tbf__starting__time__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct EgprsUlAssignDyn_template::single_value_struct {
INTEGER_template field_tfi__assignment;
BITSTRING_template field_polling;
BITSTRING_template field_spare;
INTEGER_template field_usf;
BITSTRING_template field_usf__granularity;
BITSTRING_template field_p0__present;
INTEGER_template field_p0;
BITSTRING_template field_pr__mode;
RLCMAC__CSN1__Types::EgprsChCodingCommand_template field_egprs__ch__coding__cmd;
BITSTRING_template field_tlli__block__chan__coding;
BITSTRING_template field_bep__period2__present;
BITSTRING_template field_bep__period2;
BITSTRING_template field_resegment;
RLCMAC__CSN1__Types::EgprsWindowSize_template field_egprs__window__size;
BITSTRING_template field_alpha__present;
INTEGER_template field_alpha;
INTEGER_template field_gamma;
BITSTRING_template field_ta__index__present;
INTEGER_template field_ta__index;
BITSTRING_template field_tbf__starting__time__present;
TbfStartingTime_template field_tbf__starting__time;
};

void EgprsUlAssignDyn_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_tfi__assignment = ANY_VALUE;
single_value->field_polling = ANY_VALUE;
single_value->field_spare = ANY_VALUE;
single_value->field_usf = ANY_VALUE;
single_value->field_usf__granularity = ANY_VALUE;
single_value->field_p0__present = ANY_VALUE;
single_value->field_p0 = ANY_OR_OMIT;
single_value->field_pr__mode = ANY_OR_OMIT;
single_value->field_egprs__ch__coding__cmd = ANY_VALUE;
single_value->field_tlli__block__chan__coding = ANY_VALUE;
single_value->field_bep__period2__present = ANY_VALUE;
single_value->field_bep__period2 = ANY_OR_OMIT;
single_value->field_resegment = ANY_VALUE;
single_value->field_egprs__window__size = ANY_VALUE;
single_value->field_alpha__present = ANY_VALUE;
single_value->field_alpha = ANY_OR_OMIT;
single_value->field_gamma = ANY_VALUE;
single_value->field_ta__index__present = ANY_VALUE;
single_value->field_ta__index = ANY_OR_OMIT;
single_value->field_tbf__starting__time__present = ANY_VALUE;
single_value->field_tbf__starting__time = ANY_OR_OMIT;
}
}
}

void EgprsUlAssignDyn_template::copy_value(const EgprsUlAssignDyn& other_value)
{
single_value = new single_value_struct;
if (other_value.tfi__assignment().is_bound()) {
  single_value->field_tfi__assignment = other_value.tfi__assignment();
} else {
  single_value->field_tfi__assignment.clean_up();
}
if (other_value.polling().is_bound()) {
  single_value->field_polling = other_value.polling();
} else {
  single_value->field_polling.clean_up();
}
if (other_value.spare().is_bound()) {
  single_value->field_spare = other_value.spare();
} else {
  single_value->field_spare.clean_up();
}
if (other_value.usf().is_bound()) {
  single_value->field_usf = other_value.usf();
} else {
  single_value->field_usf.clean_up();
}
if (other_value.usf__granularity().is_bound()) {
  single_value->field_usf__granularity = other_value.usf__granularity();
} else {
  single_value->field_usf__granularity.clean_up();
}
if (other_value.p0__present().is_bound()) {
  single_value->field_p0__present = other_value.p0__present();
} else {
  single_value->field_p0__present.clean_up();
}
if (other_value.p0().is_bound()) {
  if (other_value.p0().ispresent()) single_value->field_p0 = other_value.p0()();
  else single_value->field_p0 = OMIT_VALUE;
} else {
  single_value->field_p0.clean_up();
}
if (other_value.pr__mode().is_bound()) {
  if (other_value.pr__mode().ispresent()) single_value->field_pr__mode = other_value.pr__mode()();
  else single_value->field_pr__mode = OMIT_VALUE;
} else {
  single_value->field_pr__mode.clean_up();
}
if (other_value.egprs__ch__coding__cmd().is_bound()) {
  single_value->field_egprs__ch__coding__cmd = other_value.egprs__ch__coding__cmd();
} else {
  single_value->field_egprs__ch__coding__cmd.clean_up();
}
if (other_value.tlli__block__chan__coding().is_bound()) {
  single_value->field_tlli__block__chan__coding = other_value.tlli__block__chan__coding();
} else {
  single_value->field_tlli__block__chan__coding.clean_up();
}
if (other_value.bep__period2__present().is_bound()) {
  single_value->field_bep__period2__present = other_value.bep__period2__present();
} else {
  single_value->field_bep__period2__present.clean_up();
}
if (other_value.bep__period2().is_bound()) {
  if (other_value.bep__period2().ispresent()) single_value->field_bep__period2 = other_value.bep__period2()();
  else single_value->field_bep__period2 = OMIT_VALUE;
} else {
  single_value->field_bep__period2.clean_up();
}
if (other_value.resegment().is_bound()) {
  single_value->field_resegment = other_value.resegment();
} else {
  single_value->field_resegment.clean_up();
}
if (other_value.egprs__window__size().is_bound()) {
  single_value->field_egprs__window__size = other_value.egprs__window__size();
} else {
  single_value->field_egprs__window__size.clean_up();
}
if (other_value.alpha__present().is_bound()) {
  single_value->field_alpha__present = other_value.alpha__present();
} else {
  single_value->field_alpha__present.clean_up();
}
if (other_value.alpha().is_bound()) {
  if (other_value.alpha().ispresent()) single_value->field_alpha = other_value.alpha()();
  else single_value->field_alpha = OMIT_VALUE;
} else {
  single_value->field_alpha.clean_up();
}
if (other_value.gamma().is_bound()) {
  single_value->field_gamma = other_value.gamma();
} else {
  single_value->field_gamma.clean_up();
}
if (other_value.ta__index__present().is_bound()) {
  single_value->field_ta__index__present = other_value.ta__index__present();
} else {
  single_value->field_ta__index__present.clean_up();
}
if (other_value.ta__index().is_bound()) {
  if (other_value.ta__index().ispresent()) single_value->field_ta__index = other_value.ta__index()();
  else single_value->field_ta__index = OMIT_VALUE;
} else {
  single_value->field_ta__index.clean_up();
}
if (other_value.tbf__starting__time__present().is_bound()) {
  single_value->field_tbf__starting__time__present = other_value.tbf__starting__time__present();
} else {
  single_value->field_tbf__starting__time__present.clean_up();
}
if (other_value.tbf__starting__time().is_bound()) {
  if (other_value.tbf__starting__time().ispresent()) single_value->field_tbf__starting__time = other_value.tbf__starting__time()();
  else single_value->field_tbf__starting__time = OMIT_VALUE;
} else {
  single_value->field_tbf__starting__time.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void EgprsUlAssignDyn_template::copy_template(const EgprsUlAssignDyn_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.tfi__assignment().get_selection()) {
single_value->field_tfi__assignment = other_value.tfi__assignment();
} else {
single_value->field_tfi__assignment.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.polling().get_selection()) {
single_value->field_polling = other_value.polling();
} else {
single_value->field_polling.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.spare().get_selection()) {
single_value->field_spare = other_value.spare();
} else {
single_value->field_spare.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.usf().get_selection()) {
single_value->field_usf = other_value.usf();
} else {
single_value->field_usf.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.usf__granularity().get_selection()) {
single_value->field_usf__granularity = other_value.usf__granularity();
} else {
single_value->field_usf__granularity.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.p0__present().get_selection()) {
single_value->field_p0__present = other_value.p0__present();
} else {
single_value->field_p0__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.p0().get_selection()) {
single_value->field_p0 = other_value.p0();
} else {
single_value->field_p0.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.pr__mode().get_selection()) {
single_value->field_pr__mode = other_value.pr__mode();
} else {
single_value->field_pr__mode.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.egprs__ch__coding__cmd().get_selection()) {
single_value->field_egprs__ch__coding__cmd = other_value.egprs__ch__coding__cmd();
} else {
single_value->field_egprs__ch__coding__cmd.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tlli__block__chan__coding().get_selection()) {
single_value->field_tlli__block__chan__coding = other_value.tlli__block__chan__coding();
} else {
single_value->field_tlli__block__chan__coding.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.bep__period2__present().get_selection()) {
single_value->field_bep__period2__present = other_value.bep__period2__present();
} else {
single_value->field_bep__period2__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.bep__period2().get_selection()) {
single_value->field_bep__period2 = other_value.bep__period2();
} else {
single_value->field_bep__period2.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.resegment().get_selection()) {
single_value->field_resegment = other_value.resegment();
} else {
single_value->field_resegment.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.egprs__window__size().get_selection()) {
single_value->field_egprs__window__size = other_value.egprs__window__size();
} else {
single_value->field_egprs__window__size.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.alpha__present().get_selection()) {
single_value->field_alpha__present = other_value.alpha__present();
} else {
single_value->field_alpha__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.alpha().get_selection()) {
single_value->field_alpha = other_value.alpha();
} else {
single_value->field_alpha.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.gamma().get_selection()) {
single_value->field_gamma = other_value.gamma();
} else {
single_value->field_gamma.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ta__index__present().get_selection()) {
single_value->field_ta__index__present = other_value.ta__index__present();
} else {
single_value->field_ta__index__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ta__index().get_selection()) {
single_value->field_ta__index = other_value.ta__index();
} else {
single_value->field_ta__index.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tbf__starting__time__present().get_selection()) {
single_value->field_tbf__starting__time__present = other_value.tbf__starting__time__present();
} else {
single_value->field_tbf__starting__time__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tbf__starting__time().get_selection()) {
single_value->field_tbf__starting__time = other_value.tbf__starting__time();
} else {
single_value->field_tbf__starting__time.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new EgprsUlAssignDyn_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new EgprsUlAssignDyn_template(*other_value.implication_.precondition);
implication_.implied_template = new EgprsUlAssignDyn_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAssignDyn.");
break;
}
set_selection(other_value);
}

EgprsUlAssignDyn_template::EgprsUlAssignDyn_template()
{
}

EgprsUlAssignDyn_template::EgprsUlAssignDyn_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

EgprsUlAssignDyn_template::EgprsUlAssignDyn_template(const EgprsUlAssignDyn& other_value)
{
copy_value(other_value);
}

EgprsUlAssignDyn_template::EgprsUlAssignDyn_template(const OPTIONAL<EgprsUlAssignDyn>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const EgprsUlAssignDyn&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.EgprsUlAssignDyn from an unbound optional field.");
}
}

EgprsUlAssignDyn_template::EgprsUlAssignDyn_template(EgprsUlAssignDyn_template* p_precondition, EgprsUlAssignDyn_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

EgprsUlAssignDyn_template::EgprsUlAssignDyn_template(Dynamic_Match_Interface<EgprsUlAssignDyn>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<EgprsUlAssignDyn>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

EgprsUlAssignDyn_template::EgprsUlAssignDyn_template(const EgprsUlAssignDyn_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

EgprsUlAssignDyn_template::~EgprsUlAssignDyn_template()
{
clean_up();
}

EgprsUlAssignDyn_template& EgprsUlAssignDyn_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

EgprsUlAssignDyn_template& EgprsUlAssignDyn_template::operator=(const EgprsUlAssignDyn& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

EgprsUlAssignDyn_template& EgprsUlAssignDyn_template::operator=(const OPTIONAL<EgprsUlAssignDyn>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const EgprsUlAssignDyn&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.EgprsUlAssignDyn.");
}
return *this;
}

EgprsUlAssignDyn_template& EgprsUlAssignDyn_template::operator=(const EgprsUlAssignDyn_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean EgprsUlAssignDyn_template::match(const EgprsUlAssignDyn& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.tfi__assignment().is_bound()) return FALSE;
if(!single_value->field_tfi__assignment.match(other_value.tfi__assignment(), legacy))return FALSE;
if(!other_value.polling().is_bound()) return FALSE;
if(!single_value->field_polling.match(other_value.polling(), legacy))return FALSE;
if(!other_value.spare().is_bound()) return FALSE;
if(!single_value->field_spare.match(other_value.spare(), legacy))return FALSE;
if(!other_value.usf().is_bound()) return FALSE;
if(!single_value->field_usf.match(other_value.usf(), legacy))return FALSE;
if(!other_value.usf__granularity().is_bound()) return FALSE;
if(!single_value->field_usf__granularity.match(other_value.usf__granularity(), legacy))return FALSE;
if(!other_value.p0__present().is_bound()) return FALSE;
if(!single_value->field_p0__present.match(other_value.p0__present(), legacy))return FALSE;
if(!other_value.p0().is_bound()) return FALSE;
if((other_value.p0().ispresent() ? !single_value->field_p0.match((const INTEGER&)other_value.p0(), legacy) : !single_value->field_p0.match_omit(legacy)))return FALSE;
if(!other_value.pr__mode().is_bound()) return FALSE;
if((other_value.pr__mode().ispresent() ? !single_value->field_pr__mode.match((const BITSTRING&)other_value.pr__mode(), legacy) : !single_value->field_pr__mode.match_omit(legacy)))return FALSE;
if(!other_value.egprs__ch__coding__cmd().is_bound()) return FALSE;
if(!single_value->field_egprs__ch__coding__cmd.match(other_value.egprs__ch__coding__cmd(), legacy))return FALSE;
if(!other_value.tlli__block__chan__coding().is_bound()) return FALSE;
if(!single_value->field_tlli__block__chan__coding.match(other_value.tlli__block__chan__coding(), legacy))return FALSE;
if(!other_value.bep__period2__present().is_bound()) return FALSE;
if(!single_value->field_bep__period2__present.match(other_value.bep__period2__present(), legacy))return FALSE;
if(!other_value.bep__period2().is_bound()) return FALSE;
if((other_value.bep__period2().ispresent() ? !single_value->field_bep__period2.match((const BITSTRING&)other_value.bep__period2(), legacy) : !single_value->field_bep__period2.match_omit(legacy)))return FALSE;
if(!other_value.resegment().is_bound()) return FALSE;
if(!single_value->field_resegment.match(other_value.resegment(), legacy))return FALSE;
if(!other_value.egprs__window__size().is_bound()) return FALSE;
if(!single_value->field_egprs__window__size.match(other_value.egprs__window__size(), legacy))return FALSE;
if(!other_value.alpha__present().is_bound()) return FALSE;
if(!single_value->field_alpha__present.match(other_value.alpha__present(), legacy))return FALSE;
if(!other_value.alpha().is_bound()) return FALSE;
if((other_value.alpha().ispresent() ? !single_value->field_alpha.match((const INTEGER&)other_value.alpha(), legacy) : !single_value->field_alpha.match_omit(legacy)))return FALSE;
if(!other_value.gamma().is_bound()) return FALSE;
if(!single_value->field_gamma.match(other_value.gamma(), legacy))return FALSE;
if(!other_value.ta__index__present().is_bound()) return FALSE;
if(!single_value->field_ta__index__present.match(other_value.ta__index__present(), legacy))return FALSE;
if(!other_value.ta__index().is_bound()) return FALSE;
if((other_value.ta__index().ispresent() ? !single_value->field_ta__index.match((const INTEGER&)other_value.ta__index(), legacy) : !single_value->field_ta__index.match_omit(legacy)))return FALSE;
if(!other_value.tbf__starting__time__present().is_bound()) return FALSE;
if(!single_value->field_tbf__starting__time__present.match(other_value.tbf__starting__time__present(), legacy))return FALSE;
if(!other_value.tbf__starting__time().is_bound()) return FALSE;
if((other_value.tbf__starting__time().ispresent() ? !single_value->field_tbf__starting__time.match((const TbfStartingTime&)other_value.tbf__starting__time(), legacy) : !single_value->field_tbf__starting__time.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAssignDyn.");
}
return FALSE;
}

boolean EgprsUlAssignDyn_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_tfi__assignment.is_bound()
 || single_value->field_polling.is_bound()
 || single_value->field_spare.is_bound()
 || single_value->field_usf.is_bound()
 || single_value->field_usf__granularity.is_bound()
 || single_value->field_p0__present.is_bound()
 || (single_value->field_p0.is_omit() || single_value->field_p0.is_bound())
 || (single_value->field_pr__mode.is_omit() || single_value->field_pr__mode.is_bound())
 || single_value->field_egprs__ch__coding__cmd.is_bound()
 || single_value->field_tlli__block__chan__coding.is_bound()
 || single_value->field_bep__period2__present.is_bound()
 || (single_value->field_bep__period2.is_omit() || single_value->field_bep__period2.is_bound())
 || single_value->field_resegment.is_bound()
 || single_value->field_egprs__window__size.is_bound()
 || single_value->field_alpha__present.is_bound()
 || (single_value->field_alpha.is_omit() || single_value->field_alpha.is_bound())
 || single_value->field_gamma.is_bound()
 || single_value->field_ta__index__present.is_bound()
 || (single_value->field_ta__index.is_omit() || single_value->field_ta__index.is_bound())
 || single_value->field_tbf__starting__time__present.is_bound()
 || (single_value->field_tbf__starting__time.is_omit() || single_value->field_tbf__starting__time.is_bound());
}

boolean EgprsUlAssignDyn_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_tfi__assignment.is_value()
 && single_value->field_polling.is_value()
 && single_value->field_spare.is_value()
 && single_value->field_usf.is_value()
 && single_value->field_usf__granularity.is_value()
 && single_value->field_p0__present.is_value()
 && (single_value->field_p0.is_omit() || single_value->field_p0.is_value())
 && (single_value->field_pr__mode.is_omit() || single_value->field_pr__mode.is_value())
 && single_value->field_egprs__ch__coding__cmd.is_value()
 && single_value->field_tlli__block__chan__coding.is_value()
 && single_value->field_bep__period2__present.is_value()
 && (single_value->field_bep__period2.is_omit() || single_value->field_bep__period2.is_value())
 && single_value->field_resegment.is_value()
 && single_value->field_egprs__window__size.is_value()
 && single_value->field_alpha__present.is_value()
 && (single_value->field_alpha.is_omit() || single_value->field_alpha.is_value())
 && single_value->field_gamma.is_value()
 && single_value->field_ta__index__present.is_value()
 && (single_value->field_ta__index.is_omit() || single_value->field_ta__index.is_value())
 && single_value->field_tbf__starting__time__present.is_value()
 && (single_value->field_tbf__starting__time.is_omit() || single_value->field_tbf__starting__time.is_value());
}

void EgprsUlAssignDyn_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

EgprsUlAssignDyn EgprsUlAssignDyn_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
EgprsUlAssignDyn ret_val;
if (single_value->field_tfi__assignment.is_bound()) {
ret_val.tfi__assignment() = single_value->field_tfi__assignment.valueof();
}
if (single_value->field_polling.is_bound()) {
ret_val.polling() = single_value->field_polling.valueof();
}
if (single_value->field_spare.is_bound()) {
ret_val.spare() = single_value->field_spare.valueof();
}
if (single_value->field_usf.is_bound()) {
ret_val.usf() = single_value->field_usf.valueof();
}
if (single_value->field_usf__granularity.is_bound()) {
ret_val.usf__granularity() = single_value->field_usf__granularity.valueof();
}
if (single_value->field_p0__present.is_bound()) {
ret_val.p0__present() = single_value->field_p0__present.valueof();
}
if (single_value->field_p0.is_omit()) ret_val.p0() = OMIT_VALUE;
else if (single_value->field_p0.is_bound()) {
ret_val.p0() = single_value->field_p0.valueof();
}
if (single_value->field_pr__mode.is_omit()) ret_val.pr__mode() = OMIT_VALUE;
else if (single_value->field_pr__mode.is_bound()) {
ret_val.pr__mode() = single_value->field_pr__mode.valueof();
}
if (single_value->field_egprs__ch__coding__cmd.is_bound()) {
ret_val.egprs__ch__coding__cmd() = single_value->field_egprs__ch__coding__cmd.valueof();
}
if (single_value->field_tlli__block__chan__coding.is_bound()) {
ret_val.tlli__block__chan__coding() = single_value->field_tlli__block__chan__coding.valueof();
}
if (single_value->field_bep__period2__present.is_bound()) {
ret_val.bep__period2__present() = single_value->field_bep__period2__present.valueof();
}
if (single_value->field_bep__period2.is_omit()) ret_val.bep__period2() = OMIT_VALUE;
else if (single_value->field_bep__period2.is_bound()) {
ret_val.bep__period2() = single_value->field_bep__period2.valueof();
}
if (single_value->field_resegment.is_bound()) {
ret_val.resegment() = single_value->field_resegment.valueof();
}
if (single_value->field_egprs__window__size.is_bound()) {
ret_val.egprs__window__size() = single_value->field_egprs__window__size.valueof();
}
if (single_value->field_alpha__present.is_bound()) {
ret_val.alpha__present() = single_value->field_alpha__present.valueof();
}
if (single_value->field_alpha.is_omit()) ret_val.alpha() = OMIT_VALUE;
else if (single_value->field_alpha.is_bound()) {
ret_val.alpha() = single_value->field_alpha.valueof();
}
if (single_value->field_gamma.is_bound()) {
ret_val.gamma() = single_value->field_gamma.valueof();
}
if (single_value->field_ta__index__present.is_bound()) {
ret_val.ta__index__present() = single_value->field_ta__index__present.valueof();
}
if (single_value->field_ta__index.is_omit()) ret_val.ta__index() = OMIT_VALUE;
else if (single_value->field_ta__index.is_bound()) {
ret_val.ta__index() = single_value->field_ta__index.valueof();
}
if (single_value->field_tbf__starting__time__present.is_bound()) {
ret_val.tbf__starting__time__present() = single_value->field_tbf__starting__time__present.valueof();
}
if (single_value->field_tbf__starting__time.is_omit()) ret_val.tbf__starting__time() = OMIT_VALUE;
else if (single_value->field_tbf__starting__time.is_bound()) {
ret_val.tbf__starting__time() = single_value->field_tbf__starting__time.valueof();
}
return ret_val;
}

void EgprsUlAssignDyn_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.EgprsUlAssignDyn.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new EgprsUlAssignDyn_template[list_length];
}

EgprsUlAssignDyn_template& EgprsUlAssignDyn_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.EgprsUlAssignDyn.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return value_list.list_value[list_index];
}

INTEGER_template& EgprsUlAssignDyn_template::tfi__assignment()
{
set_specific();
return single_value->field_tfi__assignment;
}

const INTEGER_template& EgprsUlAssignDyn_template::tfi__assignment() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tfi_assignment of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_tfi__assignment;
}

BITSTRING_template& EgprsUlAssignDyn_template::polling()
{
set_specific();
return single_value->field_polling;
}

const BITSTRING_template& EgprsUlAssignDyn_template::polling() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field polling of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_polling;
}

BITSTRING_template& EgprsUlAssignDyn_template::spare()
{
set_specific();
return single_value->field_spare;
}

const BITSTRING_template& EgprsUlAssignDyn_template::spare() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field spare of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_spare;
}

INTEGER_template& EgprsUlAssignDyn_template::usf()
{
set_specific();
return single_value->field_usf;
}

const INTEGER_template& EgprsUlAssignDyn_template::usf() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field usf of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_usf;
}

BITSTRING_template& EgprsUlAssignDyn_template::usf__granularity()
{
set_specific();
return single_value->field_usf__granularity;
}

const BITSTRING_template& EgprsUlAssignDyn_template::usf__granularity() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field usf_granularity of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_usf__granularity;
}

BITSTRING_template& EgprsUlAssignDyn_template::p0__present()
{
set_specific();
return single_value->field_p0__present;
}

const BITSTRING_template& EgprsUlAssignDyn_template::p0__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field p0_present of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_p0__present;
}

INTEGER_template& EgprsUlAssignDyn_template::p0()
{
set_specific();
return single_value->field_p0;
}

const INTEGER_template& EgprsUlAssignDyn_template::p0() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field p0 of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_p0;
}

BITSTRING_template& EgprsUlAssignDyn_template::pr__mode()
{
set_specific();
return single_value->field_pr__mode;
}

const BITSTRING_template& EgprsUlAssignDyn_template::pr__mode() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field pr_mode of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_pr__mode;
}

RLCMAC__CSN1__Types::EgprsChCodingCommand_template& EgprsUlAssignDyn_template::egprs__ch__coding__cmd()
{
set_specific();
return single_value->field_egprs__ch__coding__cmd;
}

const RLCMAC__CSN1__Types::EgprsChCodingCommand_template& EgprsUlAssignDyn_template::egprs__ch__coding__cmd() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field egprs_ch_coding_cmd of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_egprs__ch__coding__cmd;
}

BITSTRING_template& EgprsUlAssignDyn_template::tlli__block__chan__coding()
{
set_specific();
return single_value->field_tlli__block__chan__coding;
}

const BITSTRING_template& EgprsUlAssignDyn_template::tlli__block__chan__coding() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tlli_block_chan_coding of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_tlli__block__chan__coding;
}

BITSTRING_template& EgprsUlAssignDyn_template::bep__period2__present()
{
set_specific();
return single_value->field_bep__period2__present;
}

const BITSTRING_template& EgprsUlAssignDyn_template::bep__period2__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field bep_period2_present of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_bep__period2__present;
}

BITSTRING_template& EgprsUlAssignDyn_template::bep__period2()
{
set_specific();
return single_value->field_bep__period2;
}

const BITSTRING_template& EgprsUlAssignDyn_template::bep__period2() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field bep_period2 of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_bep__period2;
}

BITSTRING_template& EgprsUlAssignDyn_template::resegment()
{
set_specific();
return single_value->field_resegment;
}

const BITSTRING_template& EgprsUlAssignDyn_template::resegment() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field resegment of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_resegment;
}

RLCMAC__CSN1__Types::EgprsWindowSize_template& EgprsUlAssignDyn_template::egprs__window__size()
{
set_specific();
return single_value->field_egprs__window__size;
}

const RLCMAC__CSN1__Types::EgprsWindowSize_template& EgprsUlAssignDyn_template::egprs__window__size() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field egprs_window_size of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_egprs__window__size;
}

BITSTRING_template& EgprsUlAssignDyn_template::alpha__present()
{
set_specific();
return single_value->field_alpha__present;
}

const BITSTRING_template& EgprsUlAssignDyn_template::alpha__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha_present of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_alpha__present;
}

INTEGER_template& EgprsUlAssignDyn_template::alpha()
{
set_specific();
return single_value->field_alpha;
}

const INTEGER_template& EgprsUlAssignDyn_template::alpha() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_alpha;
}

INTEGER_template& EgprsUlAssignDyn_template::gamma()
{
set_specific();
return single_value->field_gamma;
}

const INTEGER_template& EgprsUlAssignDyn_template::gamma() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field gamma of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_gamma;
}

BITSTRING_template& EgprsUlAssignDyn_template::ta__index__present()
{
set_specific();
return single_value->field_ta__index__present;
}

const BITSTRING_template& EgprsUlAssignDyn_template::ta__index__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ta_index_present of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_ta__index__present;
}

INTEGER_template& EgprsUlAssignDyn_template::ta__index()
{
set_specific();
return single_value->field_ta__index;
}

const INTEGER_template& EgprsUlAssignDyn_template::ta__index() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ta_index of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_ta__index;
}

BITSTRING_template& EgprsUlAssignDyn_template::tbf__starting__time__present()
{
set_specific();
return single_value->field_tbf__starting__time__present;
}

const BITSTRING_template& EgprsUlAssignDyn_template::tbf__starting__time__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tbf_starting_time_present of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_tbf__starting__time__present;
}

TbfStartingTime_template& EgprsUlAssignDyn_template::tbf__starting__time()
{
set_specific();
return single_value->field_tbf__starting__time;
}

const TbfStartingTime_template& EgprsUlAssignDyn_template::tbf__starting__time() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tbf_starting_time of a non-specific template of type @GSM_RestOctets.EgprsUlAssignDyn.");
return single_value->field_tbf__starting__time;
}

int EgprsUlAssignDyn_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignDyn which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 15;
      if (single_value->field_p0.is_present()) ret_val++;
      if (single_value->field_pr__mode.is_present()) ret_val++;
      if (single_value->field_bep__period2.is_present()) ret_val++;
      if (single_value->field_alpha.is_present()) ret_val++;
      if (single_value->field_ta__index.is_present()) ret_val++;
      if (single_value->field_tbf__starting__time.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignDyn containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignDyn containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignDyn containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignDyn containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignDyn containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignDyn containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignDyn containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignDyn containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAssignDyn.");
  }
  return 0;
}

void EgprsUlAssignDyn_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ tfi_assignment := ");
single_value->field_tfi__assignment.log();
TTCN_Logger::log_event_str(", polling := ");
single_value->field_polling.log();
TTCN_Logger::log_event_str(", spare := ");
single_value->field_spare.log();
TTCN_Logger::log_event_str(", usf := ");
single_value->field_usf.log();
TTCN_Logger::log_event_str(", usf_granularity := ");
single_value->field_usf__granularity.log();
TTCN_Logger::log_event_str(", p0_present := ");
single_value->field_p0__present.log();
TTCN_Logger::log_event_str(", p0 := ");
single_value->field_p0.log();
TTCN_Logger::log_event_str(", pr_mode := ");
single_value->field_pr__mode.log();
TTCN_Logger::log_event_str(", egprs_ch_coding_cmd := ");
single_value->field_egprs__ch__coding__cmd.log();
TTCN_Logger::log_event_str(", tlli_block_chan_coding := ");
single_value->field_tlli__block__chan__coding.log();
TTCN_Logger::log_event_str(", bep_period2_present := ");
single_value->field_bep__period2__present.log();
TTCN_Logger::log_event_str(", bep_period2 := ");
single_value->field_bep__period2.log();
TTCN_Logger::log_event_str(", resegment := ");
single_value->field_resegment.log();
TTCN_Logger::log_event_str(", egprs_window_size := ");
single_value->field_egprs__window__size.log();
TTCN_Logger::log_event_str(", alpha_present := ");
single_value->field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
single_value->field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log();
TTCN_Logger::log_event_str(", ta_index_present := ");
single_value->field_ta__index__present.log();
TTCN_Logger::log_event_str(", ta_index := ");
single_value->field_ta__index.log();
TTCN_Logger::log_event_str(", tbf_starting_time_present := ");
single_value->field_tbf__starting__time__present.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
single_value->field_tbf__starting__time.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void EgprsUlAssignDyn_template::log_match(const EgprsUlAssignDyn& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_tfi__assignment.match(match_value.tfi__assignment(), legacy)){
TTCN_Logger::log_logmatch_info(".tfi_assignment");
single_value->field_tfi__assignment.log_match(match_value.tfi__assignment(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_polling.match(match_value.polling(), legacy)){
TTCN_Logger::log_logmatch_info(".polling");
single_value->field_polling.log_match(match_value.polling(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_spare.match(match_value.spare(), legacy)){
TTCN_Logger::log_logmatch_info(".spare");
single_value->field_spare.log_match(match_value.spare(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_usf.match(match_value.usf(), legacy)){
TTCN_Logger::log_logmatch_info(".usf");
single_value->field_usf.log_match(match_value.usf(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_usf__granularity.match(match_value.usf__granularity(), legacy)){
TTCN_Logger::log_logmatch_info(".usf_granularity");
single_value->field_usf__granularity.log_match(match_value.usf__granularity(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_p0__present.match(match_value.p0__present(), legacy)){
TTCN_Logger::log_logmatch_info(".p0_present");
single_value->field_p0__present.log_match(match_value.p0__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.p0().ispresent()){
if(!single_value->field_p0.match(match_value.p0(), legacy)){
TTCN_Logger::log_logmatch_info(".p0");
single_value->field_p0.log_match(match_value.p0(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_p0.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".p0 := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_p0.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.pr__mode().ispresent()){
if(!single_value->field_pr__mode.match(match_value.pr__mode(), legacy)){
TTCN_Logger::log_logmatch_info(".pr_mode");
single_value->field_pr__mode.log_match(match_value.pr__mode(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_pr__mode.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".pr_mode := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_pr__mode.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_egprs__ch__coding__cmd.match(match_value.egprs__ch__coding__cmd(), legacy)){
TTCN_Logger::log_logmatch_info(".egprs_ch_coding_cmd");
single_value->field_egprs__ch__coding__cmd.log_match(match_value.egprs__ch__coding__cmd(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_tlli__block__chan__coding.match(match_value.tlli__block__chan__coding(), legacy)){
TTCN_Logger::log_logmatch_info(".tlli_block_chan_coding");
single_value->field_tlli__block__chan__coding.log_match(match_value.tlli__block__chan__coding(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_bep__period2__present.match(match_value.bep__period2__present(), legacy)){
TTCN_Logger::log_logmatch_info(".bep_period2_present");
single_value->field_bep__period2__present.log_match(match_value.bep__period2__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.bep__period2().ispresent()){
if(!single_value->field_bep__period2.match(match_value.bep__period2(), legacy)){
TTCN_Logger::log_logmatch_info(".bep_period2");
single_value->field_bep__period2.log_match(match_value.bep__period2(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_bep__period2.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".bep_period2 := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_bep__period2.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_resegment.match(match_value.resegment(), legacy)){
TTCN_Logger::log_logmatch_info(".resegment");
single_value->field_resegment.log_match(match_value.resegment(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_egprs__window__size.match(match_value.egprs__window__size(), legacy)){
TTCN_Logger::log_logmatch_info(".egprs_window_size");
single_value->field_egprs__window__size.log_match(match_value.egprs__window__size(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_alpha__present.match(match_value.alpha__present(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha_present");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.alpha().ispresent()){
if(!single_value->field_alpha.match(match_value.alpha(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha");
single_value->field_alpha.log_match(match_value.alpha(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_alpha.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".alpha := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_alpha.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_gamma.match(match_value.gamma(), legacy)){
TTCN_Logger::log_logmatch_info(".gamma");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_ta__index__present.match(match_value.ta__index__present(), legacy)){
TTCN_Logger::log_logmatch_info(".ta_index_present");
single_value->field_ta__index__present.log_match(match_value.ta__index__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.ta__index().ispresent()){
if(!single_value->field_ta__index.match(match_value.ta__index(), legacy)){
TTCN_Logger::log_logmatch_info(".ta_index");
single_value->field_ta__index.log_match(match_value.ta__index(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_ta__index.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".ta_index := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_ta__index.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_tbf__starting__time__present.match(match_value.tbf__starting__time__present(), legacy)){
TTCN_Logger::log_logmatch_info(".tbf_starting_time_present");
single_value->field_tbf__starting__time__present.log_match(match_value.tbf__starting__time__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.tbf__starting__time().ispresent()){
if(!single_value->field_tbf__starting__time.match(match_value.tbf__starting__time(), legacy)){
TTCN_Logger::log_logmatch_info(".tbf_starting_time");
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_tbf__starting__time.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".tbf_starting_time := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_tbf__starting__time.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ tfi_assignment := ");
single_value->field_tfi__assignment.log_match(match_value.tfi__assignment(), legacy);
TTCN_Logger::log_event_str(", polling := ");
single_value->field_polling.log_match(match_value.polling(), legacy);
TTCN_Logger::log_event_str(", spare := ");
single_value->field_spare.log_match(match_value.spare(), legacy);
TTCN_Logger::log_event_str(", usf := ");
single_value->field_usf.log_match(match_value.usf(), legacy);
TTCN_Logger::log_event_str(", usf_granularity := ");
single_value->field_usf__granularity.log_match(match_value.usf__granularity(), legacy);
TTCN_Logger::log_event_str(", p0_present := ");
single_value->field_p0__present.log_match(match_value.p0__present(), legacy);
TTCN_Logger::log_event_str(", p0 := ");
if (match_value.p0().ispresent()) {
single_value->field_p0.log_match(match_value.p0(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_p0.log();
if (single_value->field_p0.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", pr_mode := ");
if (match_value.pr__mode().ispresent()) {
single_value->field_pr__mode.log_match(match_value.pr__mode(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_pr__mode.log();
if (single_value->field_pr__mode.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", egprs_ch_coding_cmd := ");
single_value->field_egprs__ch__coding__cmd.log_match(match_value.egprs__ch__coding__cmd(), legacy);
TTCN_Logger::log_event_str(", tlli_block_chan_coding := ");
single_value->field_tlli__block__chan__coding.log_match(match_value.tlli__block__chan__coding(), legacy);
TTCN_Logger::log_event_str(", bep_period2_present := ");
single_value->field_bep__period2__present.log_match(match_value.bep__period2__present(), legacy);
TTCN_Logger::log_event_str(", bep_period2 := ");
if (match_value.bep__period2().ispresent()) {
single_value->field_bep__period2.log_match(match_value.bep__period2(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_bep__period2.log();
if (single_value->field_bep__period2.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", resegment := ");
single_value->field_resegment.log_match(match_value.resegment(), legacy);
TTCN_Logger::log_event_str(", egprs_window_size := ");
single_value->field_egprs__window__size.log_match(match_value.egprs__window__size(), legacy);
TTCN_Logger::log_event_str(", alpha_present := ");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::log_event_str(", alpha := ");
if (match_value.alpha().ispresent()) {
single_value->field_alpha.log_match(match_value.alpha(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_alpha.log();
if (single_value->field_alpha.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::log_event_str(", ta_index_present := ");
single_value->field_ta__index__present.log_match(match_value.ta__index__present(), legacy);
TTCN_Logger::log_event_str(", ta_index := ");
if (match_value.ta__index().ispresent()) {
single_value->field_ta__index.log_match(match_value.ta__index(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_ta__index.log();
if (single_value->field_ta__index.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", tbf_starting_time_present := ");
single_value->field_tbf__starting__time__present.log_match(match_value.tbf__starting__time__present(), legacy);
TTCN_Logger::log_event_str(", tbf_starting_time := ");
if (match_value.tbf__starting__time().ispresent()) {
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_tbf__starting__time.log();
if (single_value->field_tbf__starting__time.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void EgprsUlAssignDyn_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (tfi__assignment().is_bound()) tfi__assignment().set_implicit_omit();
if (polling().is_bound()) polling().set_implicit_omit();
if (spare().is_bound()) spare().set_implicit_omit();
if (usf().is_bound()) usf().set_implicit_omit();
if (usf__granularity().is_bound()) usf__granularity().set_implicit_omit();
if (p0__present().is_bound()) p0__present().set_implicit_omit();
if (!p0().is_bound()) p0() = OMIT_VALUE;
else p0().set_implicit_omit();
if (!pr__mode().is_bound()) pr__mode() = OMIT_VALUE;
else pr__mode().set_implicit_omit();
if (egprs__ch__coding__cmd().is_bound()) egprs__ch__coding__cmd().set_implicit_omit();
if (tlli__block__chan__coding().is_bound()) tlli__block__chan__coding().set_implicit_omit();
if (bep__period2__present().is_bound()) bep__period2__present().set_implicit_omit();
if (!bep__period2().is_bound()) bep__period2() = OMIT_VALUE;
else bep__period2().set_implicit_omit();
if (resegment().is_bound()) resegment().set_implicit_omit();
if (egprs__window__size().is_bound()) egprs__window__size().set_implicit_omit();
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (ta__index__present().is_bound()) ta__index__present().set_implicit_omit();
if (!ta__index().is_bound()) ta__index() = OMIT_VALUE;
else ta__index().set_implicit_omit();
if (tbf__starting__time__present().is_bound()) tbf__starting__time__present().set_implicit_omit();
if (!tbf__starting__time().is_bound()) tbf__starting__time() = OMIT_VALUE;
else tbf__starting__time().set_implicit_omit();
}

void EgprsUlAssignDyn_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_tfi__assignment.encode_text(text_buf);
single_value->field_polling.encode_text(text_buf);
single_value->field_spare.encode_text(text_buf);
single_value->field_usf.encode_text(text_buf);
single_value->field_usf__granularity.encode_text(text_buf);
single_value->field_p0__present.encode_text(text_buf);
single_value->field_p0.encode_text(text_buf);
single_value->field_pr__mode.encode_text(text_buf);
single_value->field_egprs__ch__coding__cmd.encode_text(text_buf);
single_value->field_tlli__block__chan__coding.encode_text(text_buf);
single_value->field_bep__period2__present.encode_text(text_buf);
single_value->field_bep__period2.encode_text(text_buf);
single_value->field_resegment.encode_text(text_buf);
single_value->field_egprs__window__size.encode_text(text_buf);
single_value->field_alpha__present.encode_text(text_buf);
single_value->field_alpha.encode_text(text_buf);
single_value->field_gamma.encode_text(text_buf);
single_value->field_ta__index__present.encode_text(text_buf);
single_value->field_ta__index.encode_text(text_buf);
single_value->field_tbf__starting__time__present.encode_text(text_buf);
single_value->field_tbf__starting__time.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAssignDyn.");
}
}

void EgprsUlAssignDyn_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_tfi__assignment.decode_text(text_buf);
single_value->field_polling.decode_text(text_buf);
single_value->field_spare.decode_text(text_buf);
single_value->field_usf.decode_text(text_buf);
single_value->field_usf__granularity.decode_text(text_buf);
single_value->field_p0__present.decode_text(text_buf);
single_value->field_p0.decode_text(text_buf);
single_value->field_pr__mode.decode_text(text_buf);
single_value->field_egprs__ch__coding__cmd.decode_text(text_buf);
single_value->field_tlli__block__chan__coding.decode_text(text_buf);
single_value->field_bep__period2__present.decode_text(text_buf);
single_value->field_bep__period2.decode_text(text_buf);
single_value->field_resegment.decode_text(text_buf);
single_value->field_egprs__window__size.decode_text(text_buf);
single_value->field_alpha__present.decode_text(text_buf);
single_value->field_alpha.decode_text(text_buf);
single_value->field_gamma.decode_text(text_buf);
single_value->field_ta__index__present.decode_text(text_buf);
single_value->field_ta__index.decode_text(text_buf);
single_value->field_tbf__starting__time__present.decode_text(text_buf);
single_value->field_tbf__starting__time.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new EgprsUlAssignDyn_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.EgprsUlAssignDyn.");
}
}

void EgprsUlAssignDyn_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    EgprsUlAssignDyn_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (21<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.EgprsUlAssignDyn has 21 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) tfi__assignment().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) polling().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) spare().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) usf().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) usf__granularity().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) p0__present().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) p0().set_param(*param.get_elem(6));
    if (param.get_size()>7 && param.get_elem(7)->get_type()!=Module_Param::MP_NotUsed) pr__mode().set_param(*param.get_elem(7));
    if (param.get_size()>8 && param.get_elem(8)->get_type()!=Module_Param::MP_NotUsed) egprs__ch__coding__cmd().set_param(*param.get_elem(8));
    if (param.get_size()>9 && param.get_elem(9)->get_type()!=Module_Param::MP_NotUsed) tlli__block__chan__coding().set_param(*param.get_elem(9));
    if (param.get_size()>10 && param.get_elem(10)->get_type()!=Module_Param::MP_NotUsed) bep__period2__present().set_param(*param.get_elem(10));
    if (param.get_size()>11 && param.get_elem(11)->get_type()!=Module_Param::MP_NotUsed) bep__period2().set_param(*param.get_elem(11));
    if (param.get_size()>12 && param.get_elem(12)->get_type()!=Module_Param::MP_NotUsed) resegment().set_param(*param.get_elem(12));
    if (param.get_size()>13 && param.get_elem(13)->get_type()!=Module_Param::MP_NotUsed) egprs__window__size().set_param(*param.get_elem(13));
    if (param.get_size()>14 && param.get_elem(14)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(14));
    if (param.get_size()>15 && param.get_elem(15)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(15));
    if (param.get_size()>16 && param.get_elem(16)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(16));
    if (param.get_size()>17 && param.get_elem(17)->get_type()!=Module_Param::MP_NotUsed) ta__index__present().set_param(*param.get_elem(17));
    if (param.get_size()>18 && param.get_elem(18)->get_type()!=Module_Param::MP_NotUsed) ta__index().set_param(*param.get_elem(18));
    if (param.get_size()>19 && param.get_elem(19)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time__present().set_param(*param.get_elem(19));
    if (param.get_size()>20 && param.get_elem(20)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(20));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tfi_assignment")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tfi__assignment().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "polling")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          polling().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "spare")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          spare().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "usf")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          usf().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "usf_granularity")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          usf__granularity().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pr_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pr__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "egprs_ch_coding_cmd")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          egprs__ch__coding__cmd().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tlli_block_chan_coding")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tlli__block__chan__coding().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "bep_period2_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          bep__period2__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "bep_period2")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          bep__period2().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "resegment")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          resegment().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "egprs_window_size")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          egprs__window__size().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.EgprsUlAssignDyn: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    EgprsUlAssignDyn_template* precondition = new EgprsUlAssignDyn_template;
    precondition->set_param(*param.get_elem(0));
    EgprsUlAssignDyn_template* implied_template = new EgprsUlAssignDyn_template;
    implied_template->set_param(*param.get_elem(1));
    *this = EgprsUlAssignDyn_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.EgprsUlAssignDyn");
  }
  is_ifpresent = param.get_ifpresent();
}

void EgprsUlAssignDyn_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_tfi__assignment.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_polling.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_spare.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_usf.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_usf__granularity.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_p0__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_p0.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_pr__mode.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_egprs__ch__coding__cmd.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_tlli__block__chan__coding.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_bep__period2__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_bep__period2.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_resegment.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_egprs__window__size.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_alpha__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_alpha.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_gamma.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_ta__index__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_ta__index.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_tbf__starting__time__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
single_value->field_tbf__starting__time.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignDyn");
}

boolean EgprsUlAssignDyn_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean EgprsUlAssignDyn_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

TbfStartingTime::TbfStartingTime()
{
}

TbfStartingTime::TbfStartingTime(const INTEGER& par_t1,
    const INTEGER& par_t3,
    const INTEGER& par_t2)
  :   field_t1(par_t1),
  field_t3(par_t3),
  field_t2(par_t2)
{
}

TbfStartingTime::TbfStartingTime(const TbfStartingTime& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.TbfStartingTime.");
if (other_value.t1().is_bound()) field_t1 = other_value.t1();
else field_t1.clean_up();
if (other_value.t3().is_bound()) field_t3 = other_value.t3();
else field_t3.clean_up();
if (other_value.t2().is_bound()) field_t2 = other_value.t2();
else field_t2.clean_up();
}

void TbfStartingTime::clean_up()
{
field_t1.clean_up();
field_t3.clean_up();
field_t2.clean_up();
}

const TTCN_Typedescriptor_t* TbfStartingTime::get_descriptor() const { return &TbfStartingTime_descr_; }
TbfStartingTime& TbfStartingTime::operator=(const TbfStartingTime& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.TbfStartingTime.");
  if (other_value.t1().is_bound()) field_t1 = other_value.t1();
  else field_t1.clean_up();
  if (other_value.t3().is_bound()) field_t3 = other_value.t3();
  else field_t3.clean_up();
  if (other_value.t2().is_bound()) field_t2 = other_value.t2();
  else field_t2.clean_up();
}
return *this;
}

boolean TbfStartingTime::operator==(const TbfStartingTime& other_value) const
{
return field_t1==other_value.field_t1
  && field_t3==other_value.field_t3
  && field_t2==other_value.field_t2;
}

boolean TbfStartingTime::is_bound() const
{
return (field_t1.is_bound())
  || (field_t3.is_bound())
  || (field_t2.is_bound());
}
boolean TbfStartingTime::is_value() const
{
return field_t1.is_value()
  && field_t3.is_value()
  && field_t2.is_value();
}
void TbfStartingTime::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ t1 := ");
field_t1.log();
TTCN_Logger::log_event_str(", t3 := ");
field_t3.log();
TTCN_Logger::log_event_str(", t2 := ");
field_t2.log();
TTCN_Logger::log_event_str(" }");
}

void TbfStartingTime::set_implicit_omit()
{
if (t1().is_bound()) t1().set_implicit_omit();
if (t3().is_bound()) t3().set_implicit_omit();
if (t2().is_bound()) t2().set_implicit_omit();
}

void TbfStartingTime::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.TbfStartingTime has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) t1().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) t3().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) t2().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "t1")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          t1().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "t3")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          t3().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "t2")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          t2().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.TbfStartingTime: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.TbfStartingTime");
  }
}

void TbfStartingTime::encode_text(Text_Buf& text_buf) const
{
field_t1.encode_text(text_buf);
field_t3.encode_text(text_buf);
field_t2.encode_text(text_buf);
}

void TbfStartingTime::decode_text(Text_Buf& text_buf)
{
field_t1.decode_text(text_buf);
field_t3.decode_text(text_buf);
field_t2.decode_text(text_buf);
}

void TbfStartingTime::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void TbfStartingTime::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int TbfStartingTime::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, TbfStartingTime_t1_descr_.raw->forceomit);
  decoded_field_length = field_t1.RAW_decode(TbfStartingTime_t1_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_1_force_omit(1, force_omit, TbfStartingTime_t3_descr_.raw->forceomit);
  decoded_field_length = field_t3.RAW_decode(TbfStartingTime_t3_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_2_force_omit(2, force_omit, TbfStartingTime_t2_descr_.raw->forceomit);
  decoded_field_length = field_t2.RAW_decode(TbfStartingTime_t2_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int TbfStartingTime::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 3;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(3);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, TbfStartingTime_t1_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, TbfStartingTime_t3_descr_.raw);
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, TbfStartingTime_t2_descr_.raw);
  encoded_length += field_t1.RAW_encode(TbfStartingTime_t1_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_t3.RAW_encode(TbfStartingTime_t3_descr_, *myleaf.body.node.nodes[1]);
  encoded_length += field_t2.RAW_encode(TbfStartingTime_t2_descr_, *myleaf.body.node.nodes[2]);
  return myleaf.length = encoded_length;
}

struct TbfStartingTime_template::single_value_struct {
INTEGER_template field_t1;
INTEGER_template field_t3;
INTEGER_template field_t2;
};

void TbfStartingTime_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_t1 = ANY_VALUE;
single_value->field_t3 = ANY_VALUE;
single_value->field_t2 = ANY_VALUE;
}
}
}

void TbfStartingTime_template::copy_value(const TbfStartingTime& other_value)
{
single_value = new single_value_struct;
if (other_value.t1().is_bound()) {
  single_value->field_t1 = other_value.t1();
} else {
  single_value->field_t1.clean_up();
}
if (other_value.t3().is_bound()) {
  single_value->field_t3 = other_value.t3();
} else {
  single_value->field_t3.clean_up();
}
if (other_value.t2().is_bound()) {
  single_value->field_t2 = other_value.t2();
} else {
  single_value->field_t2.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void TbfStartingTime_template::copy_template(const TbfStartingTime_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.t1().get_selection()) {
single_value->field_t1 = other_value.t1();
} else {
single_value->field_t1.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.t3().get_selection()) {
single_value->field_t3 = other_value.t3();
} else {
single_value->field_t3.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.t2().get_selection()) {
single_value->field_t2 = other_value.t2();
} else {
single_value->field_t2.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new TbfStartingTime_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new TbfStartingTime_template(*other_value.implication_.precondition);
implication_.implied_template = new TbfStartingTime_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.TbfStartingTime.");
break;
}
set_selection(other_value);
}

TbfStartingTime_template::TbfStartingTime_template()
{
}

TbfStartingTime_template::TbfStartingTime_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

TbfStartingTime_template::TbfStartingTime_template(const TbfStartingTime& other_value)
{
copy_value(other_value);
}

TbfStartingTime_template::TbfStartingTime_template(const OPTIONAL<TbfStartingTime>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const TbfStartingTime&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.TbfStartingTime from an unbound optional field.");
}
}

TbfStartingTime_template::TbfStartingTime_template(TbfStartingTime_template* p_precondition, TbfStartingTime_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

TbfStartingTime_template::TbfStartingTime_template(Dynamic_Match_Interface<TbfStartingTime>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<TbfStartingTime>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

TbfStartingTime_template::TbfStartingTime_template(const TbfStartingTime_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

TbfStartingTime_template::~TbfStartingTime_template()
{
clean_up();
}

TbfStartingTime_template& TbfStartingTime_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

TbfStartingTime_template& TbfStartingTime_template::operator=(const TbfStartingTime& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

TbfStartingTime_template& TbfStartingTime_template::operator=(const OPTIONAL<TbfStartingTime>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const TbfStartingTime&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.TbfStartingTime.");
}
return *this;
}

TbfStartingTime_template& TbfStartingTime_template::operator=(const TbfStartingTime_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean TbfStartingTime_template::match(const TbfStartingTime& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.t1().is_bound()) return FALSE;
if(!single_value->field_t1.match(other_value.t1(), legacy))return FALSE;
if(!other_value.t3().is_bound()) return FALSE;
if(!single_value->field_t3.match(other_value.t3(), legacy))return FALSE;
if(!other_value.t2().is_bound()) return FALSE;
if(!single_value->field_t2.match(other_value.t2(), legacy))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.TbfStartingTime.");
}
return FALSE;
}

boolean TbfStartingTime_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_t1.is_bound()
 || single_value->field_t3.is_bound()
 || single_value->field_t2.is_bound();
}

boolean TbfStartingTime_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_t1.is_value()
 && single_value->field_t3.is_value()
 && single_value->field_t2.is_value();
}

void TbfStartingTime_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

TbfStartingTime TbfStartingTime_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.TbfStartingTime.");
TbfStartingTime ret_val;
if (single_value->field_t1.is_bound()) {
ret_val.t1() = single_value->field_t1.valueof();
}
if (single_value->field_t3.is_bound()) {
ret_val.t3() = single_value->field_t3.valueof();
}
if (single_value->field_t2.is_bound()) {
ret_val.t2() = single_value->field_t2.valueof();
}
return ret_val;
}

void TbfStartingTime_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.TbfStartingTime.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new TbfStartingTime_template[list_length];
}

TbfStartingTime_template& TbfStartingTime_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.TbfStartingTime.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.TbfStartingTime.");
return value_list.list_value[list_index];
}

INTEGER_template& TbfStartingTime_template::t1()
{
set_specific();
return single_value->field_t1;
}

const INTEGER_template& TbfStartingTime_template::t1() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field t1 of a non-specific template of type @GSM_RestOctets.TbfStartingTime.");
return single_value->field_t1;
}

INTEGER_template& TbfStartingTime_template::t3()
{
set_specific();
return single_value->field_t3;
}

const INTEGER_template& TbfStartingTime_template::t3() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field t3 of a non-specific template of type @GSM_RestOctets.TbfStartingTime.");
return single_value->field_t3;
}

INTEGER_template& TbfStartingTime_template::t2()
{
set_specific();
return single_value->field_t2;
}

const INTEGER_template& TbfStartingTime_template::t2() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field t2 of a non-specific template of type @GSM_RestOctets.TbfStartingTime.");
return single_value->field_t2;
}

int TbfStartingTime_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.TbfStartingTime which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
    return 3;
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.TbfStartingTime containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.TbfStartingTime containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.TbfStartingTime containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.TbfStartingTime containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.TbfStartingTime containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.TbfStartingTime containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.TbfStartingTime containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.TbfStartingTime containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.TbfStartingTime.");
  }
  return 0;
}

void TbfStartingTime_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ t1 := ");
single_value->field_t1.log();
TTCN_Logger::log_event_str(", t3 := ");
single_value->field_t3.log();
TTCN_Logger::log_event_str(", t2 := ");
single_value->field_t2.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void TbfStartingTime_template::log_match(const TbfStartingTime& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_t1.match(match_value.t1(), legacy)){
TTCN_Logger::log_logmatch_info(".t1");
single_value->field_t1.log_match(match_value.t1(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_t3.match(match_value.t3(), legacy)){
TTCN_Logger::log_logmatch_info(".t3");
single_value->field_t3.log_match(match_value.t3(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_t2.match(match_value.t2(), legacy)){
TTCN_Logger::log_logmatch_info(".t2");
single_value->field_t2.log_match(match_value.t2(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ t1 := ");
single_value->field_t1.log_match(match_value.t1(), legacy);
TTCN_Logger::log_event_str(", t3 := ");
single_value->field_t3.log_match(match_value.t3(), legacy);
TTCN_Logger::log_event_str(", t2 := ");
single_value->field_t2.log_match(match_value.t2(), legacy);
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void TbfStartingTime_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (t1().is_bound()) t1().set_implicit_omit();
if (t3().is_bound()) t3().set_implicit_omit();
if (t2().is_bound()) t2().set_implicit_omit();
}

void TbfStartingTime_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_t1.encode_text(text_buf);
single_value->field_t3.encode_text(text_buf);
single_value->field_t2.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.TbfStartingTime.");
}
}

void TbfStartingTime_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_t1.decode_text(text_buf);
single_value->field_t3.decode_text(text_buf);
single_value->field_t2.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new TbfStartingTime_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.TbfStartingTime.");
}
}

void TbfStartingTime_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    TbfStartingTime_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.TbfStartingTime has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) t1().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) t3().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) t2().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "t1")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          t1().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "t3")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          t3().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "t2")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          t2().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.TbfStartingTime: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    TbfStartingTime_template* precondition = new TbfStartingTime_template;
    precondition->set_param(*param.get_elem(0));
    TbfStartingTime_template* implied_template = new TbfStartingTime_template;
    implied_template->set_param(*param.get_elem(1));
    *this = TbfStartingTime_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.TbfStartingTime");
  }
  is_ifpresent = param.get_ifpresent();
}

void TbfStartingTime_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_t1.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.TbfStartingTime");
single_value->field_t3.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.TbfStartingTime");
single_value->field_t2.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.TbfStartingTime");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.TbfStartingTime");
}

boolean TbfStartingTime_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean TbfStartingTime_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

EgprsUlAssignMultiblock::EgprsUlAssignMultiblock()
{
}

EgprsUlAssignMultiblock::EgprsUlAssignMultiblock(const BITSTRING& par_alpha__present,
    const OPTIONAL< INTEGER >& par_alpha,
    const INTEGER& par_gamma,
    const TbfStartingTime& par_tbf__starting__time,
    const BITSTRING& par_nr__radio__blocks__allocated,
    const BITSTRING& par_p0__present,
    const OPTIONAL< INTEGER >& par_p0,
    const OPTIONAL< BITSTRING >& par_spare,
    const OPTIONAL< BITSTRING >& par_pr__mode)
  :   field_alpha__present(par_alpha__present),
  field_alpha(par_alpha),
  field_gamma(par_gamma),
  field_tbf__starting__time(par_tbf__starting__time),
  field_nr__radio__blocks__allocated(par_nr__radio__blocks__allocated),
  field_p0__present(par_p0__present),
  field_p0(par_p0),
  field_spare(par_spare),
  field_pr__mode(par_pr__mode)
{
}

EgprsUlAssignMultiblock::EgprsUlAssignMultiblock(const EgprsUlAssignMultiblock& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
else field_alpha__present.clean_up();
if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
else field_alpha.clean_up();
if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
else field_gamma.clean_up();
if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
else field_tbf__starting__time.clean_up();
if (other_value.nr__radio__blocks__allocated().is_bound()) field_nr__radio__blocks__allocated = other_value.nr__radio__blocks__allocated();
else field_nr__radio__blocks__allocated.clean_up();
if (other_value.p0__present().is_bound()) field_p0__present = other_value.p0__present();
else field_p0__present.clean_up();
if (other_value.p0().is_bound()) field_p0 = other_value.p0();
else field_p0.clean_up();
if (other_value.spare().is_bound()) field_spare = other_value.spare();
else field_spare.clean_up();
if (other_value.pr__mode().is_bound()) field_pr__mode = other_value.pr__mode();
else field_pr__mode.clean_up();
}

void EgprsUlAssignMultiblock::clean_up()
{
field_alpha__present.clean_up();
field_alpha.clean_up();
field_gamma.clean_up();
field_tbf__starting__time.clean_up();
field_nr__radio__blocks__allocated.clean_up();
field_p0__present.clean_up();
field_p0.clean_up();
field_spare.clean_up();
field_pr__mode.clean_up();
}

const TTCN_Typedescriptor_t* EgprsUlAssignMultiblock::get_descriptor() const { return &EgprsUlAssignMultiblock_descr_; }
EgprsUlAssignMultiblock& EgprsUlAssignMultiblock::operator=(const EgprsUlAssignMultiblock& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
  if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
  else field_alpha__present.clean_up();
  if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
  else field_alpha.clean_up();
  if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
  else field_gamma.clean_up();
  if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
  else field_tbf__starting__time.clean_up();
  if (other_value.nr__radio__blocks__allocated().is_bound()) field_nr__radio__blocks__allocated = other_value.nr__radio__blocks__allocated();
  else field_nr__radio__blocks__allocated.clean_up();
  if (other_value.p0__present().is_bound()) field_p0__present = other_value.p0__present();
  else field_p0__present.clean_up();
  if (other_value.p0().is_bound()) field_p0 = other_value.p0();
  else field_p0.clean_up();
  if (other_value.spare().is_bound()) field_spare = other_value.spare();
  else field_spare.clean_up();
  if (other_value.pr__mode().is_bound()) field_pr__mode = other_value.pr__mode();
  else field_pr__mode.clean_up();
}
return *this;
}

boolean EgprsUlAssignMultiblock::operator==(const EgprsUlAssignMultiblock& other_value) const
{
return field_alpha__present==other_value.field_alpha__present
  && field_alpha==other_value.field_alpha
  && field_gamma==other_value.field_gamma
  && field_tbf__starting__time==other_value.field_tbf__starting__time
  && field_nr__radio__blocks__allocated==other_value.field_nr__radio__blocks__allocated
  && field_p0__present==other_value.field_p0__present
  && field_p0==other_value.field_p0
  && field_spare==other_value.field_spare
  && field_pr__mode==other_value.field_pr__mode;
}

boolean EgprsUlAssignMultiblock::is_bound() const
{
return (field_alpha__present.is_bound())
  || (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_bound())
  || (field_gamma.is_bound())
  || (field_tbf__starting__time.is_bound())
  || (field_nr__radio__blocks__allocated.is_bound())
  || (field_p0__present.is_bound())
  || (OPTIONAL_OMIT == field_p0.get_selection() || field_p0.is_bound())
  || (OPTIONAL_OMIT == field_spare.get_selection() || field_spare.is_bound())
  || (OPTIONAL_OMIT == field_pr__mode.get_selection() || field_pr__mode.is_bound());
}
boolean EgprsUlAssignMultiblock::is_value() const
{
return field_alpha__present.is_value()
  && (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_value())
  && field_gamma.is_value()
  && field_tbf__starting__time.is_value()
  && field_nr__radio__blocks__allocated.is_value()
  && field_p0__present.is_value()
  && (OPTIONAL_OMIT == field_p0.get_selection() || field_p0.is_value())
  && (OPTIONAL_OMIT == field_spare.get_selection() || field_spare.is_value())
  && (OPTIONAL_OMIT == field_pr__mode.get_selection() || field_pr__mode.is_value());
}
int EgprsUlAssignMultiblock::size_of() const
{
  int ret_val = 5;
  if (field_alpha.ispresent()) ret_val++;
  if (field_p0.ispresent()) ret_val++;
  if (field_spare.ispresent()) ret_val++;
  if (field_pr__mode.ispresent()) ret_val++;
  return ret_val;
}

void EgprsUlAssignMultiblock::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ alpha_present := ");
field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
field_gamma.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
field_tbf__starting__time.log();
TTCN_Logger::log_event_str(", nr_radio_blocks_allocated := ");
field_nr__radio__blocks__allocated.log();
TTCN_Logger::log_event_str(", p0_present := ");
field_p0__present.log();
TTCN_Logger::log_event_str(", p0 := ");
field_p0.log();
TTCN_Logger::log_event_str(", spare := ");
field_spare.log();
TTCN_Logger::log_event_str(", pr_mode := ");
field_pr__mode.log();
TTCN_Logger::log_event_str(" }");
}

void EgprsUlAssignMultiblock::set_implicit_omit()
{
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (tbf__starting__time().is_bound()) tbf__starting__time().set_implicit_omit();
if (nr__radio__blocks__allocated().is_bound()) nr__radio__blocks__allocated().set_implicit_omit();
if (p0__present().is_bound()) p0__present().set_implicit_omit();
if (!p0().is_bound()) p0() = OMIT_VALUE;
else p0().set_implicit_omit();
if (!spare().is_bound()) spare() = OMIT_VALUE;
else spare().set_implicit_omit();
if (!pr__mode().is_bound()) pr__mode() = OMIT_VALUE;
else pr__mode().set_implicit_omit();
}

void EgprsUlAssignMultiblock::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (9<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.EgprsUlAssignMultiblock has 9 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) nr__radio__blocks__allocated().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) p0__present().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) p0().set_param(*param.get_elem(6));
    if (param.get_size()>7 && param.get_elem(7)->get_type()!=Module_Param::MP_NotUsed) spare().set_param(*param.get_elem(7));
    if (param.get_size()>8 && param.get_elem(8)->get_type()!=Module_Param::MP_NotUsed) pr__mode().set_param(*param.get_elem(8));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "nr_radio_blocks_allocated")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          nr__radio__blocks__allocated().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "spare")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          spare().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pr_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pr__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.EgprsUlAssignMultiblock: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.EgprsUlAssignMultiblock");
  }
}

void EgprsUlAssignMultiblock::encode_text(Text_Buf& text_buf) const
{
field_alpha__present.encode_text(text_buf);
field_alpha.encode_text(text_buf);
field_gamma.encode_text(text_buf);
field_tbf__starting__time.encode_text(text_buf);
field_nr__radio__blocks__allocated.encode_text(text_buf);
field_p0__present.encode_text(text_buf);
field_p0.encode_text(text_buf);
field_spare.encode_text(text_buf);
field_pr__mode.encode_text(text_buf);
}

void EgprsUlAssignMultiblock::decode_text(Text_Buf& text_buf)
{
field_alpha__present.decode_text(text_buf);
field_alpha.decode_text(text_buf);
field_gamma.decode_text(text_buf);
field_tbf__starting__time.decode_text(text_buf);
field_nr__radio__blocks__allocated.decode_text(text_buf);
field_p0__present.decode_text(text_buf);
field_p0.decode_text(text_buf);
field_spare.decode_text(text_buf);
field_pr__mode.decode_text(text_buf);
}

void EgprsUlAssignMultiblock::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void EgprsUlAssignMultiblock::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int EgprsUlAssignMultiblock::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, EgprsUlAssignMultiblock_alpha__present_descr_.raw->forceomit);
  decoded_field_length = field_alpha__present.RAW_decode(EgprsUlAssignMultiblock_alpha__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_alpha__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_alpha = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, EgprsUlAssignMultiblock_alpha_descr_.raw->forceomit);
  decoded_field_length = field_alpha().RAW_decode(EgprsUlAssignMultiblock_alpha_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_alpha = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_alpha=OMIT_VALUE;
  RAW_Force_Omit field_2_force_omit(2, force_omit, EgprsUlAssignMultiblock_gamma_descr_.raw->forceomit);
  decoded_field_length = field_gamma.RAW_decode(EgprsUlAssignMultiblock_gamma_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_3_force_omit(3, force_omit, EgprsUlAssignMultiblock_tbf__starting__time_descr_.raw->forceomit);
  decoded_field_length = field_tbf__starting__time.RAW_decode(EgprsUlAssignMultiblock_tbf__starting__time_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_3_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_4_force_omit(4, force_omit, EgprsUlAssignMultiblock_nr__radio__blocks__allocated_descr_.raw->forceomit);
  decoded_field_length = field_nr__radio__blocks__allocated.RAW_decode(EgprsUlAssignMultiblock_nr__radio__blocks__allocated_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_4_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_5_force_omit(5, force_omit, EgprsUlAssignMultiblock_p0__present_descr_.raw->forceomit);
  decoded_field_length = field_p0__present.RAW_decode(EgprsUlAssignMultiblock_p0__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_5_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_p0__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(6)) {
    field_p0 = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_6_force_omit(6, force_omit, EgprsUlAssignMultiblock_p0_descr_.raw->forceomit);
  decoded_field_length = field_p0().RAW_decode(EgprsUlAssignMultiblock_p0_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_6_force_omit);
  if (decoded_field_length < 1) {
  field_p0 = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_p0=OMIT_VALUE;
  if (limit > 0 && field_p0__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(7)) {
    field_spare = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_7_force_omit(7, force_omit, EgprsUlAssignMultiblock_spare_descr_.raw->forceomit);
  decoded_field_length = field_spare().RAW_decode(EgprsUlAssignMultiblock_spare_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_7_force_omit);
  if (decoded_field_length < 1) {
  field_spare = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_spare=OMIT_VALUE;
  if (limit > 0 && field_p0__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(8)) {
    field_pr__mode = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_8_force_omit(8, force_omit, EgprsUlAssignMultiblock_pr__mode_descr_.raw->forceomit);
  decoded_field_length = field_pr__mode().RAW_decode(EgprsUlAssignMultiblock_pr__mode_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_8_force_omit);
  if (decoded_field_length < 1) {
  field_pr__mode = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_pr__mode=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int EgprsUlAssignMultiblock::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 9;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(9);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, EgprsUlAssignMultiblock_alpha__present_descr_.raw);
  if (field_alpha.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, EgprsUlAssignMultiblock_alpha_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, EgprsUlAssignMultiblock_gamma_descr_.raw);
  myleaf.body.node.nodes[3] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 3, EgprsUlAssignMultiblock_tbf__starting__time_descr_.raw);
  myleaf.body.node.nodes[4] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 4, EgprsUlAssignMultiblock_nr__radio__blocks__allocated_descr_.raw);
  myleaf.body.node.nodes[5] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 5, EgprsUlAssignMultiblock_p0__present_descr_.raw);
  if (field_p0.ispresent()) {
  myleaf.body.node.nodes[6] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 6, EgprsUlAssignMultiblock_p0_descr_.raw);
  }
  else myleaf.body.node.nodes[6] = NULL;
  if (field_spare.ispresent()) {
  myleaf.body.node.nodes[7] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 7, EgprsUlAssignMultiblock_spare_descr_.raw);
  }
  else myleaf.body.node.nodes[7] = NULL;
  if (field_pr__mode.ispresent()) {
  myleaf.body.node.nodes[8] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 8, EgprsUlAssignMultiblock_pr__mode_descr_.raw);
  }
  else myleaf.body.node.nodes[8] = NULL;
  encoded_length += field_alpha__present.RAW_encode(EgprsUlAssignMultiblock_alpha__present_descr_, *myleaf.body.node.nodes[0]);
  if (field_alpha.ispresent()) {
  encoded_length += field_alpha().RAW_encode(EgprsUlAssignMultiblock_alpha_descr_, *myleaf.body.node.nodes[1]);
  }
  encoded_length += field_gamma.RAW_encode(EgprsUlAssignMultiblock_gamma_descr_, *myleaf.body.node.nodes[2]);
  encoded_length += field_tbf__starting__time.RAW_encode(EgprsUlAssignMultiblock_tbf__starting__time_descr_, *myleaf.body.node.nodes[3]);
  encoded_length += field_nr__radio__blocks__allocated.RAW_encode(EgprsUlAssignMultiblock_nr__radio__blocks__allocated_descr_, *myleaf.body.node.nodes[4]);
  encoded_length += field_p0__present.RAW_encode(EgprsUlAssignMultiblock_p0__present_descr_, *myleaf.body.node.nodes[5]);
  if (field_p0.ispresent()) {
  encoded_length += field_p0().RAW_encode(EgprsUlAssignMultiblock_p0_descr_, *myleaf.body.node.nodes[6]);
  }
  if (field_spare.ispresent()) {
  encoded_length += field_spare().RAW_encode(EgprsUlAssignMultiblock_spare_descr_, *myleaf.body.node.nodes[7]);
  }
  if (field_pr__mode.ispresent()) {
  encoded_length += field_pr__mode().RAW_encode(EgprsUlAssignMultiblock_pr__mode_descr_, *myleaf.body.node.nodes[8]);
  }
  if (field_alpha.ispresent() && (field_alpha__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignMultiblock_alpha__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_p0.ispresent() && (field_p0__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={5};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignMultiblock_p0__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_spare.ispresent() && (field_p0__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={5};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignMultiblock_p0__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_pr__mode.ispresent() && (field_p0__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={5};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(EgprsUlAssignMultiblock_p0__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct EgprsUlAssignMultiblock_template::single_value_struct {
BITSTRING_template field_alpha__present;
INTEGER_template field_alpha;
INTEGER_template field_gamma;
TbfStartingTime_template field_tbf__starting__time;
BITSTRING_template field_nr__radio__blocks__allocated;
BITSTRING_template field_p0__present;
INTEGER_template field_p0;
BITSTRING_template field_spare;
BITSTRING_template field_pr__mode;
};

void EgprsUlAssignMultiblock_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_alpha__present = ANY_VALUE;
single_value->field_alpha = ANY_OR_OMIT;
single_value->field_gamma = ANY_VALUE;
single_value->field_tbf__starting__time = ANY_VALUE;
single_value->field_nr__radio__blocks__allocated = ANY_VALUE;
single_value->field_p0__present = ANY_VALUE;
single_value->field_p0 = ANY_OR_OMIT;
single_value->field_spare = ANY_OR_OMIT;
single_value->field_pr__mode = ANY_OR_OMIT;
}
}
}

void EgprsUlAssignMultiblock_template::copy_value(const EgprsUlAssignMultiblock& other_value)
{
single_value = new single_value_struct;
if (other_value.alpha__present().is_bound()) {
  single_value->field_alpha__present = other_value.alpha__present();
} else {
  single_value->field_alpha__present.clean_up();
}
if (other_value.alpha().is_bound()) {
  if (other_value.alpha().ispresent()) single_value->field_alpha = other_value.alpha()();
  else single_value->field_alpha = OMIT_VALUE;
} else {
  single_value->field_alpha.clean_up();
}
if (other_value.gamma().is_bound()) {
  single_value->field_gamma = other_value.gamma();
} else {
  single_value->field_gamma.clean_up();
}
if (other_value.tbf__starting__time().is_bound()) {
  single_value->field_tbf__starting__time = other_value.tbf__starting__time();
} else {
  single_value->field_tbf__starting__time.clean_up();
}
if (other_value.nr__radio__blocks__allocated().is_bound()) {
  single_value->field_nr__radio__blocks__allocated = other_value.nr__radio__blocks__allocated();
} else {
  single_value->field_nr__radio__blocks__allocated.clean_up();
}
if (other_value.p0__present().is_bound()) {
  single_value->field_p0__present = other_value.p0__present();
} else {
  single_value->field_p0__present.clean_up();
}
if (other_value.p0().is_bound()) {
  if (other_value.p0().ispresent()) single_value->field_p0 = other_value.p0()();
  else single_value->field_p0 = OMIT_VALUE;
} else {
  single_value->field_p0.clean_up();
}
if (other_value.spare().is_bound()) {
  if (other_value.spare().ispresent()) single_value->field_spare = other_value.spare()();
  else single_value->field_spare = OMIT_VALUE;
} else {
  single_value->field_spare.clean_up();
}
if (other_value.pr__mode().is_bound()) {
  if (other_value.pr__mode().ispresent()) single_value->field_pr__mode = other_value.pr__mode()();
  else single_value->field_pr__mode = OMIT_VALUE;
} else {
  single_value->field_pr__mode.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void EgprsUlAssignMultiblock_template::copy_template(const EgprsUlAssignMultiblock_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.alpha__present().get_selection()) {
single_value->field_alpha__present = other_value.alpha__present();
} else {
single_value->field_alpha__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.alpha().get_selection()) {
single_value->field_alpha = other_value.alpha();
} else {
single_value->field_alpha.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.gamma().get_selection()) {
single_value->field_gamma = other_value.gamma();
} else {
single_value->field_gamma.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tbf__starting__time().get_selection()) {
single_value->field_tbf__starting__time = other_value.tbf__starting__time();
} else {
single_value->field_tbf__starting__time.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.nr__radio__blocks__allocated().get_selection()) {
single_value->field_nr__radio__blocks__allocated = other_value.nr__radio__blocks__allocated();
} else {
single_value->field_nr__radio__blocks__allocated.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.p0__present().get_selection()) {
single_value->field_p0__present = other_value.p0__present();
} else {
single_value->field_p0__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.p0().get_selection()) {
single_value->field_p0 = other_value.p0();
} else {
single_value->field_p0.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.spare().get_selection()) {
single_value->field_spare = other_value.spare();
} else {
single_value->field_spare.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.pr__mode().get_selection()) {
single_value->field_pr__mode = other_value.pr__mode();
} else {
single_value->field_pr__mode.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new EgprsUlAssignMultiblock_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new EgprsUlAssignMultiblock_template(*other_value.implication_.precondition);
implication_.implied_template = new EgprsUlAssignMultiblock_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
break;
}
set_selection(other_value);
}

EgprsUlAssignMultiblock_template::EgprsUlAssignMultiblock_template()
{
}

EgprsUlAssignMultiblock_template::EgprsUlAssignMultiblock_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

EgprsUlAssignMultiblock_template::EgprsUlAssignMultiblock_template(const EgprsUlAssignMultiblock& other_value)
{
copy_value(other_value);
}

EgprsUlAssignMultiblock_template::EgprsUlAssignMultiblock_template(const OPTIONAL<EgprsUlAssignMultiblock>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const EgprsUlAssignMultiblock&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.EgprsUlAssignMultiblock from an unbound optional field.");
}
}

EgprsUlAssignMultiblock_template::EgprsUlAssignMultiblock_template(EgprsUlAssignMultiblock_template* p_precondition, EgprsUlAssignMultiblock_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

EgprsUlAssignMultiblock_template::EgprsUlAssignMultiblock_template(Dynamic_Match_Interface<EgprsUlAssignMultiblock>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<EgprsUlAssignMultiblock>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

EgprsUlAssignMultiblock_template::EgprsUlAssignMultiblock_template(const EgprsUlAssignMultiblock_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

EgprsUlAssignMultiblock_template::~EgprsUlAssignMultiblock_template()
{
clean_up();
}

EgprsUlAssignMultiblock_template& EgprsUlAssignMultiblock_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

EgprsUlAssignMultiblock_template& EgprsUlAssignMultiblock_template::operator=(const EgprsUlAssignMultiblock& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

EgprsUlAssignMultiblock_template& EgprsUlAssignMultiblock_template::operator=(const OPTIONAL<EgprsUlAssignMultiblock>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const EgprsUlAssignMultiblock&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
}
return *this;
}

EgprsUlAssignMultiblock_template& EgprsUlAssignMultiblock_template::operator=(const EgprsUlAssignMultiblock_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean EgprsUlAssignMultiblock_template::match(const EgprsUlAssignMultiblock& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.alpha__present().is_bound()) return FALSE;
if(!single_value->field_alpha__present.match(other_value.alpha__present(), legacy))return FALSE;
if(!other_value.alpha().is_bound()) return FALSE;
if((other_value.alpha().ispresent() ? !single_value->field_alpha.match((const INTEGER&)other_value.alpha(), legacy) : !single_value->field_alpha.match_omit(legacy)))return FALSE;
if(!other_value.gamma().is_bound()) return FALSE;
if(!single_value->field_gamma.match(other_value.gamma(), legacy))return FALSE;
if(!other_value.tbf__starting__time().is_bound()) return FALSE;
if(!single_value->field_tbf__starting__time.match(other_value.tbf__starting__time(), legacy))return FALSE;
if(!other_value.nr__radio__blocks__allocated().is_bound()) return FALSE;
if(!single_value->field_nr__radio__blocks__allocated.match(other_value.nr__radio__blocks__allocated(), legacy))return FALSE;
if(!other_value.p0__present().is_bound()) return FALSE;
if(!single_value->field_p0__present.match(other_value.p0__present(), legacy))return FALSE;
if(!other_value.p0().is_bound()) return FALSE;
if((other_value.p0().ispresent() ? !single_value->field_p0.match((const INTEGER&)other_value.p0(), legacy) : !single_value->field_p0.match_omit(legacy)))return FALSE;
if(!other_value.spare().is_bound()) return FALSE;
if((other_value.spare().ispresent() ? !single_value->field_spare.match((const BITSTRING&)other_value.spare(), legacy) : !single_value->field_spare.match_omit(legacy)))return FALSE;
if(!other_value.pr__mode().is_bound()) return FALSE;
if((other_value.pr__mode().ispresent() ? !single_value->field_pr__mode.match((const BITSTRING&)other_value.pr__mode(), legacy) : !single_value->field_pr__mode.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
}
return FALSE;
}

boolean EgprsUlAssignMultiblock_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_alpha__present.is_bound()
 || (single_value->field_alpha.is_omit() || single_value->field_alpha.is_bound())
 || single_value->field_gamma.is_bound()
 || single_value->field_tbf__starting__time.is_bound()
 || single_value->field_nr__radio__blocks__allocated.is_bound()
 || single_value->field_p0__present.is_bound()
 || (single_value->field_p0.is_omit() || single_value->field_p0.is_bound())
 || (single_value->field_spare.is_omit() || single_value->field_spare.is_bound())
 || (single_value->field_pr__mode.is_omit() || single_value->field_pr__mode.is_bound());
}

boolean EgprsUlAssignMultiblock_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_alpha__present.is_value()
 && (single_value->field_alpha.is_omit() || single_value->field_alpha.is_value())
 && single_value->field_gamma.is_value()
 && single_value->field_tbf__starting__time.is_value()
 && single_value->field_nr__radio__blocks__allocated.is_value()
 && single_value->field_p0__present.is_value()
 && (single_value->field_p0.is_omit() || single_value->field_p0.is_value())
 && (single_value->field_spare.is_omit() || single_value->field_spare.is_value())
 && (single_value->field_pr__mode.is_omit() || single_value->field_pr__mode.is_value());
}

void EgprsUlAssignMultiblock_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

EgprsUlAssignMultiblock EgprsUlAssignMultiblock_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
EgprsUlAssignMultiblock ret_val;
if (single_value->field_alpha__present.is_bound()) {
ret_val.alpha__present() = single_value->field_alpha__present.valueof();
}
if (single_value->field_alpha.is_omit()) ret_val.alpha() = OMIT_VALUE;
else if (single_value->field_alpha.is_bound()) {
ret_val.alpha() = single_value->field_alpha.valueof();
}
if (single_value->field_gamma.is_bound()) {
ret_val.gamma() = single_value->field_gamma.valueof();
}
if (single_value->field_tbf__starting__time.is_bound()) {
ret_val.tbf__starting__time() = single_value->field_tbf__starting__time.valueof();
}
if (single_value->field_nr__radio__blocks__allocated.is_bound()) {
ret_val.nr__radio__blocks__allocated() = single_value->field_nr__radio__blocks__allocated.valueof();
}
if (single_value->field_p0__present.is_bound()) {
ret_val.p0__present() = single_value->field_p0__present.valueof();
}
if (single_value->field_p0.is_omit()) ret_val.p0() = OMIT_VALUE;
else if (single_value->field_p0.is_bound()) {
ret_val.p0() = single_value->field_p0.valueof();
}
if (single_value->field_spare.is_omit()) ret_val.spare() = OMIT_VALUE;
else if (single_value->field_spare.is_bound()) {
ret_val.spare() = single_value->field_spare.valueof();
}
if (single_value->field_pr__mode.is_omit()) ret_val.pr__mode() = OMIT_VALUE;
else if (single_value->field_pr__mode.is_bound()) {
ret_val.pr__mode() = single_value->field_pr__mode.valueof();
}
return ret_val;
}

void EgprsUlAssignMultiblock_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new EgprsUlAssignMultiblock_template[list_length];
}

EgprsUlAssignMultiblock_template& EgprsUlAssignMultiblock_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return value_list.list_value[list_index];
}

BITSTRING_template& EgprsUlAssignMultiblock_template::alpha__present()
{
set_specific();
return single_value->field_alpha__present;
}

const BITSTRING_template& EgprsUlAssignMultiblock_template::alpha__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha_present of a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return single_value->field_alpha__present;
}

INTEGER_template& EgprsUlAssignMultiblock_template::alpha()
{
set_specific();
return single_value->field_alpha;
}

const INTEGER_template& EgprsUlAssignMultiblock_template::alpha() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha of a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return single_value->field_alpha;
}

INTEGER_template& EgprsUlAssignMultiblock_template::gamma()
{
set_specific();
return single_value->field_gamma;
}

const INTEGER_template& EgprsUlAssignMultiblock_template::gamma() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field gamma of a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return single_value->field_gamma;
}

TbfStartingTime_template& EgprsUlAssignMultiblock_template::tbf__starting__time()
{
set_specific();
return single_value->field_tbf__starting__time;
}

const TbfStartingTime_template& EgprsUlAssignMultiblock_template::tbf__starting__time() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tbf_starting_time of a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return single_value->field_tbf__starting__time;
}

BITSTRING_template& EgprsUlAssignMultiblock_template::nr__radio__blocks__allocated()
{
set_specific();
return single_value->field_nr__radio__blocks__allocated;
}

const BITSTRING_template& EgprsUlAssignMultiblock_template::nr__radio__blocks__allocated() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field nr_radio_blocks_allocated of a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return single_value->field_nr__radio__blocks__allocated;
}

BITSTRING_template& EgprsUlAssignMultiblock_template::p0__present()
{
set_specific();
return single_value->field_p0__present;
}

const BITSTRING_template& EgprsUlAssignMultiblock_template::p0__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field p0_present of a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return single_value->field_p0__present;
}

INTEGER_template& EgprsUlAssignMultiblock_template::p0()
{
set_specific();
return single_value->field_p0;
}

const INTEGER_template& EgprsUlAssignMultiblock_template::p0() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field p0 of a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return single_value->field_p0;
}

BITSTRING_template& EgprsUlAssignMultiblock_template::spare()
{
set_specific();
return single_value->field_spare;
}

const BITSTRING_template& EgprsUlAssignMultiblock_template::spare() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field spare of a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return single_value->field_spare;
}

BITSTRING_template& EgprsUlAssignMultiblock_template::pr__mode()
{
set_specific();
return single_value->field_pr__mode;
}

const BITSTRING_template& EgprsUlAssignMultiblock_template::pr__mode() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field pr_mode of a non-specific template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
return single_value->field_pr__mode;
}

int EgprsUlAssignMultiblock_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignMultiblock which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 5;
      if (single_value->field_alpha.is_present()) ret_val++;
      if (single_value->field_p0.is_present()) ret_val++;
      if (single_value->field_spare.is_present()) ret_val++;
      if (single_value->field_pr__mode.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignMultiblock containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignMultiblock containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignMultiblock containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignMultiblock containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignMultiblock containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignMultiblock containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignMultiblock containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.EgprsUlAssignMultiblock containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
  }
  return 0;
}

void EgprsUlAssignMultiblock_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ alpha_present := ");
single_value->field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
single_value->field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
single_value->field_tbf__starting__time.log();
TTCN_Logger::log_event_str(", nr_radio_blocks_allocated := ");
single_value->field_nr__radio__blocks__allocated.log();
TTCN_Logger::log_event_str(", p0_present := ");
single_value->field_p0__present.log();
TTCN_Logger::log_event_str(", p0 := ");
single_value->field_p0.log();
TTCN_Logger::log_event_str(", spare := ");
single_value->field_spare.log();
TTCN_Logger::log_event_str(", pr_mode := ");
single_value->field_pr__mode.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void EgprsUlAssignMultiblock_template::log_match(const EgprsUlAssignMultiblock& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_alpha__present.match(match_value.alpha__present(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha_present");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.alpha().ispresent()){
if(!single_value->field_alpha.match(match_value.alpha(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha");
single_value->field_alpha.log_match(match_value.alpha(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_alpha.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".alpha := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_alpha.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_gamma.match(match_value.gamma(), legacy)){
TTCN_Logger::log_logmatch_info(".gamma");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_tbf__starting__time.match(match_value.tbf__starting__time(), legacy)){
TTCN_Logger::log_logmatch_info(".tbf_starting_time");
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_nr__radio__blocks__allocated.match(match_value.nr__radio__blocks__allocated(), legacy)){
TTCN_Logger::log_logmatch_info(".nr_radio_blocks_allocated");
single_value->field_nr__radio__blocks__allocated.log_match(match_value.nr__radio__blocks__allocated(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_p0__present.match(match_value.p0__present(), legacy)){
TTCN_Logger::log_logmatch_info(".p0_present");
single_value->field_p0__present.log_match(match_value.p0__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.p0().ispresent()){
if(!single_value->field_p0.match(match_value.p0(), legacy)){
TTCN_Logger::log_logmatch_info(".p0");
single_value->field_p0.log_match(match_value.p0(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_p0.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".p0 := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_p0.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.spare().ispresent()){
if(!single_value->field_spare.match(match_value.spare(), legacy)){
TTCN_Logger::log_logmatch_info(".spare");
single_value->field_spare.log_match(match_value.spare(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_spare.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".spare := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_spare.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.pr__mode().ispresent()){
if(!single_value->field_pr__mode.match(match_value.pr__mode(), legacy)){
TTCN_Logger::log_logmatch_info(".pr_mode");
single_value->field_pr__mode.log_match(match_value.pr__mode(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_pr__mode.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".pr_mode := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_pr__mode.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ alpha_present := ");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::log_event_str(", alpha := ");
if (match_value.alpha().ispresent()) {
single_value->field_alpha.log_match(match_value.alpha(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_alpha.log();
if (single_value->field_alpha.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::log_event_str(", tbf_starting_time := ");
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
TTCN_Logger::log_event_str(", nr_radio_blocks_allocated := ");
single_value->field_nr__radio__blocks__allocated.log_match(match_value.nr__radio__blocks__allocated(), legacy);
TTCN_Logger::log_event_str(", p0_present := ");
single_value->field_p0__present.log_match(match_value.p0__present(), legacy);
TTCN_Logger::log_event_str(", p0 := ");
if (match_value.p0().ispresent()) {
single_value->field_p0.log_match(match_value.p0(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_p0.log();
if (single_value->field_p0.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", spare := ");
if (match_value.spare().ispresent()) {
single_value->field_spare.log_match(match_value.spare(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_spare.log();
if (single_value->field_spare.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", pr_mode := ");
if (match_value.pr__mode().ispresent()) {
single_value->field_pr__mode.log_match(match_value.pr__mode(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_pr__mode.log();
if (single_value->field_pr__mode.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void EgprsUlAssignMultiblock_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (tbf__starting__time().is_bound()) tbf__starting__time().set_implicit_omit();
if (nr__radio__blocks__allocated().is_bound()) nr__radio__blocks__allocated().set_implicit_omit();
if (p0__present().is_bound()) p0__present().set_implicit_omit();
if (!p0().is_bound()) p0() = OMIT_VALUE;
else p0().set_implicit_omit();
if (!spare().is_bound()) spare() = OMIT_VALUE;
else spare().set_implicit_omit();
if (!pr__mode().is_bound()) pr__mode() = OMIT_VALUE;
else pr__mode().set_implicit_omit();
}

void EgprsUlAssignMultiblock_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_alpha__present.encode_text(text_buf);
single_value->field_alpha.encode_text(text_buf);
single_value->field_gamma.encode_text(text_buf);
single_value->field_tbf__starting__time.encode_text(text_buf);
single_value->field_nr__radio__blocks__allocated.encode_text(text_buf);
single_value->field_p0__present.encode_text(text_buf);
single_value->field_p0.encode_text(text_buf);
single_value->field_spare.encode_text(text_buf);
single_value->field_pr__mode.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
}
}

void EgprsUlAssignMultiblock_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_alpha__present.decode_text(text_buf);
single_value->field_alpha.decode_text(text_buf);
single_value->field_gamma.decode_text(text_buf);
single_value->field_tbf__starting__time.decode_text(text_buf);
single_value->field_nr__radio__blocks__allocated.decode_text(text_buf);
single_value->field_p0__present.decode_text(text_buf);
single_value->field_p0.decode_text(text_buf);
single_value->field_spare.decode_text(text_buf);
single_value->field_pr__mode.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new EgprsUlAssignMultiblock_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.EgprsUlAssignMultiblock.");
}
}

void EgprsUlAssignMultiblock_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    EgprsUlAssignMultiblock_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (9<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.EgprsUlAssignMultiblock has 9 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) nr__radio__blocks__allocated().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) p0__present().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) p0().set_param(*param.get_elem(6));
    if (param.get_size()>7 && param.get_elem(7)->get_type()!=Module_Param::MP_NotUsed) spare().set_param(*param.get_elem(7));
    if (param.get_size()>8 && param.get_elem(8)->get_type()!=Module_Param::MP_NotUsed) pr__mode().set_param(*param.get_elem(8));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "nr_radio_blocks_allocated")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          nr__radio__blocks__allocated().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "spare")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          spare().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pr_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pr__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.EgprsUlAssignMultiblock: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    EgprsUlAssignMultiblock_template* precondition = new EgprsUlAssignMultiblock_template;
    precondition->set_param(*param.get_elem(0));
    EgprsUlAssignMultiblock_template* implied_template = new EgprsUlAssignMultiblock_template;
    implied_template->set_param(*param.get_elem(1));
    *this = EgprsUlAssignMultiblock_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.EgprsUlAssignMultiblock");
  }
  is_ifpresent = param.get_ifpresent();
}

void EgprsUlAssignMultiblock_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_alpha__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
single_value->field_alpha.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
single_value->field_gamma.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
single_value->field_tbf__starting__time.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
single_value->field_nr__radio__blocks__allocated.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
single_value->field_p0__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
single_value->field_p0.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
single_value->field_spare.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
single_value->field_pr__mode.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.EgprsUlAssignMultiblock");
}

boolean EgprsUlAssignMultiblock_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean EgprsUlAssignMultiblock_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

IaRestOctHL::IaRestOctHL()
{
}

IaRestOctHL::IaRestOctHL(const INTEGER& par_freq__par__len,
    const OPTIONAL< BITSTRING >& par_padding,
    const OPTIONAL< INTEGER >& par_maio,
    const OPTIONAL< OCTETSTRING >& par_mobile__allocation)
  :   field_freq__par__len(par_freq__par__len),
  field_padding(par_padding),
  field_maio(par_maio),
  field_mobile__allocation(par_mobile__allocation)
{
}

IaRestOctHL::IaRestOctHL(const IaRestOctHL& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.IaRestOctHL.");
if (other_value.freq__par__len().is_bound()) field_freq__par__len = other_value.freq__par__len();
else field_freq__par__len.clean_up();
if (other_value.padding().is_bound()) field_padding = other_value.padding();
else field_padding.clean_up();
if (other_value.maio().is_bound()) field_maio = other_value.maio();
else field_maio.clean_up();
if (other_value.mobile__allocation().is_bound()) field_mobile__allocation = other_value.mobile__allocation();
else field_mobile__allocation.clean_up();
}

void IaRestOctHL::clean_up()
{
field_freq__par__len.clean_up();
field_padding.clean_up();
field_maio.clean_up();
field_mobile__allocation.clean_up();
}

const TTCN_Typedescriptor_t* IaRestOctHL::get_descriptor() const { return &IaRestOctHL_descr_; }
IaRestOctHL& IaRestOctHL::operator=(const IaRestOctHL& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.IaRestOctHL.");
  if (other_value.freq__par__len().is_bound()) field_freq__par__len = other_value.freq__par__len();
  else field_freq__par__len.clean_up();
  if (other_value.padding().is_bound()) field_padding = other_value.padding();
  else field_padding.clean_up();
  if (other_value.maio().is_bound()) field_maio = other_value.maio();
  else field_maio.clean_up();
  if (other_value.mobile__allocation().is_bound()) field_mobile__allocation = other_value.mobile__allocation();
  else field_mobile__allocation.clean_up();
}
return *this;
}

boolean IaRestOctHL::operator==(const IaRestOctHL& other_value) const
{
return field_freq__par__len==other_value.field_freq__par__len
  && field_padding==other_value.field_padding
  && field_maio==other_value.field_maio
  && field_mobile__allocation==other_value.field_mobile__allocation;
}

boolean IaRestOctHL::is_bound() const
{
return (field_freq__par__len.is_bound())
  || (OPTIONAL_OMIT == field_padding.get_selection() || field_padding.is_bound())
  || (OPTIONAL_OMIT == field_maio.get_selection() || field_maio.is_bound())
  || (OPTIONAL_OMIT == field_mobile__allocation.get_selection() || field_mobile__allocation.is_bound());
}
boolean IaRestOctHL::is_value() const
{
return field_freq__par__len.is_value()
  && (OPTIONAL_OMIT == field_padding.get_selection() || field_padding.is_value())
  && (OPTIONAL_OMIT == field_maio.get_selection() || field_maio.is_value())
  && (OPTIONAL_OMIT == field_mobile__allocation.get_selection() || field_mobile__allocation.is_value());
}
int IaRestOctHL::size_of() const
{
  int ret_val = 1;
  if (field_padding.ispresent()) ret_val++;
  if (field_maio.ispresent()) ret_val++;
  if (field_mobile__allocation.ispresent()) ret_val++;
  return ret_val;
}

void IaRestOctHL::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ freq_par_len := ");
field_freq__par__len.log();
TTCN_Logger::log_event_str(", padding := ");
field_padding.log();
TTCN_Logger::log_event_str(", maio := ");
field_maio.log();
TTCN_Logger::log_event_str(", mobile_allocation := ");
field_mobile__allocation.log();
TTCN_Logger::log_event_str(" }");
}

void IaRestOctHL::set_implicit_omit()
{
if (freq__par__len().is_bound()) freq__par__len().set_implicit_omit();
if (!padding().is_bound()) padding() = OMIT_VALUE;
else padding().set_implicit_omit();
if (!maio().is_bound()) maio() = OMIT_VALUE;
else maio().set_implicit_omit();
if (!mobile__allocation().is_bound()) mobile__allocation() = OMIT_VALUE;
else mobile__allocation().set_implicit_omit();
}

void IaRestOctHL::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (4<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.IaRestOctHL has 4 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) freq__par__len().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) padding().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) maio().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) mobile__allocation().set_param(*param.get_elem(3));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "freq_par_len")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          freq__par__len().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "padding")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          padding().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "maio")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          maio().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "mobile_allocation")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          mobile__allocation().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctHL: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.IaRestOctHL");
  }
}

void IaRestOctHL::encode_text(Text_Buf& text_buf) const
{
field_freq__par__len.encode_text(text_buf);
field_padding.encode_text(text_buf);
field_maio.encode_text(text_buf);
field_mobile__allocation.encode_text(text_buf);
}

void IaRestOctHL::decode_text(Text_Buf& text_buf)
{
field_freq__par__len.decode_text(text_buf);
field_padding.decode_text(text_buf);
field_maio.decode_text(text_buf);
field_mobile__allocation.decode_text(text_buf);
}

void IaRestOctHL::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void IaRestOctHL::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int IaRestOctHL::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  int value_of_length_field0 = 0;
  RAW_Force_Omit field_0_force_omit(0, force_omit, IaRestOctHL_freq__par__len_descr_.raw->forceomit);
  decoded_field_length = field_freq__par__len.RAW_decode(IaRestOctHL_freq__par__len_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  INTEGER tmp0 = field_freq__par__len.convert_to_Integer(IaRestOctHL_freq__par__len_descr_);
  field_freq__par__len = tmp0;
  value_of_length_field0 += tmp0.get_long_long_val() * 8;
  if (limit > 0 && value_of_length_field0 > 0){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_padding = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, IaRestOctHL_padding_descr_.raw->forceomit);
  decoded_field_length = field_padding().RAW_decode(IaRestOctHL_padding_descr_, p_buf, min_of_ints(2, limit, value_of_length_field0), local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_padding = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  value_of_length_field0 -= decoded_field_length;
  }
  }
  }
  else field_padding=OMIT_VALUE;
  if (limit > 0 && value_of_length_field0 > 0){
  if (force_omit != NULL && (*force_omit)(2)) {
    field_maio = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_2_force_omit(2, force_omit, IaRestOctHL_maio_descr_.raw->forceomit);
  decoded_field_length = field_maio().RAW_decode(IaRestOctHL_maio_descr_, p_buf, min_of_ints(2, limit, value_of_length_field0), local_top_order, TRUE, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 1) {
  field_maio = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  value_of_length_field0 -= decoded_field_length;
  }
  }
  }
  else field_maio=OMIT_VALUE;
  if (limit > 0 && value_of_length_field0 > 0){
  if (force_omit != NULL && (*force_omit)(3)) {
    field_mobile__allocation = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_3_force_omit(3, force_omit, IaRestOctHL_mobile__allocation_descr_.raw->forceomit);
  decoded_field_length = field_mobile__allocation().RAW_decode(IaRestOctHL_mobile__allocation_descr_, p_buf, min_of_ints(2, limit, value_of_length_field0), local_top_order, TRUE, -1, TRUE, &field_3_force_omit);
  if (decoded_field_length < 1) {
  field_mobile__allocation = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  value_of_length_field0 -= decoded_field_length;
  }
  }
  }
  else field_mobile__allocation=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int IaRestOctHL::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 4;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(4);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, IaRestOctHL_freq__par__len_descr_.raw);
  if (field_padding.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, IaRestOctHL_padding_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  if (field_maio.ispresent()) {
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, IaRestOctHL_maio_descr_.raw);
  }
  else myleaf.body.node.nodes[2] = NULL;
  if (field_mobile__allocation.ispresent()) {
  myleaf.body.node.nodes[3] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 3, IaRestOctHL_mobile__allocation_descr_.raw);
  }
  else myleaf.body.node.nodes[3] = NULL;
  encoded_length += 6;
  myleaf.body.node.nodes[0]->calc = CALC_LENGTH;
  myleaf.body.node.nodes[0]->coding_descr = &IaRestOctHL_freq__par__len_descr_;
  myleaf.body.node.nodes[0]->calcof.lengthto.num_of_fields = 3;
  myleaf.body.node.nodes[0]->calcof.lengthto.unit = 8;
  myleaf.body.node.nodes[0]->calcof.lengthto.offset = 0;
  myleaf.body.node.nodes[0]->calcof.lengthto.fields = init_lengthto_fields_list(3);
  myleaf.body.node.nodes[0]->length = 6;
  if (field_mobile__allocation.ispresent()) {
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[0].level = myleaf.body.node.nodes[3]->curr_pos.level;
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[0].pos = myleaf.body.node.nodes[3]->curr_pos.pos;
  } else {
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[0].level = 0;
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[0].pos = 0;
  }
  if (field_maio.ispresent()) {
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[1].level = myleaf.body.node.nodes[2]->curr_pos.level;
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[1].pos = myleaf.body.node.nodes[2]->curr_pos.pos;
  } else {
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[1].level = 0;
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[1].pos = 0;
  }
  if (field_padding.ispresent()) {
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[2].level = myleaf.body.node.nodes[1]->curr_pos.level;
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[2].pos = myleaf.body.node.nodes[1]->curr_pos.pos;
  } else {
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[2].level = 0;
  myleaf.body.node.nodes[0]->calcof.lengthto.fields[2].pos = 0;
  }
  if (field_padding.ispresent()) {
  encoded_length += field_padding().RAW_encode(IaRestOctHL_padding_descr_, *myleaf.body.node.nodes[1]);
  }
  if (field_maio.ispresent()) {
  encoded_length += field_maio().RAW_encode(IaRestOctHL_maio_descr_, *myleaf.body.node.nodes[2]);
  }
  if (field_mobile__allocation.ispresent()) {
  encoded_length += field_mobile__allocation().RAW_encode(IaRestOctHL_mobile__allocation_descr_, *myleaf.body.node.nodes[3]);
  }
  return myleaf.length = encoded_length;
}

struct IaRestOctHL_template::single_value_struct {
INTEGER_template field_freq__par__len;
BITSTRING_template field_padding;
INTEGER_template field_maio;
OCTETSTRING_template field_mobile__allocation;
};

void IaRestOctHL_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_freq__par__len = ANY_VALUE;
single_value->field_padding = ANY_OR_OMIT;
single_value->field_maio = ANY_OR_OMIT;
single_value->field_mobile__allocation = ANY_OR_OMIT;
}
}
}

void IaRestOctHL_template::copy_value(const IaRestOctHL& other_value)
{
single_value = new single_value_struct;
if (other_value.freq__par__len().is_bound()) {
  single_value->field_freq__par__len = other_value.freq__par__len();
} else {
  single_value->field_freq__par__len.clean_up();
}
if (other_value.padding().is_bound()) {
  if (other_value.padding().ispresent()) single_value->field_padding = other_value.padding()();
  else single_value->field_padding = OMIT_VALUE;
} else {
  single_value->field_padding.clean_up();
}
if (other_value.maio().is_bound()) {
  if (other_value.maio().ispresent()) single_value->field_maio = other_value.maio()();
  else single_value->field_maio = OMIT_VALUE;
} else {
  single_value->field_maio.clean_up();
}
if (other_value.mobile__allocation().is_bound()) {
  if (other_value.mobile__allocation().ispresent()) single_value->field_mobile__allocation = other_value.mobile__allocation()();
  else single_value->field_mobile__allocation = OMIT_VALUE;
} else {
  single_value->field_mobile__allocation.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void IaRestOctHL_template::copy_template(const IaRestOctHL_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.freq__par__len().get_selection()) {
single_value->field_freq__par__len = other_value.freq__par__len();
} else {
single_value->field_freq__par__len.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.padding().get_selection()) {
single_value->field_padding = other_value.padding();
} else {
single_value->field_padding.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.maio().get_selection()) {
single_value->field_maio = other_value.maio();
} else {
single_value->field_maio.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.mobile__allocation().get_selection()) {
single_value->field_mobile__allocation = other_value.mobile__allocation();
} else {
single_value->field_mobile__allocation.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new IaRestOctHL_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new IaRestOctHL_template(*other_value.implication_.precondition);
implication_.implied_template = new IaRestOctHL_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctHL.");
break;
}
set_selection(other_value);
}

IaRestOctHL_template::IaRestOctHL_template()
{
}

IaRestOctHL_template::IaRestOctHL_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

IaRestOctHL_template::IaRestOctHL_template(const IaRestOctHL& other_value)
{
copy_value(other_value);
}

IaRestOctHL_template::IaRestOctHL_template(const OPTIONAL<IaRestOctHL>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctHL&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.IaRestOctHL from an unbound optional field.");
}
}

IaRestOctHL_template::IaRestOctHL_template(IaRestOctHL_template* p_precondition, IaRestOctHL_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

IaRestOctHL_template::IaRestOctHL_template(Dynamic_Match_Interface<IaRestOctHL>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<IaRestOctHL>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

IaRestOctHL_template::IaRestOctHL_template(const IaRestOctHL_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

IaRestOctHL_template::~IaRestOctHL_template()
{
clean_up();
}

IaRestOctHL_template& IaRestOctHL_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

IaRestOctHL_template& IaRestOctHL_template::operator=(const IaRestOctHL& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

IaRestOctHL_template& IaRestOctHL_template::operator=(const OPTIONAL<IaRestOctHL>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctHL&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.IaRestOctHL.");
}
return *this;
}

IaRestOctHL_template& IaRestOctHL_template::operator=(const IaRestOctHL_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean IaRestOctHL_template::match(const IaRestOctHL& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.freq__par__len().is_bound()) return FALSE;
if(!single_value->field_freq__par__len.match(other_value.freq__par__len(), legacy))return FALSE;
if(!other_value.padding().is_bound()) return FALSE;
if((other_value.padding().ispresent() ? !single_value->field_padding.match((const BITSTRING&)other_value.padding(), legacy) : !single_value->field_padding.match_omit(legacy)))return FALSE;
if(!other_value.maio().is_bound()) return FALSE;
if((other_value.maio().ispresent() ? !single_value->field_maio.match((const INTEGER&)other_value.maio(), legacy) : !single_value->field_maio.match_omit(legacy)))return FALSE;
if(!other_value.mobile__allocation().is_bound()) return FALSE;
if((other_value.mobile__allocation().ispresent() ? !single_value->field_mobile__allocation.match((const OCTETSTRING&)other_value.mobile__allocation(), legacy) : !single_value->field_mobile__allocation.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctHL.");
}
return FALSE;
}

boolean IaRestOctHL_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_freq__par__len.is_bound()
 || (single_value->field_padding.is_omit() || single_value->field_padding.is_bound())
 || (single_value->field_maio.is_omit() || single_value->field_maio.is_bound())
 || (single_value->field_mobile__allocation.is_omit() || single_value->field_mobile__allocation.is_bound());
}

boolean IaRestOctHL_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_freq__par__len.is_value()
 && (single_value->field_padding.is_omit() || single_value->field_padding.is_value())
 && (single_value->field_maio.is_omit() || single_value->field_maio.is_value())
 && (single_value->field_mobile__allocation.is_omit() || single_value->field_mobile__allocation.is_value());
}

void IaRestOctHL_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

IaRestOctHL IaRestOctHL_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.IaRestOctHL.");
IaRestOctHL ret_val;
if (single_value->field_freq__par__len.is_bound()) {
ret_val.freq__par__len() = single_value->field_freq__par__len.valueof();
}
if (single_value->field_padding.is_omit()) ret_val.padding() = OMIT_VALUE;
else if (single_value->field_padding.is_bound()) {
ret_val.padding() = single_value->field_padding.valueof();
}
if (single_value->field_maio.is_omit()) ret_val.maio() = OMIT_VALUE;
else if (single_value->field_maio.is_bound()) {
ret_val.maio() = single_value->field_maio.valueof();
}
if (single_value->field_mobile__allocation.is_omit()) ret_val.mobile__allocation() = OMIT_VALUE;
else if (single_value->field_mobile__allocation.is_bound()) {
ret_val.mobile__allocation() = single_value->field_mobile__allocation.valueof();
}
return ret_val;
}

void IaRestOctHL_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.IaRestOctHL.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new IaRestOctHL_template[list_length];
}

IaRestOctHL_template& IaRestOctHL_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.IaRestOctHL.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.IaRestOctHL.");
return value_list.list_value[list_index];
}

INTEGER_template& IaRestOctHL_template::freq__par__len()
{
set_specific();
return single_value->field_freq__par__len;
}

const INTEGER_template& IaRestOctHL_template::freq__par__len() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field freq_par_len of a non-specific template of type @GSM_RestOctets.IaRestOctHL.");
return single_value->field_freq__par__len;
}

BITSTRING_template& IaRestOctHL_template::padding()
{
set_specific();
return single_value->field_padding;
}

const BITSTRING_template& IaRestOctHL_template::padding() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field padding of a non-specific template of type @GSM_RestOctets.IaRestOctHL.");
return single_value->field_padding;
}

INTEGER_template& IaRestOctHL_template::maio()
{
set_specific();
return single_value->field_maio;
}

const INTEGER_template& IaRestOctHL_template::maio() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field maio of a non-specific template of type @GSM_RestOctets.IaRestOctHL.");
return single_value->field_maio;
}

OCTETSTRING_template& IaRestOctHL_template::mobile__allocation()
{
set_specific();
return single_value->field_mobile__allocation;
}

const OCTETSTRING_template& IaRestOctHL_template::mobile__allocation() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field mobile_allocation of a non-specific template of type @GSM_RestOctets.IaRestOctHL.");
return single_value->field_mobile__allocation;
}

int IaRestOctHL_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHL which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 1;
      if (single_value->field_padding.is_present()) ret_val++;
      if (single_value->field_maio.is_present()) ret_val++;
      if (single_value->field_mobile__allocation.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHL containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHL containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHL containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHL containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHL containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHL containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHL containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHL containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctHL.");
  }
  return 0;
}

void IaRestOctHL_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ freq_par_len := ");
single_value->field_freq__par__len.log();
TTCN_Logger::log_event_str(", padding := ");
single_value->field_padding.log();
TTCN_Logger::log_event_str(", maio := ");
single_value->field_maio.log();
TTCN_Logger::log_event_str(", mobile_allocation := ");
single_value->field_mobile__allocation.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void IaRestOctHL_template::log_match(const IaRestOctHL& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_freq__par__len.match(match_value.freq__par__len(), legacy)){
TTCN_Logger::log_logmatch_info(".freq_par_len");
single_value->field_freq__par__len.log_match(match_value.freq__par__len(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.padding().ispresent()){
if(!single_value->field_padding.match(match_value.padding(), legacy)){
TTCN_Logger::log_logmatch_info(".padding");
single_value->field_padding.log_match(match_value.padding(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_padding.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".padding := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_padding.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.maio().ispresent()){
if(!single_value->field_maio.match(match_value.maio(), legacy)){
TTCN_Logger::log_logmatch_info(".maio");
single_value->field_maio.log_match(match_value.maio(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_maio.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".maio := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_maio.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.mobile__allocation().ispresent()){
if(!single_value->field_mobile__allocation.match(match_value.mobile__allocation(), legacy)){
TTCN_Logger::log_logmatch_info(".mobile_allocation");
single_value->field_mobile__allocation.log_match(match_value.mobile__allocation(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_mobile__allocation.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".mobile_allocation := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_mobile__allocation.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ freq_par_len := ");
single_value->field_freq__par__len.log_match(match_value.freq__par__len(), legacy);
TTCN_Logger::log_event_str(", padding := ");
if (match_value.padding().ispresent()) {
single_value->field_padding.log_match(match_value.padding(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_padding.log();
if (single_value->field_padding.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", maio := ");
if (match_value.maio().ispresent()) {
single_value->field_maio.log_match(match_value.maio(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_maio.log();
if (single_value->field_maio.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", mobile_allocation := ");
if (match_value.mobile__allocation().ispresent()) {
single_value->field_mobile__allocation.log_match(match_value.mobile__allocation(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_mobile__allocation.log();
if (single_value->field_mobile__allocation.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void IaRestOctHL_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (freq__par__len().is_bound()) freq__par__len().set_implicit_omit();
if (!padding().is_bound()) padding() = OMIT_VALUE;
else padding().set_implicit_omit();
if (!maio().is_bound()) maio() = OMIT_VALUE;
else maio().set_implicit_omit();
if (!mobile__allocation().is_bound()) mobile__allocation() = OMIT_VALUE;
else mobile__allocation().set_implicit_omit();
}

void IaRestOctHL_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_freq__par__len.encode_text(text_buf);
single_value->field_padding.encode_text(text_buf);
single_value->field_maio.encode_text(text_buf);
single_value->field_mobile__allocation.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctHL.");
}
}

void IaRestOctHL_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_freq__par__len.decode_text(text_buf);
single_value->field_padding.decode_text(text_buf);
single_value->field_maio.decode_text(text_buf);
single_value->field_mobile__allocation.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new IaRestOctHL_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.IaRestOctHL.");
}
}

void IaRestOctHL_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    IaRestOctHL_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (4<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.IaRestOctHL has 4 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) freq__par__len().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) padding().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) maio().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) mobile__allocation().set_param(*param.get_elem(3));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "freq_par_len")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          freq__par__len().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "padding")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          padding().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "maio")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          maio().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "mobile_allocation")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          mobile__allocation().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctHL: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    IaRestOctHL_template* precondition = new IaRestOctHL_template;
    precondition->set_param(*param.get_elem(0));
    IaRestOctHL_template* implied_template = new IaRestOctHL_template;
    implied_template->set_param(*param.get_elem(1));
    *this = IaRestOctHL_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.IaRestOctHL");
  }
  is_ifpresent = param.get_ifpresent();
}

void IaRestOctHL_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_freq__par__len.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctHL");
single_value->field_padding.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctHL");
single_value->field_maio.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctHL");
single_value->field_mobile__allocation.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctHL");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.IaRestOctHL");
}

boolean IaRestOctHL_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean IaRestOctHL_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

void PacketAssignUnion::copy_value(const PacketAssignUnion& other_value)
{
switch (other_value.union_selection) {
case ALT_spa:
field_spa = new SecondPartAssign(*other_value.field_spa);
break;
case ALT_uldl:
field_uldl = new PacketUlDlAssign(*other_value.field_uldl);
break;
default:
TTCN_error("Assignment of an unbound union value of type @GSM_RestOctets.PacketAssignUnion.");
}
union_selection = other_value.union_selection;
}

PacketAssignUnion::PacketAssignUnion()
{
union_selection = UNBOUND_VALUE;
}

PacketAssignUnion::PacketAssignUnion(const PacketAssignUnion& other_value)
: Base_Type(){
copy_value(other_value);
}

PacketAssignUnion::~PacketAssignUnion()
{
clean_up();
}

PacketAssignUnion& PacketAssignUnion::operator=(const PacketAssignUnion& other_value)
{
if (this != &other_value) {
clean_up();
copy_value(other_value);
}
return *this;
}

boolean PacketAssignUnion::operator==(const PacketAssignUnion& other_value) const
{
if (union_selection == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of union type @GSM_RestOctets.PacketAssignUnion.");
if (other_value.union_selection == UNBOUND_VALUE) TTCN_error("The right operand of comparison is an unbound value of union type @GSM_RestOctets.PacketAssignUnion.");
if (union_selection != other_value.union_selection) return FALSE;
switch (union_selection) {
case ALT_spa:
return *field_spa == *other_value.field_spa;
case ALT_uldl:
return *field_uldl == *other_value.field_uldl;
default:
return FALSE;
}
}

SecondPartAssign& PacketAssignUnion::spa()
{
if (union_selection != ALT_spa) {
clean_up();
field_spa = new SecondPartAssign;
union_selection = ALT_spa;
}
return *field_spa;
}

const SecondPartAssign& PacketAssignUnion::spa() const
{
if (union_selection != ALT_spa) TTCN_error("Using non-selected field spa in a value of union type @GSM_RestOctets.PacketAssignUnion.");
return *field_spa;
}

PacketUlDlAssign& PacketAssignUnion::uldl()
{
if (union_selection != ALT_uldl) {
clean_up();
field_uldl = new PacketUlDlAssign;
union_selection = ALT_uldl;
}
return *field_uldl;
}

const PacketUlDlAssign& PacketAssignUnion::uldl() const
{
if (union_selection != ALT_uldl) TTCN_error("Using non-selected field uldl in a value of union type @GSM_RestOctets.PacketAssignUnion.");
return *field_uldl;
}

boolean PacketAssignUnion::ischosen(union_selection_type checked_selection) const
{
if (checked_selection == UNBOUND_VALUE) TTCN_error("Internal error: Performing ischosen() operation on an invalid field of union type @GSM_RestOctets.PacketAssignUnion.");
return union_selection == checked_selection;
}

boolean PacketAssignUnion::is_bound() const
{
  return union_selection != UNBOUND_VALUE;
}

boolean PacketAssignUnion::is_value() const
{
switch (union_selection) {
case UNBOUND_VALUE: return FALSE;
case ALT_spa: return field_spa->is_value();
case ALT_uldl: return field_uldl->is_value();
default: TTCN_error("Invalid selection in union is_bound");}
}

void PacketAssignUnion::clean_up()
{
switch (union_selection) {
case ALT_spa:
  delete field_spa;
  break;
case ALT_uldl:
  delete field_uldl;
  break;
default:
  break;
}
union_selection = UNBOUND_VALUE;
}

void PacketAssignUnion::log() const
{
switch (union_selection) {
case ALT_spa:
TTCN_Logger::log_event_str("{ spa := ");
field_spa->log();
TTCN_Logger::log_event_str(" }");
break;
case ALT_uldl:
TTCN_Logger::log_event_str("{ uldl := ");
field_uldl->log();
TTCN_Logger::log_event_str(" }");
break;
default:
TTCN_Logger::log_event_unbound();
}
}

void PacketAssignUnion::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "union value");
  Module_Param_Ptr m_p = &param;
  if (m_p->get_type()==Module_Param::MP_Value_List && m_p->get_size()==0) return;
  if (m_p->get_type()!=Module_Param::MP_Assignment_List) {
    param.error("union value with field name was expected");
  }
  Module_Param* mp_last = m_p->get_elem(m_p->get_size()-1);
  char* last_name = mp_last->get_id()->get_name();
  if (!strcmp(last_name, "spa")) {
    spa().set_param(*mp_last);
    if (!spa().is_bound()) clean_up();
    return;
  }
  if (!strcmp(last_name, "uldl")) {
    uldl().set_param(*mp_last);
    if (!uldl().is_bound()) clean_up();
    return;
  }
  mp_last->error("Field %s does not exist in type @GSM_RestOctets.PacketAssignUnion.", last_name);
}

void PacketAssignUnion::set_implicit_omit()
{
switch (union_selection) {
case ALT_spa:
field_spa->set_implicit_omit(); break;
case ALT_uldl:
field_uldl->set_implicit_omit(); break;
default: break;
}
}

void PacketAssignUnion::encode_text(Text_Buf& text_buf) const
{
text_buf.push_int(union_selection);
switch (union_selection) {
case ALT_spa:
field_spa->encode_text(text_buf);
break;
case ALT_uldl:
field_uldl->encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an unbound value of union type @GSM_RestOctets.PacketAssignUnion.");
}
}

void PacketAssignUnion::decode_text(Text_Buf& text_buf)
{
switch ((union_selection_type)text_buf.pull_int().get_val()) {
case ALT_spa:
spa().decode_text(text_buf);
break;
case ALT_uldl:
uldl().decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: Unrecognized union selector was received for type @GSM_RestOctets.PacketAssignUnion.");
}
}

void PacketAssignUnion::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(TRUE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void PacketAssignUnion::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int PacketAssignUnion::RAW_decode(
const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, 
raw_order_t top_bit_ord, boolean no_err, int sel_field, boolean, const RAW_Force_Omit* force_omit)
{
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  int decoded_length=0;
  int starting_pos=p_buf.get_pos_bit();
  if(sel_field!=-1){
    switch(sel_field){
    case 0: {
      RAW_Force_Omit field_force_omit(0, force_omit, PacketAssignUnion_spa_descr_.raw->forceomit);
      decoded_length = spa().RAW_decode(PacketAssignUnion_spa_descr_, p_buf, limit, top_bit_ord, no_err, -1, TRUE, &field_force_omit);
      break; }
    case 1: {
      RAW_Force_Omit field_force_omit(1, force_omit, PacketAssignUnion_uldl_descr_.raw->forceomit);
      decoded_length = uldl().RAW_decode(PacketAssignUnion_uldl_descr_, p_buf, limit, top_bit_ord, no_err, -1, TRUE, &field_force_omit);
      break; }
    default: break;
    }
    return decoded_length + p_buf.increase_pos_padd(p_td.raw->padding) + prepaddlength;
  } else {
      p_buf.set_pos_bit(starting_pos);
      RAW_Force_Omit field_0_force_omit(0, force_omit, PacketAssignUnion_spa_descr_.raw->forceomit);
      decoded_length = spa().RAW_decode(PacketAssignUnion_spa_descr_, p_buf, limit, top_bit_ord, TRUE, -1, TRUE, &field_0_force_omit);
      if (decoded_length >= 0) {
         return decoded_length + p_buf.increase_pos_padd(p_td.raw->padding) + prepaddlength;
       }
      p_buf.set_pos_bit(starting_pos);
      RAW_Force_Omit field_1_force_omit(1, force_omit, PacketAssignUnion_uldl_descr_.raw->forceomit);
      decoded_length = uldl().RAW_decode(PacketAssignUnion_uldl_descr_, p_buf, limit, top_bit_ord, TRUE, -1, TRUE, &field_1_force_omit);
      if (decoded_length >= 0) {
         return decoded_length + p_buf.increase_pos_padd(p_td.raw->padding) + prepaddlength;
       }
 }
 clean_up();
 return -1;
}

int PacketAssignUnion::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const
{
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 2;  myleaf.body.node.nodes = init_nodes_of_enc_tree(2);
  memset(myleaf.body.node.nodes, 0, 2 * sizeof(RAW_enc_tree *));
  switch (union_selection) {
  case ALT_spa:
    myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &myleaf.curr_pos, 0, PacketAssignUnion_spa_descr_.raw);
    encoded_length = field_spa->RAW_encode(PacketAssignUnion_spa_descr_, *myleaf.body.node.nodes[0]);
    myleaf.body.node.nodes[0]->coding_descr = &PacketAssignUnion_spa_descr_;
    break;
  case ALT_uldl:
    myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &myleaf.curr_pos, 1, PacketAssignUnion_uldl_descr_.raw);
    encoded_length = field_uldl->RAW_encode(PacketAssignUnion_uldl_descr_, *myleaf.body.node.nodes[1]);
    myleaf.body.node.nodes[1]->coding_descr = &PacketAssignUnion_uldl_descr_;
    break;
  default:
    TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  }
  return encoded_length;
}

void PacketAssignUnion_template::copy_value(const PacketAssignUnion& other_value)
{
single_value.union_selection = other_value.get_selection();
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
single_value.field_spa = new SecondPartAssign_template(other_value.spa());
break;
case PacketAssignUnion::ALT_uldl:
single_value.field_uldl = new PacketUlDlAssign_template(other_value.uldl());
break;
default:
TTCN_error("Initializing a template with an unbound value of type @GSM_RestOctets.PacketAssignUnion.");
}
set_selection(SPECIFIC_VALUE);
}

void PacketAssignUnion_template::copy_template(const PacketAssignUnion_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value.union_selection = other_value.single_value.union_selection;
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
single_value.field_spa = new SecondPartAssign_template(*other_value.single_value.field_spa);
break;
case PacketAssignUnion::ALT_uldl:
single_value.field_uldl = new PacketUlDlAssign_template(*other_value.single_value.field_uldl);
break;
default:
TTCN_error("Internal error: Invalid union selector in a specific value when copying a template of type @GSM_RestOctets.PacketAssignUnion.");
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new PacketAssignUnion_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new PacketAssignUnion_template(*other_value.implication_.precondition);
implication_.implied_template = new PacketAssignUnion_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized template of union type @GSM_RestOctets.PacketAssignUnion.");
}
set_selection(other_value);
}

PacketAssignUnion_template::PacketAssignUnion_template()
{
}

PacketAssignUnion_template::PacketAssignUnion_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

PacketAssignUnion_template::PacketAssignUnion_template(const PacketAssignUnion& other_value)
{
copy_value(other_value);
}

PacketAssignUnion_template::PacketAssignUnion_template(const OPTIONAL<PacketAssignUnion>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketAssignUnion&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of union type @GSM_RestOctets.PacketAssignUnion from an unbound optional field.");
}
}

PacketAssignUnion_template::PacketAssignUnion_template(PacketAssignUnion_template* p_precondition, PacketAssignUnion_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

PacketAssignUnion_template::PacketAssignUnion_template(Dynamic_Match_Interface<PacketAssignUnion>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<PacketAssignUnion>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

PacketAssignUnion_template::PacketAssignUnion_template(const PacketAssignUnion_template& other_value)
: Base_Template(){
copy_template(other_value);
}

PacketAssignUnion_template::~PacketAssignUnion_template()
{
clean_up();
}

void PacketAssignUnion_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
delete single_value.field_spa;
break;
case PacketAssignUnion::ALT_uldl:
delete single_value.field_uldl;
default:
break;
}
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

PacketAssignUnion_template& PacketAssignUnion_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

PacketAssignUnion_template& PacketAssignUnion_template::operator=(const PacketAssignUnion& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

PacketAssignUnion_template& PacketAssignUnion_template::operator=(const OPTIONAL<PacketAssignUnion>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketAssignUnion&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of union type @GSM_RestOctets.PacketAssignUnion.");
}
return *this;
}

PacketAssignUnion_template& PacketAssignUnion_template::operator=(const PacketAssignUnion_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean PacketAssignUnion_template::match(const PacketAssignUnion& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
{
PacketAssignUnion::union_selection_type value_selection = other_value.get_selection();
if (value_selection == PacketAssignUnion::UNBOUND_VALUE) return FALSE;
if (value_selection != single_value.union_selection) return FALSE;
switch (value_selection) {
case PacketAssignUnion::ALT_spa:
return single_value.field_spa->match(other_value.spa(), legacy);
case PacketAssignUnion::ALT_uldl:
return single_value.field_uldl->match(other_value.uldl(), legacy);
default:
TTCN_error("Internal error: Invalid selector in a specific value when matching a template of union type @GSM_RestOctets.PacketAssignUnion.");
}
}
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error ("Matching an uninitialized template of union type @GSM_RestOctets.PacketAssignUnion.");
}
return FALSE;
}

boolean PacketAssignUnion_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
return single_value.field_spa->is_value();
case PacketAssignUnion::ALT_uldl:
return single_value.field_uldl->is_value();
default:
TTCN_error("Internal error: Invalid selector in a specific value when performing is_value operation on a template of union type @GSM_RestOctets.PacketAssignUnion.");
}
}

PacketAssignUnion PacketAssignUnion_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of union type @GSM_RestOctets.PacketAssignUnion.");
PacketAssignUnion ret_val;
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
ret_val.spa() = single_value.field_spa->valueof();
break;
case PacketAssignUnion::ALT_uldl:
ret_val.uldl() = single_value.field_uldl->valueof();
break;
default:
TTCN_error("Internal error: Invalid selector in a specific value when performing valueof operation on a template of union type @GSM_RestOctets.PacketAssignUnion.");
}
return ret_val;
}

PacketAssignUnion_template& PacketAssignUnion_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST && template_selection != CONJUNCTION_MATCH) TTCN_error("Internal error: Accessing a list element of a non-list template of union type @GSM_RestOctets.PacketAssignUnion.");
if (list_index >= value_list.n_values) TTCN_error("Internal error: Index overflow in a value list template of union type @GSM_RestOctets.PacketAssignUnion.");
return value_list.list_value[list_index];
}
void PacketAssignUnion_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST && template_type != CONJUNCTION_MATCH) TTCN_error ("Internal error: Setting an invalid list for a template of union type @GSM_RestOctets.PacketAssignUnion.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new PacketAssignUnion_template[list_length];
}

SecondPartAssign_template& PacketAssignUnion_template::spa()
{
if (template_selection != SPECIFIC_VALUE || single_value.union_selection != PacketAssignUnion::ALT_spa) {
template_sel old_selection = template_selection;
clean_up();
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) single_value.field_spa = new SecondPartAssign_template(ANY_VALUE);
else single_value.field_spa = new SecondPartAssign_template;
single_value.union_selection = PacketAssignUnion::ALT_spa;
set_selection(SPECIFIC_VALUE);
}
return *single_value.field_spa;
}

const SecondPartAssign_template& PacketAssignUnion_template::spa() const
{
if (template_selection != SPECIFIC_VALUE) TTCN_error("Accessing field spa in a non-specific template of union type @GSM_RestOctets.PacketAssignUnion.");
if (single_value.union_selection != PacketAssignUnion::ALT_spa) TTCN_error("Accessing non-selected field spa in a template of union type @GSM_RestOctets.PacketAssignUnion.");
return *single_value.field_spa;
}

PacketUlDlAssign_template& PacketAssignUnion_template::uldl()
{
if (template_selection != SPECIFIC_VALUE || single_value.union_selection != PacketAssignUnion::ALT_uldl) {
template_sel old_selection = template_selection;
clean_up();
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) single_value.field_uldl = new PacketUlDlAssign_template(ANY_VALUE);
else single_value.field_uldl = new PacketUlDlAssign_template;
single_value.union_selection = PacketAssignUnion::ALT_uldl;
set_selection(SPECIFIC_VALUE);
}
return *single_value.field_uldl;
}

const PacketUlDlAssign_template& PacketAssignUnion_template::uldl() const
{
if (template_selection != SPECIFIC_VALUE) TTCN_error("Accessing field uldl in a non-specific template of union type @GSM_RestOctets.PacketAssignUnion.");
if (single_value.union_selection != PacketAssignUnion::ALT_uldl) TTCN_error("Accessing non-selected field uldl in a template of union type @GSM_RestOctets.PacketAssignUnion.");
return *single_value.field_uldl;
}

boolean PacketAssignUnion_template::ischosen(PacketAssignUnion::union_selection_type checked_selection) const
{
if (checked_selection == PacketAssignUnion::UNBOUND_VALUE) TTCN_error("Internal error: Performing ischosen() operation on an invalid field of union type @GSM_RestOctets.PacketAssignUnion.");
switch (template_selection) {
case SPECIFIC_VALUE:
if (single_value.union_selection == PacketAssignUnion::UNBOUND_VALUE) TTCN_error("Internal error: Invalid selector in a specific value when performing ischosen() operation on a template of union type @GSM_RestOctets.PacketAssignUnion.");
return single_value.union_selection == checked_selection;
case VALUE_LIST:
{
if (value_list.n_values < 1)
TTCN_error("Internal error: Performing ischosen() operation on a template of union type @GSM_RestOctets.PacketAssignUnion containing an empty list.");
boolean ret_val = value_list.list_value[0].ischosen(checked_selection);
for (unsigned int list_count = 1; ret_val == TRUE && list_count < value_list.n_values; list_count++) {
ret_val = value_list.list_value[list_count].ischosen(checked_selection);
}
return ret_val;
}
default:
return FALSE;
}
return FALSE;
}

void PacketAssignUnion_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
TTCN_Logger::log_event_str("{ spa := ");
single_value.field_spa->log();
TTCN_Logger::log_event_str(" }");
break;
case PacketAssignUnion::ALT_uldl:
TTCN_Logger::log_event_str("{ uldl := ");
single_value.field_uldl->log();
TTCN_Logger::log_event_str(" }");
break;
default:
TTCN_Logger::log_event_str("<invalid selector>");
}
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void PacketAssignUnion_template::log_match(const PacketAssignUnion& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity() && match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
return;
}
if (template_selection == SPECIFIC_VALUE && single_value.union_selection == match_value.get_selection()) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
TTCN_Logger::log_logmatch_info(".spa");
single_value.field_spa->log_match(match_value.spa(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
} else {
TTCN_Logger::log_event_str("{ spa := ");
single_value.field_spa->log_match(match_value.spa(), legacy);
TTCN_Logger::log_event_str(" }");
}
break;
case PacketAssignUnion::ALT_uldl:
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
TTCN_Logger::log_logmatch_info(".uldl");
single_value.field_uldl->log_match(match_value.uldl(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
} else {
TTCN_Logger::log_event_str("{ uldl := ");
single_value.field_uldl->log_match(match_value.uldl(), legacy);
TTCN_Logger::log_event_str(" }");
}
break;
default:
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str("<invalid selector>");
}
} else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void PacketAssignUnion_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
single_value.field_spa->set_implicit_omit(); break;
case PacketAssignUnion::ALT_uldl:
single_value.field_uldl->set_implicit_omit(); break;
default: break;
}
}

void PacketAssignUnion_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
text_buf.push_int(single_value.union_selection);
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
single_value.field_spa->encode_text(text_buf);
break;
case PacketAssignUnion::ALT_uldl:
single_value.field_uldl->encode_text(text_buf);
break;
default:
TTCN_error("Internal error: Invalid selector in a specific value when encoding a template of union type @GSM_RestOctets.PacketAssignUnion.");
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized template of type @GSM_RestOctets.PacketAssignUnion.");
}
}

void PacketAssignUnion_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
{
single_value.union_selection = PacketAssignUnion::UNBOUND_VALUE;
PacketAssignUnion::union_selection_type new_selection = (PacketAssignUnion::union_selection_type)text_buf.pull_int().get_val();
switch (new_selection) {
case PacketAssignUnion::ALT_spa:
single_value.field_spa = new SecondPartAssign_template;
single_value.field_spa->decode_text(text_buf);
break;
case PacketAssignUnion::ALT_uldl:
single_value.field_uldl = new PacketUlDlAssign_template;
single_value.field_uldl->decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: Unrecognized union selector was received for a template of type @GSM_RestOctets.PacketAssignUnion.");
}
single_value.union_selection = new_selection;
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new PacketAssignUnion_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: Unrecognized selector was received in a template of type @GSM_RestOctets.PacketAssignUnion.");
}
}

boolean PacketAssignUnion_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean PacketAssignUnion_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int v_idx=0; v_idx<value_list.n_values; v_idx++)
if (value_list.list_value[v_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

void PacketAssignUnion_template::set_param(Module_Param& param)
{
  if (dynamic_cast<Module_Param_Name*>(param.get_id()) != NULL &&
      param.get_id()->next_name()) {
    char* param_field = param.get_id()->get_current_name();
    if (param_field[0] >= '0' && param_field[0] <= '9') {
      param.error("Unexpected array index in module parameter, expected a valid field"
        " name for union template type `@GSM_RestOctets.PacketAssignUnion'");
    }
    if (strcmp("spa", param_field) == 0) {
      spa().set_param(param);
      return;
    } else if (strcmp("uldl", param_field) == 0) {
      uldl().set_param(param);
      return;
    } else param.error("Field `%s' not found in union template type `@GSM_RestOctets.PacketAssignUnion'", param_field);
  }
  param.basic_check(Module_Param::BC_TEMPLATE, "union template");
  Module_Param_Ptr m_p = &param;
  switch (m_p->get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    PacketAssignUnion_template new_temp;
    new_temp.set_type(m_p->get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (m_p->get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), m_p->get_size());
    for (size_t p_i=0; p_i<m_p->get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*m_p->get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (m_p->get_size()==0) break;
    param.type_error("union template", "@GSM_RestOctets.PacketAssignUnion");
    break;
  case Module_Param::MP_Assignment_List: {
    Module_Param* mp_last = m_p->get_elem(m_p->get_size()-1);
    char* last_name = mp_last->get_id()->get_name();
    if (!strcmp(last_name, "spa")) {
      spa().set_param(*mp_last);
      break;
    }
    if (!strcmp(last_name, "uldl")) {
      uldl().set_param(*mp_last);
      break;
    }
    mp_last->error("Field %s does not exist in type @GSM_RestOctets.PacketAssignUnion.", last_name);
  } break;
  case Module_Param::MP_Implication_Template: {
    PacketAssignUnion_template* precondition = new PacketAssignUnion_template;
    precondition->set_param(*m_p->get_elem(0));
    PacketAssignUnion_template* implied_template = new PacketAssignUnion_template;
    implied_template->set_param(*m_p->get_elem(1));
    *this = PacketAssignUnion_template(precondition, implied_template);
  } break;
  default:
    param.type_error("union template", "@GSM_RestOctets.PacketAssignUnion");
  }
  is_ifpresent = param.get_ifpresent();
}

void PacketAssignUnion_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
switch (single_value.union_selection) {
case PacketAssignUnion::ALT_spa:
single_value.field_spa->check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketAssignUnion");
return;
case PacketAssignUnion::ALT_uldl:
single_value.field_uldl->check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketAssignUnion");
return;
default:
TTCN_error("Internal error: Invalid selector in a specific value when performing check_restriction operation on a template of union type @GSM_RestOctets.PacketAssignUnion.");
}
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.PacketAssignUnion");
}

SecondPartAssign::SecondPartAssign()
{
}

SecondPartAssign::SecondPartAssign(const BITSTRING& par_r99,
    const OPTIONAL< BITSTRING >& par_presence,
    const OPTIONAL< BITSTRING >& par_ext__ra)
  :   field_r99(par_r99),
  field_presence(par_presence),
  field_ext__ra(par_ext__ra)
{
}

SecondPartAssign::SecondPartAssign(const SecondPartAssign& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.SecondPartAssign.");
if (other_value.r99().is_bound()) field_r99 = other_value.r99();
else field_r99.clean_up();
if (other_value.presence().is_bound()) field_presence = other_value.presence();
else field_presence.clean_up();
if (other_value.ext__ra().is_bound()) field_ext__ra = other_value.ext__ra();
else field_ext__ra.clean_up();
}

void SecondPartAssign::clean_up()
{
field_r99.clean_up();
field_presence.clean_up();
field_ext__ra.clean_up();
}

const TTCN_Typedescriptor_t* SecondPartAssign::get_descriptor() const { return &SecondPartAssign_descr_; }
SecondPartAssign& SecondPartAssign::operator=(const SecondPartAssign& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.SecondPartAssign.");
  if (other_value.r99().is_bound()) field_r99 = other_value.r99();
  else field_r99.clean_up();
  if (other_value.presence().is_bound()) field_presence = other_value.presence();
  else field_presence.clean_up();
  if (other_value.ext__ra().is_bound()) field_ext__ra = other_value.ext__ra();
  else field_ext__ra.clean_up();
}
return *this;
}

boolean SecondPartAssign::operator==(const SecondPartAssign& other_value) const
{
return field_r99==other_value.field_r99
  && field_presence==other_value.field_presence
  && field_ext__ra==other_value.field_ext__ra;
}

boolean SecondPartAssign::is_bound() const
{
return (field_r99.is_bound())
  || (OPTIONAL_OMIT == field_presence.get_selection() || field_presence.is_bound())
  || (OPTIONAL_OMIT == field_ext__ra.get_selection() || field_ext__ra.is_bound());
}
boolean SecondPartAssign::is_value() const
{
return field_r99.is_value()
  && (OPTIONAL_OMIT == field_presence.get_selection() || field_presence.is_value())
  && (OPTIONAL_OMIT == field_ext__ra.get_selection() || field_ext__ra.is_value());
}
int SecondPartAssign::size_of() const
{
  int ret_val = 1;
  if (field_presence.ispresent()) ret_val++;
  if (field_ext__ra.ispresent()) ret_val++;
  return ret_val;
}

void SecondPartAssign::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ r99 := ");
field_r99.log();
TTCN_Logger::log_event_str(", presence := ");
field_presence.log();
TTCN_Logger::log_event_str(", ext_ra := ");
field_ext__ra.log();
TTCN_Logger::log_event_str(" }");
}

void SecondPartAssign::set_implicit_omit()
{
if (r99().is_bound()) r99().set_implicit_omit();
if (!presence().is_bound()) presence() = OMIT_VALUE;
else presence().set_implicit_omit();
if (!ext__ra().is_bound()) ext__ra() = OMIT_VALUE;
else ext__ra().set_implicit_omit();
}

void SecondPartAssign::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.SecondPartAssign has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) r99().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) ext__ra().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "r99")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          r99().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ext_ra")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ext__ra().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.SecondPartAssign: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.SecondPartAssign");
  }
}

void SecondPartAssign::encode_text(Text_Buf& text_buf) const
{
field_r99.encode_text(text_buf);
field_presence.encode_text(text_buf);
field_ext__ra.encode_text(text_buf);
}

void SecondPartAssign::decode_text(Text_Buf& text_buf)
{
field_r99.decode_text(text_buf);
field_presence.decode_text(text_buf);
field_ext__ra.decode_text(text_buf);
}

void SecondPartAssign::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void SecondPartAssign::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int SecondPartAssign::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, SecondPartAssign_r99_descr_.raw->forceomit);
  decoded_field_length = field_r99.RAW_decode(SecondPartAssign_r99_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_r99 ==  bs_0){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_presence = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, SecondPartAssign_presence_descr_.raw->forceomit);
  decoded_field_length = field_presence().RAW_decode(SecondPartAssign_presence_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_presence = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_presence=OMIT_VALUE;
  if (limit > 0 && field_presence ==  bs_0){
  if (force_omit != NULL && (*force_omit)(2)) {
    field_ext__ra = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_2_force_omit(2, force_omit, SecondPartAssign_ext__ra_descr_.raw->forceomit);
  decoded_field_length = field_ext__ra().RAW_decode(SecondPartAssign_ext__ra_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 1) {
  field_ext__ra = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_ext__ra=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int SecondPartAssign::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 3;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(3);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, SecondPartAssign_r99_descr_.raw);
  if (field_presence.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, SecondPartAssign_presence_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  if (field_ext__ra.ispresent()) {
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, SecondPartAssign_ext__ra_descr_.raw);
  }
  else myleaf.body.node.nodes[2] = NULL;
  encoded_length += field_r99.RAW_encode(SecondPartAssign_r99_descr_, *myleaf.body.node.nodes[0]);
  if (field_presence.ispresent()) {
  encoded_length += field_presence().RAW_encode(SecondPartAssign_presence_descr_, *myleaf.body.node.nodes[1]);
  }
  if (field_ext__ra.ispresent()) {
  encoded_length += field_ext__ra().RAW_encode(SecondPartAssign_ext__ra_descr_, *myleaf.body.node.nodes[2]);
  }
  if (field_presence.ispresent() && (field_r99 !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(SecondPartAssign_r99_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_ext__ra.ispresent() && (field_presence !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={1};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(SecondPartAssign_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct SecondPartAssign_template::single_value_struct {
BITSTRING_template field_r99;
BITSTRING_template field_presence;
BITSTRING_template field_ext__ra;
};

void SecondPartAssign_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_r99 = ANY_VALUE;
single_value->field_presence = ANY_OR_OMIT;
single_value->field_ext__ra = ANY_OR_OMIT;
}
}
}

void SecondPartAssign_template::copy_value(const SecondPartAssign& other_value)
{
single_value = new single_value_struct;
if (other_value.r99().is_bound()) {
  single_value->field_r99 = other_value.r99();
} else {
  single_value->field_r99.clean_up();
}
if (other_value.presence().is_bound()) {
  if (other_value.presence().ispresent()) single_value->field_presence = other_value.presence()();
  else single_value->field_presence = OMIT_VALUE;
} else {
  single_value->field_presence.clean_up();
}
if (other_value.ext__ra().is_bound()) {
  if (other_value.ext__ra().ispresent()) single_value->field_ext__ra = other_value.ext__ra()();
  else single_value->field_ext__ra = OMIT_VALUE;
} else {
  single_value->field_ext__ra.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void SecondPartAssign_template::copy_template(const SecondPartAssign_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.r99().get_selection()) {
single_value->field_r99 = other_value.r99();
} else {
single_value->field_r99.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.presence().get_selection()) {
single_value->field_presence = other_value.presence();
} else {
single_value->field_presence.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ext__ra().get_selection()) {
single_value->field_ext__ra = other_value.ext__ra();
} else {
single_value->field_ext__ra.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new SecondPartAssign_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new SecondPartAssign_template(*other_value.implication_.precondition);
implication_.implied_template = new SecondPartAssign_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.SecondPartAssign.");
break;
}
set_selection(other_value);
}

SecondPartAssign_template::SecondPartAssign_template()
{
}

SecondPartAssign_template::SecondPartAssign_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

SecondPartAssign_template::SecondPartAssign_template(const SecondPartAssign& other_value)
{
copy_value(other_value);
}

SecondPartAssign_template::SecondPartAssign_template(const OPTIONAL<SecondPartAssign>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const SecondPartAssign&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.SecondPartAssign from an unbound optional field.");
}
}

SecondPartAssign_template::SecondPartAssign_template(SecondPartAssign_template* p_precondition, SecondPartAssign_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

SecondPartAssign_template::SecondPartAssign_template(Dynamic_Match_Interface<SecondPartAssign>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<SecondPartAssign>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

SecondPartAssign_template::SecondPartAssign_template(const SecondPartAssign_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

SecondPartAssign_template::~SecondPartAssign_template()
{
clean_up();
}

SecondPartAssign_template& SecondPartAssign_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

SecondPartAssign_template& SecondPartAssign_template::operator=(const SecondPartAssign& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

SecondPartAssign_template& SecondPartAssign_template::operator=(const OPTIONAL<SecondPartAssign>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const SecondPartAssign&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.SecondPartAssign.");
}
return *this;
}

SecondPartAssign_template& SecondPartAssign_template::operator=(const SecondPartAssign_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean SecondPartAssign_template::match(const SecondPartAssign& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.r99().is_bound()) return FALSE;
if(!single_value->field_r99.match(other_value.r99(), legacy))return FALSE;
if(!other_value.presence().is_bound()) return FALSE;
if((other_value.presence().ispresent() ? !single_value->field_presence.match((const BITSTRING&)other_value.presence(), legacy) : !single_value->field_presence.match_omit(legacy)))return FALSE;
if(!other_value.ext__ra().is_bound()) return FALSE;
if((other_value.ext__ra().ispresent() ? !single_value->field_ext__ra.match((const BITSTRING&)other_value.ext__ra(), legacy) : !single_value->field_ext__ra.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.SecondPartAssign.");
}
return FALSE;
}

boolean SecondPartAssign_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_r99.is_bound()
 || (single_value->field_presence.is_omit() || single_value->field_presence.is_bound())
 || (single_value->field_ext__ra.is_omit() || single_value->field_ext__ra.is_bound());
}

boolean SecondPartAssign_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_r99.is_value()
 && (single_value->field_presence.is_omit() || single_value->field_presence.is_value())
 && (single_value->field_ext__ra.is_omit() || single_value->field_ext__ra.is_value());
}

void SecondPartAssign_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

SecondPartAssign SecondPartAssign_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.SecondPartAssign.");
SecondPartAssign ret_val;
if (single_value->field_r99.is_bound()) {
ret_val.r99() = single_value->field_r99.valueof();
}
if (single_value->field_presence.is_omit()) ret_val.presence() = OMIT_VALUE;
else if (single_value->field_presence.is_bound()) {
ret_val.presence() = single_value->field_presence.valueof();
}
if (single_value->field_ext__ra.is_omit()) ret_val.ext__ra() = OMIT_VALUE;
else if (single_value->field_ext__ra.is_bound()) {
ret_val.ext__ra() = single_value->field_ext__ra.valueof();
}
return ret_val;
}

void SecondPartAssign_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.SecondPartAssign.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new SecondPartAssign_template[list_length];
}

SecondPartAssign_template& SecondPartAssign_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.SecondPartAssign.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.SecondPartAssign.");
return value_list.list_value[list_index];
}

BITSTRING_template& SecondPartAssign_template::r99()
{
set_specific();
return single_value->field_r99;
}

const BITSTRING_template& SecondPartAssign_template::r99() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field r99 of a non-specific template of type @GSM_RestOctets.SecondPartAssign.");
return single_value->field_r99;
}

BITSTRING_template& SecondPartAssign_template::presence()
{
set_specific();
return single_value->field_presence;
}

const BITSTRING_template& SecondPartAssign_template::presence() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field presence of a non-specific template of type @GSM_RestOctets.SecondPartAssign.");
return single_value->field_presence;
}

BITSTRING_template& SecondPartAssign_template::ext__ra()
{
set_specific();
return single_value->field_ext__ra;
}

const BITSTRING_template& SecondPartAssign_template::ext__ra() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ext_ra of a non-specific template of type @GSM_RestOctets.SecondPartAssign.");
return single_value->field_ext__ra;
}

int SecondPartAssign_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.SecondPartAssign which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 1;
      if (single_value->field_presence.is_present()) ret_val++;
      if (single_value->field_ext__ra.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.SecondPartAssign containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.SecondPartAssign containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.SecondPartAssign containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.SecondPartAssign containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.SecondPartAssign containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.SecondPartAssign containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.SecondPartAssign containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.SecondPartAssign containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.SecondPartAssign.");
  }
  return 0;
}

void SecondPartAssign_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ r99 := ");
single_value->field_r99.log();
TTCN_Logger::log_event_str(", presence := ");
single_value->field_presence.log();
TTCN_Logger::log_event_str(", ext_ra := ");
single_value->field_ext__ra.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void SecondPartAssign_template::log_match(const SecondPartAssign& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_r99.match(match_value.r99(), legacy)){
TTCN_Logger::log_logmatch_info(".r99");
single_value->field_r99.log_match(match_value.r99(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.presence().ispresent()){
if(!single_value->field_presence.match(match_value.presence(), legacy)){
TTCN_Logger::log_logmatch_info(".presence");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_presence.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".presence := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_presence.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.ext__ra().ispresent()){
if(!single_value->field_ext__ra.match(match_value.ext__ra(), legacy)){
TTCN_Logger::log_logmatch_info(".ext_ra");
single_value->field_ext__ra.log_match(match_value.ext__ra(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_ext__ra.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".ext_ra := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_ext__ra.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ r99 := ");
single_value->field_r99.log_match(match_value.r99(), legacy);
TTCN_Logger::log_event_str(", presence := ");
if (match_value.presence().ispresent()) {
single_value->field_presence.log_match(match_value.presence(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_presence.log();
if (single_value->field_presence.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", ext_ra := ");
if (match_value.ext__ra().ispresent()) {
single_value->field_ext__ra.log_match(match_value.ext__ra(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_ext__ra.log();
if (single_value->field_ext__ra.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void SecondPartAssign_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (r99().is_bound()) r99().set_implicit_omit();
if (!presence().is_bound()) presence() = OMIT_VALUE;
else presence().set_implicit_omit();
if (!ext__ra().is_bound()) ext__ra() = OMIT_VALUE;
else ext__ra().set_implicit_omit();
}

void SecondPartAssign_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_r99.encode_text(text_buf);
single_value->field_presence.encode_text(text_buf);
single_value->field_ext__ra.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.SecondPartAssign.");
}
}

void SecondPartAssign_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_r99.decode_text(text_buf);
single_value->field_presence.decode_text(text_buf);
single_value->field_ext__ra.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new SecondPartAssign_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.SecondPartAssign.");
}
}

void SecondPartAssign_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    SecondPartAssign_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.SecondPartAssign has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) r99().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) ext__ra().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "r99")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          r99().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ext_ra")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ext__ra().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.SecondPartAssign: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    SecondPartAssign_template* precondition = new SecondPartAssign_template;
    precondition->set_param(*param.get_elem(0));
    SecondPartAssign_template* implied_template = new SecondPartAssign_template;
    implied_template->set_param(*param.get_elem(1));
    *this = SecondPartAssign_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.SecondPartAssign");
  }
  is_ifpresent = param.get_ifpresent();
}

void SecondPartAssign_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_r99.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.SecondPartAssign");
single_value->field_presence.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.SecondPartAssign");
single_value->field_ext__ra.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.SecondPartAssign");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.SecondPartAssign");
}

boolean SecondPartAssign_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean SecondPartAssign_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

void PacketUlDlAssignUnion::copy_value(const PacketUlDlAssignUnion& other_value)
{
switch (other_value.union_selection) {
case ALT_ul:
field_ul = new PacketUlAssign(*other_value.field_ul);
break;
case ALT_dl:
field_dl = new PacketDlAssign(*other_value.field_dl);
break;
default:
TTCN_error("Assignment of an unbound union value of type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
union_selection = other_value.union_selection;
}

PacketUlDlAssignUnion::PacketUlDlAssignUnion()
{
union_selection = UNBOUND_VALUE;
}

PacketUlDlAssignUnion::PacketUlDlAssignUnion(const PacketUlDlAssignUnion& other_value)
: Base_Type(){
copy_value(other_value);
}

PacketUlDlAssignUnion::~PacketUlDlAssignUnion()
{
clean_up();
}

PacketUlDlAssignUnion& PacketUlDlAssignUnion::operator=(const PacketUlDlAssignUnion& other_value)
{
if (this != &other_value) {
clean_up();
copy_value(other_value);
}
return *this;
}

boolean PacketUlDlAssignUnion::operator==(const PacketUlDlAssignUnion& other_value) const
{
if (union_selection == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
if (other_value.union_selection == UNBOUND_VALUE) TTCN_error("The right operand of comparison is an unbound value of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
if (union_selection != other_value.union_selection) return FALSE;
switch (union_selection) {
case ALT_ul:
return *field_ul == *other_value.field_ul;
case ALT_dl:
return *field_dl == *other_value.field_dl;
default:
return FALSE;
}
}

PacketUlAssign& PacketUlDlAssignUnion::ul()
{
if (union_selection != ALT_ul) {
clean_up();
field_ul = new PacketUlAssign;
union_selection = ALT_ul;
}
return *field_ul;
}

const PacketUlAssign& PacketUlDlAssignUnion::ul() const
{
if (union_selection != ALT_ul) TTCN_error("Using non-selected field ul in a value of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
return *field_ul;
}

PacketDlAssign& PacketUlDlAssignUnion::dl()
{
if (union_selection != ALT_dl) {
clean_up();
field_dl = new PacketDlAssign;
union_selection = ALT_dl;
}
return *field_dl;
}

const PacketDlAssign& PacketUlDlAssignUnion::dl() const
{
if (union_selection != ALT_dl) TTCN_error("Using non-selected field dl in a value of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
return *field_dl;
}

boolean PacketUlDlAssignUnion::ischosen(union_selection_type checked_selection) const
{
if (checked_selection == UNBOUND_VALUE) TTCN_error("Internal error: Performing ischosen() operation on an invalid field of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
return union_selection == checked_selection;
}

boolean PacketUlDlAssignUnion::is_bound() const
{
  return union_selection != UNBOUND_VALUE;
}

boolean PacketUlDlAssignUnion::is_value() const
{
switch (union_selection) {
case UNBOUND_VALUE: return FALSE;
case ALT_ul: return field_ul->is_value();
case ALT_dl: return field_dl->is_value();
default: TTCN_error("Invalid selection in union is_bound");}
}

void PacketUlDlAssignUnion::clean_up()
{
switch (union_selection) {
case ALT_ul:
  delete field_ul;
  break;
case ALT_dl:
  delete field_dl;
  break;
default:
  break;
}
union_selection = UNBOUND_VALUE;
}

void PacketUlDlAssignUnion::log() const
{
switch (union_selection) {
case ALT_ul:
TTCN_Logger::log_event_str("{ ul := ");
field_ul->log();
TTCN_Logger::log_event_str(" }");
break;
case ALT_dl:
TTCN_Logger::log_event_str("{ dl := ");
field_dl->log();
TTCN_Logger::log_event_str(" }");
break;
default:
TTCN_Logger::log_event_unbound();
}
}

void PacketUlDlAssignUnion::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "union value");
  Module_Param_Ptr m_p = &param;
  if (m_p->get_type()==Module_Param::MP_Value_List && m_p->get_size()==0) return;
  if (m_p->get_type()!=Module_Param::MP_Assignment_List) {
    param.error("union value with field name was expected");
  }
  Module_Param* mp_last = m_p->get_elem(m_p->get_size()-1);
  char* last_name = mp_last->get_id()->get_name();
  if (!strcmp(last_name, "ul")) {
    ul().set_param(*mp_last);
    if (!ul().is_bound()) clean_up();
    return;
  }
  if (!strcmp(last_name, "dl")) {
    dl().set_param(*mp_last);
    if (!dl().is_bound()) clean_up();
    return;
  }
  mp_last->error("Field %s does not exist in type @GSM_RestOctets.PacketUlDlAssignUnion.", last_name);
}

void PacketUlDlAssignUnion::set_implicit_omit()
{
switch (union_selection) {
case ALT_ul:
field_ul->set_implicit_omit(); break;
case ALT_dl:
field_dl->set_implicit_omit(); break;
default: break;
}
}

void PacketUlDlAssignUnion::encode_text(Text_Buf& text_buf) const
{
text_buf.push_int(union_selection);
switch (union_selection) {
case ALT_ul:
field_ul->encode_text(text_buf);
break;
case ALT_dl:
field_dl->encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an unbound value of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
}

void PacketUlDlAssignUnion::decode_text(Text_Buf& text_buf)
{
switch ((union_selection_type)text_buf.pull_int().get_val()) {
case ALT_ul:
ul().decode_text(text_buf);
break;
case ALT_dl:
dl().decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: Unrecognized union selector was received for type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
}

void PacketUlDlAssignUnion::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(TRUE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void PacketUlDlAssignUnion::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int PacketUlDlAssignUnion::RAW_decode(
const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, 
raw_order_t top_bit_ord, boolean no_err, int sel_field, boolean, const RAW_Force_Omit* force_omit)
{
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  int decoded_length=0;
  int starting_pos=p_buf.get_pos_bit();
  if(sel_field!=-1){
    switch(sel_field){
    case 0: {
      RAW_Force_Omit field_force_omit(0, force_omit, PacketUlDlAssignUnion_ul_descr_.raw->forceomit);
      decoded_length = ul().RAW_decode(PacketUlDlAssignUnion_ul_descr_, p_buf, limit, top_bit_ord, no_err, -1, TRUE, &field_force_omit);
      break; }
    case 1: {
      RAW_Force_Omit field_force_omit(1, force_omit, PacketUlDlAssignUnion_dl_descr_.raw->forceomit);
      decoded_length = dl().RAW_decode(PacketUlDlAssignUnion_dl_descr_, p_buf, limit, top_bit_ord, no_err, -1, TRUE, &field_force_omit);
      break; }
    default: break;
    }
    return decoded_length + p_buf.increase_pos_padd(p_td.raw->padding) + prepaddlength;
  } else {
      p_buf.set_pos_bit(starting_pos);
      RAW_Force_Omit field_0_force_omit(0, force_omit, PacketUlDlAssignUnion_ul_descr_.raw->forceomit);
      decoded_length = ul().RAW_decode(PacketUlDlAssignUnion_ul_descr_, p_buf, limit, top_bit_ord, TRUE, -1, TRUE, &field_0_force_omit);
      if (decoded_length >= 0) {
         return decoded_length + p_buf.increase_pos_padd(p_td.raw->padding) + prepaddlength;
       }
      p_buf.set_pos_bit(starting_pos);
      RAW_Force_Omit field_1_force_omit(1, force_omit, PacketUlDlAssignUnion_dl_descr_.raw->forceomit);
      decoded_length = dl().RAW_decode(PacketUlDlAssignUnion_dl_descr_, p_buf, limit, top_bit_ord, TRUE, -1, TRUE, &field_1_force_omit);
      if (decoded_length >= 0) {
         return decoded_length + p_buf.increase_pos_padd(p_td.raw->padding) + prepaddlength;
       }
 }
 clean_up();
 return -1;
}

int PacketUlDlAssignUnion::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const
{
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 2;  myleaf.body.node.nodes = init_nodes_of_enc_tree(2);
  memset(myleaf.body.node.nodes, 0, 2 * sizeof(RAW_enc_tree *));
  switch (union_selection) {
  case ALT_ul:
    myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &myleaf.curr_pos, 0, PacketUlDlAssignUnion_ul_descr_.raw);
    encoded_length = field_ul->RAW_encode(PacketUlDlAssignUnion_ul_descr_, *myleaf.body.node.nodes[0]);
    myleaf.body.node.nodes[0]->coding_descr = &PacketUlDlAssignUnion_ul_descr_;
    break;
  case ALT_dl:
    myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &myleaf.curr_pos, 1, PacketUlDlAssignUnion_dl_descr_.raw);
    encoded_length = field_dl->RAW_encode(PacketUlDlAssignUnion_dl_descr_, *myleaf.body.node.nodes[1]);
    myleaf.body.node.nodes[1]->coding_descr = &PacketUlDlAssignUnion_dl_descr_;
    break;
  default:
    TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  }
  return encoded_length;
}

void PacketUlDlAssignUnion_template::copy_value(const PacketUlDlAssignUnion& other_value)
{
single_value.union_selection = other_value.get_selection();
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
single_value.field_ul = new PacketUlAssign_template(other_value.ul());
break;
case PacketUlDlAssignUnion::ALT_dl:
single_value.field_dl = new PacketDlAssign_template(other_value.dl());
break;
default:
TTCN_error("Initializing a template with an unbound value of type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
set_selection(SPECIFIC_VALUE);
}

void PacketUlDlAssignUnion_template::copy_template(const PacketUlDlAssignUnion_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value.union_selection = other_value.single_value.union_selection;
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
single_value.field_ul = new PacketUlAssign_template(*other_value.single_value.field_ul);
break;
case PacketUlDlAssignUnion::ALT_dl:
single_value.field_dl = new PacketDlAssign_template(*other_value.single_value.field_dl);
break;
default:
TTCN_error("Internal error: Invalid union selector in a specific value when copying a template of type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new PacketUlDlAssignUnion_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new PacketUlDlAssignUnion_template(*other_value.implication_.precondition);
implication_.implied_template = new PacketUlDlAssignUnion_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
set_selection(other_value);
}

PacketUlDlAssignUnion_template::PacketUlDlAssignUnion_template()
{
}

PacketUlDlAssignUnion_template::PacketUlDlAssignUnion_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

PacketUlDlAssignUnion_template::PacketUlDlAssignUnion_template(const PacketUlDlAssignUnion& other_value)
{
copy_value(other_value);
}

PacketUlDlAssignUnion_template::PacketUlDlAssignUnion_template(const OPTIONAL<PacketUlDlAssignUnion>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlDlAssignUnion&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of union type @GSM_RestOctets.PacketUlDlAssignUnion from an unbound optional field.");
}
}

PacketUlDlAssignUnion_template::PacketUlDlAssignUnion_template(PacketUlDlAssignUnion_template* p_precondition, PacketUlDlAssignUnion_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

PacketUlDlAssignUnion_template::PacketUlDlAssignUnion_template(Dynamic_Match_Interface<PacketUlDlAssignUnion>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<PacketUlDlAssignUnion>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

PacketUlDlAssignUnion_template::PacketUlDlAssignUnion_template(const PacketUlDlAssignUnion_template& other_value)
: Base_Template(){
copy_template(other_value);
}

PacketUlDlAssignUnion_template::~PacketUlDlAssignUnion_template()
{
clean_up();
}

void PacketUlDlAssignUnion_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
delete single_value.field_ul;
break;
case PacketUlDlAssignUnion::ALT_dl:
delete single_value.field_dl;
default:
break;
}
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

PacketUlDlAssignUnion_template& PacketUlDlAssignUnion_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

PacketUlDlAssignUnion_template& PacketUlDlAssignUnion_template::operator=(const PacketUlDlAssignUnion& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

PacketUlDlAssignUnion_template& PacketUlDlAssignUnion_template::operator=(const OPTIONAL<PacketUlDlAssignUnion>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlDlAssignUnion&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
return *this;
}

PacketUlDlAssignUnion_template& PacketUlDlAssignUnion_template::operator=(const PacketUlDlAssignUnion_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean PacketUlDlAssignUnion_template::match(const PacketUlDlAssignUnion& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
{
PacketUlDlAssignUnion::union_selection_type value_selection = other_value.get_selection();
if (value_selection == PacketUlDlAssignUnion::UNBOUND_VALUE) return FALSE;
if (value_selection != single_value.union_selection) return FALSE;
switch (value_selection) {
case PacketUlDlAssignUnion::ALT_ul:
return single_value.field_ul->match(other_value.ul(), legacy);
case PacketUlDlAssignUnion::ALT_dl:
return single_value.field_dl->match(other_value.dl(), legacy);
default:
TTCN_error("Internal error: Invalid selector in a specific value when matching a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
}
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error ("Matching an uninitialized template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
return FALSE;
}

boolean PacketUlDlAssignUnion_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
return single_value.field_ul->is_value();
case PacketUlDlAssignUnion::ALT_dl:
return single_value.field_dl->is_value();
default:
TTCN_error("Internal error: Invalid selector in a specific value when performing is_value operation on a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
}

PacketUlDlAssignUnion PacketUlDlAssignUnion_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
PacketUlDlAssignUnion ret_val;
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
ret_val.ul() = single_value.field_ul->valueof();
break;
case PacketUlDlAssignUnion::ALT_dl:
ret_val.dl() = single_value.field_dl->valueof();
break;
default:
TTCN_error("Internal error: Invalid selector in a specific value when performing valueof operation on a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
return ret_val;
}

PacketUlDlAssignUnion_template& PacketUlDlAssignUnion_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST && template_selection != CONJUNCTION_MATCH) TTCN_error("Internal error: Accessing a list element of a non-list template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
if (list_index >= value_list.n_values) TTCN_error("Internal error: Index overflow in a value list template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
return value_list.list_value[list_index];
}
void PacketUlDlAssignUnion_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST && template_type != CONJUNCTION_MATCH) TTCN_error ("Internal error: Setting an invalid list for a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new PacketUlDlAssignUnion_template[list_length];
}

PacketUlAssign_template& PacketUlDlAssignUnion_template::ul()
{
if (template_selection != SPECIFIC_VALUE || single_value.union_selection != PacketUlDlAssignUnion::ALT_ul) {
template_sel old_selection = template_selection;
clean_up();
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) single_value.field_ul = new PacketUlAssign_template(ANY_VALUE);
else single_value.field_ul = new PacketUlAssign_template;
single_value.union_selection = PacketUlDlAssignUnion::ALT_ul;
set_selection(SPECIFIC_VALUE);
}
return *single_value.field_ul;
}

const PacketUlAssign_template& PacketUlDlAssignUnion_template::ul() const
{
if (template_selection != SPECIFIC_VALUE) TTCN_error("Accessing field ul in a non-specific template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
if (single_value.union_selection != PacketUlDlAssignUnion::ALT_ul) TTCN_error("Accessing non-selected field ul in a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
return *single_value.field_ul;
}

PacketDlAssign_template& PacketUlDlAssignUnion_template::dl()
{
if (template_selection != SPECIFIC_VALUE || single_value.union_selection != PacketUlDlAssignUnion::ALT_dl) {
template_sel old_selection = template_selection;
clean_up();
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) single_value.field_dl = new PacketDlAssign_template(ANY_VALUE);
else single_value.field_dl = new PacketDlAssign_template;
single_value.union_selection = PacketUlDlAssignUnion::ALT_dl;
set_selection(SPECIFIC_VALUE);
}
return *single_value.field_dl;
}

const PacketDlAssign_template& PacketUlDlAssignUnion_template::dl() const
{
if (template_selection != SPECIFIC_VALUE) TTCN_error("Accessing field dl in a non-specific template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
if (single_value.union_selection != PacketUlDlAssignUnion::ALT_dl) TTCN_error("Accessing non-selected field dl in a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
return *single_value.field_dl;
}

boolean PacketUlDlAssignUnion_template::ischosen(PacketUlDlAssignUnion::union_selection_type checked_selection) const
{
if (checked_selection == PacketUlDlAssignUnion::UNBOUND_VALUE) TTCN_error("Internal error: Performing ischosen() operation on an invalid field of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
switch (template_selection) {
case SPECIFIC_VALUE:
if (single_value.union_selection == PacketUlDlAssignUnion::UNBOUND_VALUE) TTCN_error("Internal error: Invalid selector in a specific value when performing ischosen() operation on a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
return single_value.union_selection == checked_selection;
case VALUE_LIST:
{
if (value_list.n_values < 1)
TTCN_error("Internal error: Performing ischosen() operation on a template of union type @GSM_RestOctets.PacketUlDlAssignUnion containing an empty list.");
boolean ret_val = value_list.list_value[0].ischosen(checked_selection);
for (unsigned int list_count = 1; ret_val == TRUE && list_count < value_list.n_values; list_count++) {
ret_val = value_list.list_value[list_count].ischosen(checked_selection);
}
return ret_val;
}
default:
return FALSE;
}
return FALSE;
}

void PacketUlDlAssignUnion_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
TTCN_Logger::log_event_str("{ ul := ");
single_value.field_ul->log();
TTCN_Logger::log_event_str(" }");
break;
case PacketUlDlAssignUnion::ALT_dl:
TTCN_Logger::log_event_str("{ dl := ");
single_value.field_dl->log();
TTCN_Logger::log_event_str(" }");
break;
default:
TTCN_Logger::log_event_str("<invalid selector>");
}
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void PacketUlDlAssignUnion_template::log_match(const PacketUlDlAssignUnion& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity() && match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
return;
}
if (template_selection == SPECIFIC_VALUE && single_value.union_selection == match_value.get_selection()) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
TTCN_Logger::log_logmatch_info(".ul");
single_value.field_ul->log_match(match_value.ul(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
} else {
TTCN_Logger::log_event_str("{ ul := ");
single_value.field_ul->log_match(match_value.ul(), legacy);
TTCN_Logger::log_event_str(" }");
}
break;
case PacketUlDlAssignUnion::ALT_dl:
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
TTCN_Logger::log_logmatch_info(".dl");
single_value.field_dl->log_match(match_value.dl(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
} else {
TTCN_Logger::log_event_str("{ dl := ");
single_value.field_dl->log_match(match_value.dl(), legacy);
TTCN_Logger::log_event_str(" }");
}
break;
default:
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str("<invalid selector>");
}
} else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void PacketUlDlAssignUnion_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
single_value.field_ul->set_implicit_omit(); break;
case PacketUlDlAssignUnion::ALT_dl:
single_value.field_dl->set_implicit_omit(); break;
default: break;
}
}

void PacketUlDlAssignUnion_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
text_buf.push_int(single_value.union_selection);
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
single_value.field_ul->encode_text(text_buf);
break;
case PacketUlDlAssignUnion::ALT_dl:
single_value.field_dl->encode_text(text_buf);
break;
default:
TTCN_error("Internal error: Invalid selector in a specific value when encoding a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized template of type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
}

void PacketUlDlAssignUnion_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
{
single_value.union_selection = PacketUlDlAssignUnion::UNBOUND_VALUE;
PacketUlDlAssignUnion::union_selection_type new_selection = (PacketUlDlAssignUnion::union_selection_type)text_buf.pull_int().get_val();
switch (new_selection) {
case PacketUlDlAssignUnion::ALT_ul:
single_value.field_ul = new PacketUlAssign_template;
single_value.field_ul->decode_text(text_buf);
break;
case PacketUlDlAssignUnion::ALT_dl:
single_value.field_dl = new PacketDlAssign_template;
single_value.field_dl->decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: Unrecognized union selector was received for a template of type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
single_value.union_selection = new_selection;
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new PacketUlDlAssignUnion_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: Unrecognized selector was received in a template of type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
}

boolean PacketUlDlAssignUnion_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean PacketUlDlAssignUnion_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int v_idx=0; v_idx<value_list.n_values; v_idx++)
if (value_list.list_value[v_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

void PacketUlDlAssignUnion_template::set_param(Module_Param& param)
{
  if (dynamic_cast<Module_Param_Name*>(param.get_id()) != NULL &&
      param.get_id()->next_name()) {
    char* param_field = param.get_id()->get_current_name();
    if (param_field[0] >= '0' && param_field[0] <= '9') {
      param.error("Unexpected array index in module parameter, expected a valid field"
        " name for union template type `@GSM_RestOctets.PacketUlDlAssignUnion'");
    }
    if (strcmp("ul", param_field) == 0) {
      ul().set_param(param);
      return;
    } else if (strcmp("dl", param_field) == 0) {
      dl().set_param(param);
      return;
    } else param.error("Field `%s' not found in union template type `@GSM_RestOctets.PacketUlDlAssignUnion'", param_field);
  }
  param.basic_check(Module_Param::BC_TEMPLATE, "union template");
  Module_Param_Ptr m_p = &param;
  switch (m_p->get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    PacketUlDlAssignUnion_template new_temp;
    new_temp.set_type(m_p->get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (m_p->get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), m_p->get_size());
    for (size_t p_i=0; p_i<m_p->get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*m_p->get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (m_p->get_size()==0) break;
    param.type_error("union template", "@GSM_RestOctets.PacketUlDlAssignUnion");
    break;
  case Module_Param::MP_Assignment_List: {
    Module_Param* mp_last = m_p->get_elem(m_p->get_size()-1);
    char* last_name = mp_last->get_id()->get_name();
    if (!strcmp(last_name, "ul")) {
      ul().set_param(*mp_last);
      break;
    }
    if (!strcmp(last_name, "dl")) {
      dl().set_param(*mp_last);
      break;
    }
    mp_last->error("Field %s does not exist in type @GSM_RestOctets.PacketUlDlAssignUnion.", last_name);
  } break;
  case Module_Param::MP_Implication_Template: {
    PacketUlDlAssignUnion_template* precondition = new PacketUlDlAssignUnion_template;
    precondition->set_param(*m_p->get_elem(0));
    PacketUlDlAssignUnion_template* implied_template = new PacketUlDlAssignUnion_template;
    implied_template->set_param(*m_p->get_elem(1));
    *this = PacketUlDlAssignUnion_template(precondition, implied_template);
  } break;
  default:
    param.type_error("union template", "@GSM_RestOctets.PacketUlDlAssignUnion");
  }
  is_ifpresent = param.get_ifpresent();
}

void PacketUlDlAssignUnion_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
switch (single_value.union_selection) {
case PacketUlDlAssignUnion::ALT_ul:
single_value.field_ul->check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlDlAssignUnion");
return;
case PacketUlDlAssignUnion::ALT_dl:
single_value.field_dl->check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlDlAssignUnion");
return;
default:
TTCN_error("Internal error: Invalid selector in a specific value when performing check_restriction operation on a template of union type @GSM_RestOctets.PacketUlDlAssignUnion.");
}
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.PacketUlDlAssignUnion");
}

PacketUlAssign::PacketUlAssign()
{
}

PacketUlAssign::PacketUlAssign(const BITSTRING& par_presence,
    const OPTIONAL< PacketUlAssignDyn >& par_dynamic,
    const OPTIONAL< PacketUlAssignSgl >& par_single)
  :   field_presence(par_presence),
  field_dynamic(par_dynamic),
  field_single(par_single)
{
}

PacketUlAssign::PacketUlAssign(const PacketUlAssign& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.PacketUlAssign.");
if (other_value.presence().is_bound()) field_presence = other_value.presence();
else field_presence.clean_up();
if (other_value.dynamic().is_bound()) field_dynamic = other_value.dynamic();
else field_dynamic.clean_up();
if (other_value.single().is_bound()) field_single = other_value.single();
else field_single.clean_up();
}

void PacketUlAssign::clean_up()
{
field_presence.clean_up();
field_dynamic.clean_up();
field_single.clean_up();
}

const TTCN_Typedescriptor_t* PacketUlAssign::get_descriptor() const { return &PacketUlAssign_descr_; }
PacketUlAssign& PacketUlAssign::operator=(const PacketUlAssign& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.PacketUlAssign.");
  if (other_value.presence().is_bound()) field_presence = other_value.presence();
  else field_presence.clean_up();
  if (other_value.dynamic().is_bound()) field_dynamic = other_value.dynamic();
  else field_dynamic.clean_up();
  if (other_value.single().is_bound()) field_single = other_value.single();
  else field_single.clean_up();
}
return *this;
}

boolean PacketUlAssign::operator==(const PacketUlAssign& other_value) const
{
return field_presence==other_value.field_presence
  && field_dynamic==other_value.field_dynamic
  && field_single==other_value.field_single;
}

boolean PacketUlAssign::is_bound() const
{
return (field_presence.is_bound())
  || (OPTIONAL_OMIT == field_dynamic.get_selection() || field_dynamic.is_bound())
  || (OPTIONAL_OMIT == field_single.get_selection() || field_single.is_bound());
}
boolean PacketUlAssign::is_value() const
{
return field_presence.is_value()
  && (OPTIONAL_OMIT == field_dynamic.get_selection() || field_dynamic.is_value())
  && (OPTIONAL_OMIT == field_single.get_selection() || field_single.is_value());
}
int PacketUlAssign::size_of() const
{
  int ret_val = 1;
  if (field_dynamic.ispresent()) ret_val++;
  if (field_single.ispresent()) ret_val++;
  return ret_val;
}

void PacketUlAssign::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ presence := ");
field_presence.log();
TTCN_Logger::log_event_str(", dynamic := ");
field_dynamic.log();
TTCN_Logger::log_event_str(", single := ");
field_single.log();
TTCN_Logger::log_event_str(" }");
}

void PacketUlAssign::set_implicit_omit()
{
if (presence().is_bound()) presence().set_implicit_omit();
if (!dynamic().is_bound()) dynamic() = OMIT_VALUE;
else dynamic().set_implicit_omit();
if (!single().is_bound()) single() = OMIT_VALUE;
else single().set_implicit_omit();
}

void PacketUlAssign::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.PacketUlAssign has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) dynamic().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) single().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "dynamic")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          dynamic().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "single")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          single().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketUlAssign: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.PacketUlAssign");
  }
}

void PacketUlAssign::encode_text(Text_Buf& text_buf) const
{
field_presence.encode_text(text_buf);
field_dynamic.encode_text(text_buf);
field_single.encode_text(text_buf);
}

void PacketUlAssign::decode_text(Text_Buf& text_buf)
{
field_presence.decode_text(text_buf);
field_dynamic.decode_text(text_buf);
field_single.decode_text(text_buf);
}

void PacketUlAssign::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void PacketUlAssign::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int PacketUlAssign::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, PacketUlAssign_presence_descr_.raw->forceomit);
  decoded_field_length = field_presence.RAW_decode(PacketUlAssign_presence_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_presence ==  bs_0){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_dynamic = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, PacketUlAssign_dynamic_descr_.raw->forceomit);
  decoded_field_length = field_dynamic().RAW_decode(PacketUlAssign_dynamic_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_dynamic = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_dynamic=OMIT_VALUE;
  if (limit > 0 && field_presence ==  bs_1){
  if (force_omit != NULL && (*force_omit)(2)) {
    field_single = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_2_force_omit(2, force_omit, PacketUlAssign_single_descr_.raw->forceomit);
  decoded_field_length = field_single().RAW_decode(PacketUlAssign_single_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 1) {
  field_single = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_single=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int PacketUlAssign::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 3;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(3);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, PacketUlAssign_presence_descr_.raw);
  if (field_dynamic.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, PacketUlAssign_dynamic_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  if (field_single.ispresent()) {
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, PacketUlAssign_single_descr_.raw);
  }
  else myleaf.body.node.nodes[2] = NULL;
  encoded_length += field_presence.RAW_encode(PacketUlAssign_presence_descr_, *myleaf.body.node.nodes[0]);
  if (field_dynamic.ispresent()) {
  encoded_length += field_dynamic().RAW_encode(PacketUlAssign_dynamic_descr_, *myleaf.body.node.nodes[1]);
  }
  if (field_single.ispresent()) {
  encoded_length += field_single().RAW_encode(PacketUlAssign_single_descr_, *myleaf.body.node.nodes[2]);
  }
  if (field_dynamic.ispresent() && (field_presence !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketUlAssign_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_single.ispresent() && (field_presence !=  bs_1)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_1.RAW_encode(PacketUlAssign_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct PacketUlAssign_template::single_value_struct {
BITSTRING_template field_presence;
PacketUlAssignDyn_template field_dynamic;
PacketUlAssignSgl_template field_single;
};

void PacketUlAssign_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_presence = ANY_VALUE;
single_value->field_dynamic = ANY_OR_OMIT;
single_value->field_single = ANY_OR_OMIT;
}
}
}

void PacketUlAssign_template::copy_value(const PacketUlAssign& other_value)
{
single_value = new single_value_struct;
if (other_value.presence().is_bound()) {
  single_value->field_presence = other_value.presence();
} else {
  single_value->field_presence.clean_up();
}
if (other_value.dynamic().is_bound()) {
  if (other_value.dynamic().ispresent()) single_value->field_dynamic = other_value.dynamic()();
  else single_value->field_dynamic = OMIT_VALUE;
} else {
  single_value->field_dynamic.clean_up();
}
if (other_value.single().is_bound()) {
  if (other_value.single().ispresent()) single_value->field_single = other_value.single()();
  else single_value->field_single = OMIT_VALUE;
} else {
  single_value->field_single.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void PacketUlAssign_template::copy_template(const PacketUlAssign_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.presence().get_selection()) {
single_value->field_presence = other_value.presence();
} else {
single_value->field_presence.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.dynamic().get_selection()) {
single_value->field_dynamic = other_value.dynamic();
} else {
single_value->field_dynamic.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.single().get_selection()) {
single_value->field_single = other_value.single();
} else {
single_value->field_single.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new PacketUlAssign_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new PacketUlAssign_template(*other_value.implication_.precondition);
implication_.implied_template = new PacketUlAssign_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssign.");
break;
}
set_selection(other_value);
}

PacketUlAssign_template::PacketUlAssign_template()
{
}

PacketUlAssign_template::PacketUlAssign_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

PacketUlAssign_template::PacketUlAssign_template(const PacketUlAssign& other_value)
{
copy_value(other_value);
}

PacketUlAssign_template::PacketUlAssign_template(const OPTIONAL<PacketUlAssign>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlAssign&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.PacketUlAssign from an unbound optional field.");
}
}

PacketUlAssign_template::PacketUlAssign_template(PacketUlAssign_template* p_precondition, PacketUlAssign_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

PacketUlAssign_template::PacketUlAssign_template(Dynamic_Match_Interface<PacketUlAssign>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<PacketUlAssign>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

PacketUlAssign_template::PacketUlAssign_template(const PacketUlAssign_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

PacketUlAssign_template::~PacketUlAssign_template()
{
clean_up();
}

PacketUlAssign_template& PacketUlAssign_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

PacketUlAssign_template& PacketUlAssign_template::operator=(const PacketUlAssign& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

PacketUlAssign_template& PacketUlAssign_template::operator=(const OPTIONAL<PacketUlAssign>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlAssign&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.PacketUlAssign.");
}
return *this;
}

PacketUlAssign_template& PacketUlAssign_template::operator=(const PacketUlAssign_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean PacketUlAssign_template::match(const PacketUlAssign& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.presence().is_bound()) return FALSE;
if(!single_value->field_presence.match(other_value.presence(), legacy))return FALSE;
if(!other_value.dynamic().is_bound()) return FALSE;
if((other_value.dynamic().ispresent() ? !single_value->field_dynamic.match((const PacketUlAssignDyn&)other_value.dynamic(), legacy) : !single_value->field_dynamic.match_omit(legacy)))return FALSE;
if(!other_value.single().is_bound()) return FALSE;
if((other_value.single().ispresent() ? !single_value->field_single.match((const PacketUlAssignSgl&)other_value.single(), legacy) : !single_value->field_single.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssign.");
}
return FALSE;
}

boolean PacketUlAssign_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_presence.is_bound()
 || (single_value->field_dynamic.is_omit() || single_value->field_dynamic.is_bound())
 || (single_value->field_single.is_omit() || single_value->field_single.is_bound());
}

boolean PacketUlAssign_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_presence.is_value()
 && (single_value->field_dynamic.is_omit() || single_value->field_dynamic.is_value())
 && (single_value->field_single.is_omit() || single_value->field_single.is_value());
}

void PacketUlAssign_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

PacketUlAssign PacketUlAssign_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.PacketUlAssign.");
PacketUlAssign ret_val;
if (single_value->field_presence.is_bound()) {
ret_val.presence() = single_value->field_presence.valueof();
}
if (single_value->field_dynamic.is_omit()) ret_val.dynamic() = OMIT_VALUE;
else if (single_value->field_dynamic.is_bound()) {
ret_val.dynamic() = single_value->field_dynamic.valueof();
}
if (single_value->field_single.is_omit()) ret_val.single() = OMIT_VALUE;
else if (single_value->field_single.is_bound()) {
ret_val.single() = single_value->field_single.valueof();
}
return ret_val;
}

void PacketUlAssign_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.PacketUlAssign.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new PacketUlAssign_template[list_length];
}

PacketUlAssign_template& PacketUlAssign_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.PacketUlAssign.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.PacketUlAssign.");
return value_list.list_value[list_index];
}

BITSTRING_template& PacketUlAssign_template::presence()
{
set_specific();
return single_value->field_presence;
}

const BITSTRING_template& PacketUlAssign_template::presence() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field presence of a non-specific template of type @GSM_RestOctets.PacketUlAssign.");
return single_value->field_presence;
}

PacketUlAssignDyn_template& PacketUlAssign_template::dynamic()
{
set_specific();
return single_value->field_dynamic;
}

const PacketUlAssignDyn_template& PacketUlAssign_template::dynamic() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field dynamic of a non-specific template of type @GSM_RestOctets.PacketUlAssign.");
return single_value->field_dynamic;
}

PacketUlAssignSgl_template& PacketUlAssign_template::single()
{
set_specific();
return single_value->field_single;
}

const PacketUlAssignSgl_template& PacketUlAssign_template::single() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field single of a non-specific template of type @GSM_RestOctets.PacketUlAssign.");
return single_value->field_single;
}

int PacketUlAssign_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssign which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 1;
      if (single_value->field_dynamic.is_present()) ret_val++;
      if (single_value->field_single.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssign containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssign containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssign containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssign containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssign containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssign containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssign containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssign containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssign.");
  }
  return 0;
}

void PacketUlAssign_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log();
TTCN_Logger::log_event_str(", dynamic := ");
single_value->field_dynamic.log();
TTCN_Logger::log_event_str(", single := ");
single_value->field_single.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void PacketUlAssign_template::log_match(const PacketUlAssign& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_presence.match(match_value.presence(), legacy)){
TTCN_Logger::log_logmatch_info(".presence");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.dynamic().ispresent()){
if(!single_value->field_dynamic.match(match_value.dynamic(), legacy)){
TTCN_Logger::log_logmatch_info(".dynamic");
single_value->field_dynamic.log_match(match_value.dynamic(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_dynamic.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".dynamic := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_dynamic.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.single().ispresent()){
if(!single_value->field_single.match(match_value.single(), legacy)){
TTCN_Logger::log_logmatch_info(".single");
single_value->field_single.log_match(match_value.single(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_single.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".single := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_single.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::log_event_str(", dynamic := ");
if (match_value.dynamic().ispresent()) {
single_value->field_dynamic.log_match(match_value.dynamic(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_dynamic.log();
if (single_value->field_dynamic.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", single := ");
if (match_value.single().ispresent()) {
single_value->field_single.log_match(match_value.single(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_single.log();
if (single_value->field_single.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void PacketUlAssign_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (presence().is_bound()) presence().set_implicit_omit();
if (!dynamic().is_bound()) dynamic() = OMIT_VALUE;
else dynamic().set_implicit_omit();
if (!single().is_bound()) single() = OMIT_VALUE;
else single().set_implicit_omit();
}

void PacketUlAssign_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_presence.encode_text(text_buf);
single_value->field_dynamic.encode_text(text_buf);
single_value->field_single.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssign.");
}
}

void PacketUlAssign_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_presence.decode_text(text_buf);
single_value->field_dynamic.decode_text(text_buf);
single_value->field_single.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new PacketUlAssign_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.PacketUlAssign.");
}
}

void PacketUlAssign_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    PacketUlAssign_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.PacketUlAssign has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) dynamic().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) single().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "dynamic")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          dynamic().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "single")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          single().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketUlAssign: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    PacketUlAssign_template* precondition = new PacketUlAssign_template;
    precondition->set_param(*param.get_elem(0));
    PacketUlAssign_template* implied_template = new PacketUlAssign_template;
    implied_template->set_param(*param.get_elem(1));
    *this = PacketUlAssign_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.PacketUlAssign");
  }
  is_ifpresent = param.get_ifpresent();
}

void PacketUlAssign_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_presence.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssign");
single_value->field_dynamic.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssign");
single_value->field_single.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssign");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.PacketUlAssign");
}

boolean PacketUlAssign_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean PacketUlAssign_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

PacketUlAssignDyn::PacketUlAssignDyn()
{
}

PacketUlAssignDyn::PacketUlAssignDyn(const INTEGER& par_tfi__assignment,
    const BITSTRING& par_polling,
    const BITSTRING& par_spare,
    const INTEGER& par_usf,
    const BITSTRING& par_usf__granularity,
    const BITSTRING& par_p0__present,
    const OPTIONAL< INTEGER >& par_p0,
    const OPTIONAL< BITSTRING >& par_pr__mode,
    const RLCMAC__CSN1__Types::ChCodingCommand& par_ch__coding__cmd,
    const BITSTRING& par_tlli__block__chan__coding,
    const BITSTRING& par_alpha__present,
    const OPTIONAL< INTEGER >& par_alpha,
    const INTEGER& par_gamma,
    const BITSTRING& par_ta__index__present,
    const OPTIONAL< INTEGER >& par_ta__index,
    const BITSTRING& par_tbf__starting__time__present,
    const OPTIONAL< TbfStartingTime >& par_tbf__starting__time)
  :   field_tfi__assignment(par_tfi__assignment),
  field_polling(par_polling),
  field_spare(par_spare),
  field_usf(par_usf),
  field_usf__granularity(par_usf__granularity),
  field_p0__present(par_p0__present),
  field_p0(par_p0),
  field_pr__mode(par_pr__mode),
  field_ch__coding__cmd(par_ch__coding__cmd),
  field_tlli__block__chan__coding(par_tlli__block__chan__coding),
  field_alpha__present(par_alpha__present),
  field_alpha(par_alpha),
  field_gamma(par_gamma),
  field_ta__index__present(par_ta__index__present),
  field_ta__index(par_ta__index),
  field_tbf__starting__time__present(par_tbf__starting__time__present),
  field_tbf__starting__time(par_tbf__starting__time)
{
}

PacketUlAssignDyn::PacketUlAssignDyn(const PacketUlAssignDyn& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.PacketUlAssignDyn.");
if (other_value.tfi__assignment().is_bound()) field_tfi__assignment = other_value.tfi__assignment();
else field_tfi__assignment.clean_up();
if (other_value.polling().is_bound()) field_polling = other_value.polling();
else field_polling.clean_up();
if (other_value.spare().is_bound()) field_spare = other_value.spare();
else field_spare.clean_up();
if (other_value.usf().is_bound()) field_usf = other_value.usf();
else field_usf.clean_up();
if (other_value.usf__granularity().is_bound()) field_usf__granularity = other_value.usf__granularity();
else field_usf__granularity.clean_up();
if (other_value.p0__present().is_bound()) field_p0__present = other_value.p0__present();
else field_p0__present.clean_up();
if (other_value.p0().is_bound()) field_p0 = other_value.p0();
else field_p0.clean_up();
if (other_value.pr__mode().is_bound()) field_pr__mode = other_value.pr__mode();
else field_pr__mode.clean_up();
if (other_value.ch__coding__cmd().is_bound()) field_ch__coding__cmd = other_value.ch__coding__cmd();
else field_ch__coding__cmd.clean_up();
if (other_value.tlli__block__chan__coding().is_bound()) field_tlli__block__chan__coding = other_value.tlli__block__chan__coding();
else field_tlli__block__chan__coding.clean_up();
if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
else field_alpha__present.clean_up();
if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
else field_alpha.clean_up();
if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
else field_gamma.clean_up();
if (other_value.ta__index__present().is_bound()) field_ta__index__present = other_value.ta__index__present();
else field_ta__index__present.clean_up();
if (other_value.ta__index().is_bound()) field_ta__index = other_value.ta__index();
else field_ta__index.clean_up();
if (other_value.tbf__starting__time__present().is_bound()) field_tbf__starting__time__present = other_value.tbf__starting__time__present();
else field_tbf__starting__time__present.clean_up();
if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
else field_tbf__starting__time.clean_up();
}

void PacketUlAssignDyn::clean_up()
{
field_tfi__assignment.clean_up();
field_polling.clean_up();
field_spare.clean_up();
field_usf.clean_up();
field_usf__granularity.clean_up();
field_p0__present.clean_up();
field_p0.clean_up();
field_pr__mode.clean_up();
field_ch__coding__cmd.clean_up();
field_tlli__block__chan__coding.clean_up();
field_alpha__present.clean_up();
field_alpha.clean_up();
field_gamma.clean_up();
field_ta__index__present.clean_up();
field_ta__index.clean_up();
field_tbf__starting__time__present.clean_up();
field_tbf__starting__time.clean_up();
}

const TTCN_Typedescriptor_t* PacketUlAssignDyn::get_descriptor() const { return &PacketUlAssignDyn_descr_; }
PacketUlAssignDyn& PacketUlAssignDyn::operator=(const PacketUlAssignDyn& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.PacketUlAssignDyn.");
  if (other_value.tfi__assignment().is_bound()) field_tfi__assignment = other_value.tfi__assignment();
  else field_tfi__assignment.clean_up();
  if (other_value.polling().is_bound()) field_polling = other_value.polling();
  else field_polling.clean_up();
  if (other_value.spare().is_bound()) field_spare = other_value.spare();
  else field_spare.clean_up();
  if (other_value.usf().is_bound()) field_usf = other_value.usf();
  else field_usf.clean_up();
  if (other_value.usf__granularity().is_bound()) field_usf__granularity = other_value.usf__granularity();
  else field_usf__granularity.clean_up();
  if (other_value.p0__present().is_bound()) field_p0__present = other_value.p0__present();
  else field_p0__present.clean_up();
  if (other_value.p0().is_bound()) field_p0 = other_value.p0();
  else field_p0.clean_up();
  if (other_value.pr__mode().is_bound()) field_pr__mode = other_value.pr__mode();
  else field_pr__mode.clean_up();
  if (other_value.ch__coding__cmd().is_bound()) field_ch__coding__cmd = other_value.ch__coding__cmd();
  else field_ch__coding__cmd.clean_up();
  if (other_value.tlli__block__chan__coding().is_bound()) field_tlli__block__chan__coding = other_value.tlli__block__chan__coding();
  else field_tlli__block__chan__coding.clean_up();
  if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
  else field_alpha__present.clean_up();
  if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
  else field_alpha.clean_up();
  if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
  else field_gamma.clean_up();
  if (other_value.ta__index__present().is_bound()) field_ta__index__present = other_value.ta__index__present();
  else field_ta__index__present.clean_up();
  if (other_value.ta__index().is_bound()) field_ta__index = other_value.ta__index();
  else field_ta__index.clean_up();
  if (other_value.tbf__starting__time__present().is_bound()) field_tbf__starting__time__present = other_value.tbf__starting__time__present();
  else field_tbf__starting__time__present.clean_up();
  if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
  else field_tbf__starting__time.clean_up();
}
return *this;
}

boolean PacketUlAssignDyn::operator==(const PacketUlAssignDyn& other_value) const
{
return field_tfi__assignment==other_value.field_tfi__assignment
  && field_polling==other_value.field_polling
  && field_spare==other_value.field_spare
  && field_usf==other_value.field_usf
  && field_usf__granularity==other_value.field_usf__granularity
  && field_p0__present==other_value.field_p0__present
  && field_p0==other_value.field_p0
  && field_pr__mode==other_value.field_pr__mode
  && field_ch__coding__cmd==other_value.field_ch__coding__cmd
  && field_tlli__block__chan__coding==other_value.field_tlli__block__chan__coding
  && field_alpha__present==other_value.field_alpha__present
  && field_alpha==other_value.field_alpha
  && field_gamma==other_value.field_gamma
  && field_ta__index__present==other_value.field_ta__index__present
  && field_ta__index==other_value.field_ta__index
  && field_tbf__starting__time__present==other_value.field_tbf__starting__time__present
  && field_tbf__starting__time==other_value.field_tbf__starting__time;
}

boolean PacketUlAssignDyn::is_bound() const
{
return (field_tfi__assignment.is_bound())
  || (field_polling.is_bound())
  || (field_spare.is_bound())
  || (field_usf.is_bound())
  || (field_usf__granularity.is_bound())
  || (field_p0__present.is_bound())
  || (OPTIONAL_OMIT == field_p0.get_selection() || field_p0.is_bound())
  || (OPTIONAL_OMIT == field_pr__mode.get_selection() || field_pr__mode.is_bound())
  || (field_ch__coding__cmd.is_bound())
  || (field_tlli__block__chan__coding.is_bound())
  || (field_alpha__present.is_bound())
  || (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_bound())
  || (field_gamma.is_bound())
  || (field_ta__index__present.is_bound())
  || (OPTIONAL_OMIT == field_ta__index.get_selection() || field_ta__index.is_bound())
  || (field_tbf__starting__time__present.is_bound())
  || (OPTIONAL_OMIT == field_tbf__starting__time.get_selection() || field_tbf__starting__time.is_bound());
}
boolean PacketUlAssignDyn::is_value() const
{
return field_tfi__assignment.is_value()
  && field_polling.is_value()
  && field_spare.is_value()
  && field_usf.is_value()
  && field_usf__granularity.is_value()
  && field_p0__present.is_value()
  && (OPTIONAL_OMIT == field_p0.get_selection() || field_p0.is_value())
  && (OPTIONAL_OMIT == field_pr__mode.get_selection() || field_pr__mode.is_value())
  && field_ch__coding__cmd.is_value()
  && field_tlli__block__chan__coding.is_value()
  && field_alpha__present.is_value()
  && (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_value())
  && field_gamma.is_value()
  && field_ta__index__present.is_value()
  && (OPTIONAL_OMIT == field_ta__index.get_selection() || field_ta__index.is_value())
  && field_tbf__starting__time__present.is_value()
  && (OPTIONAL_OMIT == field_tbf__starting__time.get_selection() || field_tbf__starting__time.is_value());
}
int PacketUlAssignDyn::size_of() const
{
  int ret_val = 12;
  if (field_p0.ispresent()) ret_val++;
  if (field_pr__mode.ispresent()) ret_val++;
  if (field_alpha.ispresent()) ret_val++;
  if (field_ta__index.ispresent()) ret_val++;
  if (field_tbf__starting__time.ispresent()) ret_val++;
  return ret_val;
}

void PacketUlAssignDyn::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ tfi_assignment := ");
field_tfi__assignment.log();
TTCN_Logger::log_event_str(", polling := ");
field_polling.log();
TTCN_Logger::log_event_str(", spare := ");
field_spare.log();
TTCN_Logger::log_event_str(", usf := ");
field_usf.log();
TTCN_Logger::log_event_str(", usf_granularity := ");
field_usf__granularity.log();
TTCN_Logger::log_event_str(", p0_present := ");
field_p0__present.log();
TTCN_Logger::log_event_str(", p0 := ");
field_p0.log();
TTCN_Logger::log_event_str(", pr_mode := ");
field_pr__mode.log();
TTCN_Logger::log_event_str(", ch_coding_cmd := ");
field_ch__coding__cmd.log();
TTCN_Logger::log_event_str(", tlli_block_chan_coding := ");
field_tlli__block__chan__coding.log();
TTCN_Logger::log_event_str(", alpha_present := ");
field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
field_gamma.log();
TTCN_Logger::log_event_str(", ta_index_present := ");
field_ta__index__present.log();
TTCN_Logger::log_event_str(", ta_index := ");
field_ta__index.log();
TTCN_Logger::log_event_str(", tbf_starting_time_present := ");
field_tbf__starting__time__present.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
field_tbf__starting__time.log();
TTCN_Logger::log_event_str(" }");
}

void PacketUlAssignDyn::set_implicit_omit()
{
if (tfi__assignment().is_bound()) tfi__assignment().set_implicit_omit();
if (polling().is_bound()) polling().set_implicit_omit();
if (spare().is_bound()) spare().set_implicit_omit();
if (usf().is_bound()) usf().set_implicit_omit();
if (usf__granularity().is_bound()) usf__granularity().set_implicit_omit();
if (p0__present().is_bound()) p0__present().set_implicit_omit();
if (!p0().is_bound()) p0() = OMIT_VALUE;
else p0().set_implicit_omit();
if (!pr__mode().is_bound()) pr__mode() = OMIT_VALUE;
else pr__mode().set_implicit_omit();
if (ch__coding__cmd().is_bound()) ch__coding__cmd().set_implicit_omit();
if (tlli__block__chan__coding().is_bound()) tlli__block__chan__coding().set_implicit_omit();
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (ta__index__present().is_bound()) ta__index__present().set_implicit_omit();
if (!ta__index().is_bound()) ta__index() = OMIT_VALUE;
else ta__index().set_implicit_omit();
if (tbf__starting__time__present().is_bound()) tbf__starting__time__present().set_implicit_omit();
if (!tbf__starting__time().is_bound()) tbf__starting__time() = OMIT_VALUE;
else tbf__starting__time().set_implicit_omit();
}

void PacketUlAssignDyn::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (17<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.PacketUlAssignDyn has 17 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) tfi__assignment().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) polling().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) spare().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) usf().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) usf__granularity().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) p0__present().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) p0().set_param(*param.get_elem(6));
    if (param.get_size()>7 && param.get_elem(7)->get_type()!=Module_Param::MP_NotUsed) pr__mode().set_param(*param.get_elem(7));
    if (param.get_size()>8 && param.get_elem(8)->get_type()!=Module_Param::MP_NotUsed) ch__coding__cmd().set_param(*param.get_elem(8));
    if (param.get_size()>9 && param.get_elem(9)->get_type()!=Module_Param::MP_NotUsed) tlli__block__chan__coding().set_param(*param.get_elem(9));
    if (param.get_size()>10 && param.get_elem(10)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(10));
    if (param.get_size()>11 && param.get_elem(11)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(11));
    if (param.get_size()>12 && param.get_elem(12)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(12));
    if (param.get_size()>13 && param.get_elem(13)->get_type()!=Module_Param::MP_NotUsed) ta__index__present().set_param(*param.get_elem(13));
    if (param.get_size()>14 && param.get_elem(14)->get_type()!=Module_Param::MP_NotUsed) ta__index().set_param(*param.get_elem(14));
    if (param.get_size()>15 && param.get_elem(15)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time__present().set_param(*param.get_elem(15));
    if (param.get_size()>16 && param.get_elem(16)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(16));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tfi_assignment")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tfi__assignment().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "polling")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          polling().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "spare")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          spare().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "usf")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          usf().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "usf_granularity")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          usf__granularity().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pr_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pr__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ch_coding_cmd")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ch__coding__cmd().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tlli_block_chan_coding")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tlli__block__chan__coding().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketUlAssignDyn: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.PacketUlAssignDyn");
  }
}

void PacketUlAssignDyn::encode_text(Text_Buf& text_buf) const
{
field_tfi__assignment.encode_text(text_buf);
field_polling.encode_text(text_buf);
field_spare.encode_text(text_buf);
field_usf.encode_text(text_buf);
field_usf__granularity.encode_text(text_buf);
field_p0__present.encode_text(text_buf);
field_p0.encode_text(text_buf);
field_pr__mode.encode_text(text_buf);
field_ch__coding__cmd.encode_text(text_buf);
field_tlli__block__chan__coding.encode_text(text_buf);
field_alpha__present.encode_text(text_buf);
field_alpha.encode_text(text_buf);
field_gamma.encode_text(text_buf);
field_ta__index__present.encode_text(text_buf);
field_ta__index.encode_text(text_buf);
field_tbf__starting__time__present.encode_text(text_buf);
field_tbf__starting__time.encode_text(text_buf);
}

void PacketUlAssignDyn::decode_text(Text_Buf& text_buf)
{
field_tfi__assignment.decode_text(text_buf);
field_polling.decode_text(text_buf);
field_spare.decode_text(text_buf);
field_usf.decode_text(text_buf);
field_usf__granularity.decode_text(text_buf);
field_p0__present.decode_text(text_buf);
field_p0.decode_text(text_buf);
field_pr__mode.decode_text(text_buf);
field_ch__coding__cmd.decode_text(text_buf);
field_tlli__block__chan__coding.decode_text(text_buf);
field_alpha__present.decode_text(text_buf);
field_alpha.decode_text(text_buf);
field_gamma.decode_text(text_buf);
field_ta__index__present.decode_text(text_buf);
field_ta__index.decode_text(text_buf);
field_tbf__starting__time__present.decode_text(text_buf);
field_tbf__starting__time.decode_text(text_buf);
}

void PacketUlAssignDyn::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void PacketUlAssignDyn::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int PacketUlAssignDyn::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, PacketUlAssignDyn_tfi__assignment_descr_.raw->forceomit);
  decoded_field_length = field_tfi__assignment.RAW_decode(PacketUlAssignDyn_tfi__assignment_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_1_force_omit(1, force_omit, PacketUlAssignDyn_polling_descr_.raw->forceomit);
  decoded_field_length = field_polling.RAW_decode(PacketUlAssignDyn_polling_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_2_force_omit(2, force_omit, PacketUlAssignDyn_spare_descr_.raw->forceomit);
  decoded_field_length = field_spare.RAW_decode(PacketUlAssignDyn_spare_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_3_force_omit(3, force_omit, PacketUlAssignDyn_usf_descr_.raw->forceomit);
  decoded_field_length = field_usf.RAW_decode(PacketUlAssignDyn_usf_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_3_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_4_force_omit(4, force_omit, PacketUlAssignDyn_usf__granularity_descr_.raw->forceomit);
  decoded_field_length = field_usf__granularity.RAW_decode(PacketUlAssignDyn_usf__granularity_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_4_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_5_force_omit(5, force_omit, PacketUlAssignDyn_p0__present_descr_.raw->forceomit);
  decoded_field_length = field_p0__present.RAW_decode(PacketUlAssignDyn_p0__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_5_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_p0__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(6)) {
    field_p0 = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_6_force_omit(6, force_omit, PacketUlAssignDyn_p0_descr_.raw->forceomit);
  decoded_field_length = field_p0().RAW_decode(PacketUlAssignDyn_p0_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_6_force_omit);
  if (decoded_field_length < 1) {
  field_p0 = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_p0=OMIT_VALUE;
  if (limit > 0 && field_p0__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(7)) {
    field_pr__mode = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_7_force_omit(7, force_omit, PacketUlAssignDyn_pr__mode_descr_.raw->forceomit);
  decoded_field_length = field_pr__mode().RAW_decode(PacketUlAssignDyn_pr__mode_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_7_force_omit);
  if (decoded_field_length < 1) {
  field_pr__mode = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_pr__mode=OMIT_VALUE;
  RAW_Force_Omit field_8_force_omit(8, force_omit, PacketUlAssignDyn_ch__coding__cmd_descr_.raw->forceomit);
  decoded_field_length = field_ch__coding__cmd.RAW_decode(PacketUlAssignDyn_ch__coding__cmd_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_8_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_9_force_omit(9, force_omit, PacketUlAssignDyn_tlli__block__chan__coding_descr_.raw->forceomit);
  decoded_field_length = field_tlli__block__chan__coding.RAW_decode(PacketUlAssignDyn_tlli__block__chan__coding_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_9_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_10_force_omit(10, force_omit, PacketUlAssignDyn_alpha__present_descr_.raw->forceomit);
  decoded_field_length = field_alpha__present.RAW_decode(PacketUlAssignDyn_alpha__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_10_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_alpha__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(11)) {
    field_alpha = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_11_force_omit(11, force_omit, PacketUlAssignDyn_alpha_descr_.raw->forceomit);
  decoded_field_length = field_alpha().RAW_decode(PacketUlAssignDyn_alpha_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_11_force_omit);
  if (decoded_field_length < 1) {
  field_alpha = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_alpha=OMIT_VALUE;
  RAW_Force_Omit field_12_force_omit(12, force_omit, PacketUlAssignDyn_gamma_descr_.raw->forceomit);
  decoded_field_length = field_gamma.RAW_decode(PacketUlAssignDyn_gamma_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_12_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_13_force_omit(13, force_omit, PacketUlAssignDyn_ta__index__present_descr_.raw->forceomit);
  decoded_field_length = field_ta__index__present.RAW_decode(PacketUlAssignDyn_ta__index__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_13_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_ta__index__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(14)) {
    field_ta__index = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_14_force_omit(14, force_omit, PacketUlAssignDyn_ta__index_descr_.raw->forceomit);
  decoded_field_length = field_ta__index().RAW_decode(PacketUlAssignDyn_ta__index_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_14_force_omit);
  if (decoded_field_length < 1) {
  field_ta__index = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_ta__index=OMIT_VALUE;
  RAW_Force_Omit field_15_force_omit(15, force_omit, PacketUlAssignDyn_tbf__starting__time__present_descr_.raw->forceomit);
  decoded_field_length = field_tbf__starting__time__present.RAW_decode(PacketUlAssignDyn_tbf__starting__time__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_15_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_tbf__starting__time__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(16)) {
    field_tbf__starting__time = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_16_force_omit(16, force_omit, PacketUlAssignDyn_tbf__starting__time_descr_.raw->forceomit);
  decoded_field_length = field_tbf__starting__time().RAW_decode(PacketUlAssignDyn_tbf__starting__time_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_16_force_omit);
  if (decoded_field_length < 1) {
  field_tbf__starting__time = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_tbf__starting__time=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int PacketUlAssignDyn::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 17;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(17);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, PacketUlAssignDyn_tfi__assignment_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, PacketUlAssignDyn_polling_descr_.raw);
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, PacketUlAssignDyn_spare_descr_.raw);
  myleaf.body.node.nodes[3] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 3, PacketUlAssignDyn_usf_descr_.raw);
  myleaf.body.node.nodes[4] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 4, PacketUlAssignDyn_usf__granularity_descr_.raw);
  myleaf.body.node.nodes[5] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 5, PacketUlAssignDyn_p0__present_descr_.raw);
  if (field_p0.ispresent()) {
  myleaf.body.node.nodes[6] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 6, PacketUlAssignDyn_p0_descr_.raw);
  }
  else myleaf.body.node.nodes[6] = NULL;
  if (field_pr__mode.ispresent()) {
  myleaf.body.node.nodes[7] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 7, PacketUlAssignDyn_pr__mode_descr_.raw);
  }
  else myleaf.body.node.nodes[7] = NULL;
  myleaf.body.node.nodes[8] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 8, PacketUlAssignDyn_ch__coding__cmd_descr_.raw);
  myleaf.body.node.nodes[9] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 9, PacketUlAssignDyn_tlli__block__chan__coding_descr_.raw);
  myleaf.body.node.nodes[10] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 10, PacketUlAssignDyn_alpha__present_descr_.raw);
  if (field_alpha.ispresent()) {
  myleaf.body.node.nodes[11] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 11, PacketUlAssignDyn_alpha_descr_.raw);
  }
  else myleaf.body.node.nodes[11] = NULL;
  myleaf.body.node.nodes[12] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 12, PacketUlAssignDyn_gamma_descr_.raw);
  myleaf.body.node.nodes[13] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 13, PacketUlAssignDyn_ta__index__present_descr_.raw);
  if (field_ta__index.ispresent()) {
  myleaf.body.node.nodes[14] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 14, PacketUlAssignDyn_ta__index_descr_.raw);
  }
  else myleaf.body.node.nodes[14] = NULL;
  myleaf.body.node.nodes[15] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 15, PacketUlAssignDyn_tbf__starting__time__present_descr_.raw);
  if (field_tbf__starting__time.ispresent()) {
  myleaf.body.node.nodes[16] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 16, PacketUlAssignDyn_tbf__starting__time_descr_.raw);
  }
  else myleaf.body.node.nodes[16] = NULL;
  encoded_length += field_tfi__assignment.RAW_encode(PacketUlAssignDyn_tfi__assignment_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_polling.RAW_encode(PacketUlAssignDyn_polling_descr_, *myleaf.body.node.nodes[1]);
  encoded_length += field_spare.RAW_encode(PacketUlAssignDyn_spare_descr_, *myleaf.body.node.nodes[2]);
  encoded_length += field_usf.RAW_encode(PacketUlAssignDyn_usf_descr_, *myleaf.body.node.nodes[3]);
  encoded_length += field_usf__granularity.RAW_encode(PacketUlAssignDyn_usf__granularity_descr_, *myleaf.body.node.nodes[4]);
  encoded_length += field_p0__present.RAW_encode(PacketUlAssignDyn_p0__present_descr_, *myleaf.body.node.nodes[5]);
  if (field_p0.ispresent()) {
  encoded_length += field_p0().RAW_encode(PacketUlAssignDyn_p0_descr_, *myleaf.body.node.nodes[6]);
  }
  if (field_pr__mode.ispresent()) {
  encoded_length += field_pr__mode().RAW_encode(PacketUlAssignDyn_pr__mode_descr_, *myleaf.body.node.nodes[7]);
  }
  encoded_length += field_ch__coding__cmd.RAW_encode(PacketUlAssignDyn_ch__coding__cmd_descr_, *myleaf.body.node.nodes[8]);
  encoded_length += field_tlli__block__chan__coding.RAW_encode(PacketUlAssignDyn_tlli__block__chan__coding_descr_, *myleaf.body.node.nodes[9]);
  encoded_length += field_alpha__present.RAW_encode(PacketUlAssignDyn_alpha__present_descr_, *myleaf.body.node.nodes[10]);
  if (field_alpha.ispresent()) {
  encoded_length += field_alpha().RAW_encode(PacketUlAssignDyn_alpha_descr_, *myleaf.body.node.nodes[11]);
  }
  encoded_length += field_gamma.RAW_encode(PacketUlAssignDyn_gamma_descr_, *myleaf.body.node.nodes[12]);
  encoded_length += field_ta__index__present.RAW_encode(PacketUlAssignDyn_ta__index__present_descr_, *myleaf.body.node.nodes[13]);
  if (field_ta__index.ispresent()) {
  encoded_length += field_ta__index().RAW_encode(PacketUlAssignDyn_ta__index_descr_, *myleaf.body.node.nodes[14]);
  }
  encoded_length += field_tbf__starting__time__present.RAW_encode(PacketUlAssignDyn_tbf__starting__time__present_descr_, *myleaf.body.node.nodes[15]);
  if (field_tbf__starting__time.ispresent()) {
  encoded_length += field_tbf__starting__time().RAW_encode(PacketUlAssignDyn_tbf__starting__time_descr_, *myleaf.body.node.nodes[16]);
  }
  if (field_p0.ispresent() && (field_p0__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={5};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketUlAssignDyn_p0__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_pr__mode.ispresent() && (field_p0__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={5};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketUlAssignDyn_p0__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_alpha.ispresent() && (field_alpha__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={10};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketUlAssignDyn_alpha__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_ta__index.ispresent() && (field_ta__index__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={13};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketUlAssignDyn_ta__index__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_tbf__starting__time.ispresent() && (field_tbf__starting__time__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={15};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketUlAssignDyn_tbf__starting__time__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct PacketUlAssignDyn_template::single_value_struct {
INTEGER_template field_tfi__assignment;
BITSTRING_template field_polling;
BITSTRING_template field_spare;
INTEGER_template field_usf;
BITSTRING_template field_usf__granularity;
BITSTRING_template field_p0__present;
INTEGER_template field_p0;
BITSTRING_template field_pr__mode;
RLCMAC__CSN1__Types::ChCodingCommand_template field_ch__coding__cmd;
BITSTRING_template field_tlli__block__chan__coding;
BITSTRING_template field_alpha__present;
INTEGER_template field_alpha;
INTEGER_template field_gamma;
BITSTRING_template field_ta__index__present;
INTEGER_template field_ta__index;
BITSTRING_template field_tbf__starting__time__present;
TbfStartingTime_template field_tbf__starting__time;
};

void PacketUlAssignDyn_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_tfi__assignment = ANY_VALUE;
single_value->field_polling = ANY_VALUE;
single_value->field_spare = ANY_VALUE;
single_value->field_usf = ANY_VALUE;
single_value->field_usf__granularity = ANY_VALUE;
single_value->field_p0__present = ANY_VALUE;
single_value->field_p0 = ANY_OR_OMIT;
single_value->field_pr__mode = ANY_OR_OMIT;
single_value->field_ch__coding__cmd = ANY_VALUE;
single_value->field_tlli__block__chan__coding = ANY_VALUE;
single_value->field_alpha__present = ANY_VALUE;
single_value->field_alpha = ANY_OR_OMIT;
single_value->field_gamma = ANY_VALUE;
single_value->field_ta__index__present = ANY_VALUE;
single_value->field_ta__index = ANY_OR_OMIT;
single_value->field_tbf__starting__time__present = ANY_VALUE;
single_value->field_tbf__starting__time = ANY_OR_OMIT;
}
}
}

void PacketUlAssignDyn_template::copy_value(const PacketUlAssignDyn& other_value)
{
single_value = new single_value_struct;
if (other_value.tfi__assignment().is_bound()) {
  single_value->field_tfi__assignment = other_value.tfi__assignment();
} else {
  single_value->field_tfi__assignment.clean_up();
}
if (other_value.polling().is_bound()) {
  single_value->field_polling = other_value.polling();
} else {
  single_value->field_polling.clean_up();
}
if (other_value.spare().is_bound()) {
  single_value->field_spare = other_value.spare();
} else {
  single_value->field_spare.clean_up();
}
if (other_value.usf().is_bound()) {
  single_value->field_usf = other_value.usf();
} else {
  single_value->field_usf.clean_up();
}
if (other_value.usf__granularity().is_bound()) {
  single_value->field_usf__granularity = other_value.usf__granularity();
} else {
  single_value->field_usf__granularity.clean_up();
}
if (other_value.p0__present().is_bound()) {
  single_value->field_p0__present = other_value.p0__present();
} else {
  single_value->field_p0__present.clean_up();
}
if (other_value.p0().is_bound()) {
  if (other_value.p0().ispresent()) single_value->field_p0 = other_value.p0()();
  else single_value->field_p0 = OMIT_VALUE;
} else {
  single_value->field_p0.clean_up();
}
if (other_value.pr__mode().is_bound()) {
  if (other_value.pr__mode().ispresent()) single_value->field_pr__mode = other_value.pr__mode()();
  else single_value->field_pr__mode = OMIT_VALUE;
} else {
  single_value->field_pr__mode.clean_up();
}
if (other_value.ch__coding__cmd().is_bound()) {
  single_value->field_ch__coding__cmd = other_value.ch__coding__cmd();
} else {
  single_value->field_ch__coding__cmd.clean_up();
}
if (other_value.tlli__block__chan__coding().is_bound()) {
  single_value->field_tlli__block__chan__coding = other_value.tlli__block__chan__coding();
} else {
  single_value->field_tlli__block__chan__coding.clean_up();
}
if (other_value.alpha__present().is_bound()) {
  single_value->field_alpha__present = other_value.alpha__present();
} else {
  single_value->field_alpha__present.clean_up();
}
if (other_value.alpha().is_bound()) {
  if (other_value.alpha().ispresent()) single_value->field_alpha = other_value.alpha()();
  else single_value->field_alpha = OMIT_VALUE;
} else {
  single_value->field_alpha.clean_up();
}
if (other_value.gamma().is_bound()) {
  single_value->field_gamma = other_value.gamma();
} else {
  single_value->field_gamma.clean_up();
}
if (other_value.ta__index__present().is_bound()) {
  single_value->field_ta__index__present = other_value.ta__index__present();
} else {
  single_value->field_ta__index__present.clean_up();
}
if (other_value.ta__index().is_bound()) {
  if (other_value.ta__index().ispresent()) single_value->field_ta__index = other_value.ta__index()();
  else single_value->field_ta__index = OMIT_VALUE;
} else {
  single_value->field_ta__index.clean_up();
}
if (other_value.tbf__starting__time__present().is_bound()) {
  single_value->field_tbf__starting__time__present = other_value.tbf__starting__time__present();
} else {
  single_value->field_tbf__starting__time__present.clean_up();
}
if (other_value.tbf__starting__time().is_bound()) {
  if (other_value.tbf__starting__time().ispresent()) single_value->field_tbf__starting__time = other_value.tbf__starting__time()();
  else single_value->field_tbf__starting__time = OMIT_VALUE;
} else {
  single_value->field_tbf__starting__time.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void PacketUlAssignDyn_template::copy_template(const PacketUlAssignDyn_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.tfi__assignment().get_selection()) {
single_value->field_tfi__assignment = other_value.tfi__assignment();
} else {
single_value->field_tfi__assignment.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.polling().get_selection()) {
single_value->field_polling = other_value.polling();
} else {
single_value->field_polling.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.spare().get_selection()) {
single_value->field_spare = other_value.spare();
} else {
single_value->field_spare.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.usf().get_selection()) {
single_value->field_usf = other_value.usf();
} else {
single_value->field_usf.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.usf__granularity().get_selection()) {
single_value->field_usf__granularity = other_value.usf__granularity();
} else {
single_value->field_usf__granularity.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.p0__present().get_selection()) {
single_value->field_p0__present = other_value.p0__present();
} else {
single_value->field_p0__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.p0().get_selection()) {
single_value->field_p0 = other_value.p0();
} else {
single_value->field_p0.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.pr__mode().get_selection()) {
single_value->field_pr__mode = other_value.pr__mode();
} else {
single_value->field_pr__mode.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ch__coding__cmd().get_selection()) {
single_value->field_ch__coding__cmd = other_value.ch__coding__cmd();
} else {
single_value->field_ch__coding__cmd.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tlli__block__chan__coding().get_selection()) {
single_value->field_tlli__block__chan__coding = other_value.tlli__block__chan__coding();
} else {
single_value->field_tlli__block__chan__coding.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.alpha__present().get_selection()) {
single_value->field_alpha__present = other_value.alpha__present();
} else {
single_value->field_alpha__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.alpha().get_selection()) {
single_value->field_alpha = other_value.alpha();
} else {
single_value->field_alpha.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.gamma().get_selection()) {
single_value->field_gamma = other_value.gamma();
} else {
single_value->field_gamma.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ta__index__present().get_selection()) {
single_value->field_ta__index__present = other_value.ta__index__present();
} else {
single_value->field_ta__index__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ta__index().get_selection()) {
single_value->field_ta__index = other_value.ta__index();
} else {
single_value->field_ta__index.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tbf__starting__time__present().get_selection()) {
single_value->field_tbf__starting__time__present = other_value.tbf__starting__time__present();
} else {
single_value->field_tbf__starting__time__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tbf__starting__time().get_selection()) {
single_value->field_tbf__starting__time = other_value.tbf__starting__time();
} else {
single_value->field_tbf__starting__time.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new PacketUlAssignDyn_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new PacketUlAssignDyn_template(*other_value.implication_.precondition);
implication_.implied_template = new PacketUlAssignDyn_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssignDyn.");
break;
}
set_selection(other_value);
}

PacketUlAssignDyn_template::PacketUlAssignDyn_template()
{
}

PacketUlAssignDyn_template::PacketUlAssignDyn_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

PacketUlAssignDyn_template::PacketUlAssignDyn_template(const PacketUlAssignDyn& other_value)
{
copy_value(other_value);
}

PacketUlAssignDyn_template::PacketUlAssignDyn_template(const OPTIONAL<PacketUlAssignDyn>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlAssignDyn&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.PacketUlAssignDyn from an unbound optional field.");
}
}

PacketUlAssignDyn_template::PacketUlAssignDyn_template(PacketUlAssignDyn_template* p_precondition, PacketUlAssignDyn_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

PacketUlAssignDyn_template::PacketUlAssignDyn_template(Dynamic_Match_Interface<PacketUlAssignDyn>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<PacketUlAssignDyn>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

PacketUlAssignDyn_template::PacketUlAssignDyn_template(const PacketUlAssignDyn_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

PacketUlAssignDyn_template::~PacketUlAssignDyn_template()
{
clean_up();
}

PacketUlAssignDyn_template& PacketUlAssignDyn_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

PacketUlAssignDyn_template& PacketUlAssignDyn_template::operator=(const PacketUlAssignDyn& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

PacketUlAssignDyn_template& PacketUlAssignDyn_template::operator=(const OPTIONAL<PacketUlAssignDyn>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlAssignDyn&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.PacketUlAssignDyn.");
}
return *this;
}

PacketUlAssignDyn_template& PacketUlAssignDyn_template::operator=(const PacketUlAssignDyn_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean PacketUlAssignDyn_template::match(const PacketUlAssignDyn& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.tfi__assignment().is_bound()) return FALSE;
if(!single_value->field_tfi__assignment.match(other_value.tfi__assignment(), legacy))return FALSE;
if(!other_value.polling().is_bound()) return FALSE;
if(!single_value->field_polling.match(other_value.polling(), legacy))return FALSE;
if(!other_value.spare().is_bound()) return FALSE;
if(!single_value->field_spare.match(other_value.spare(), legacy))return FALSE;
if(!other_value.usf().is_bound()) return FALSE;
if(!single_value->field_usf.match(other_value.usf(), legacy))return FALSE;
if(!other_value.usf__granularity().is_bound()) return FALSE;
if(!single_value->field_usf__granularity.match(other_value.usf__granularity(), legacy))return FALSE;
if(!other_value.p0__present().is_bound()) return FALSE;
if(!single_value->field_p0__present.match(other_value.p0__present(), legacy))return FALSE;
if(!other_value.p0().is_bound()) return FALSE;
if((other_value.p0().ispresent() ? !single_value->field_p0.match((const INTEGER&)other_value.p0(), legacy) : !single_value->field_p0.match_omit(legacy)))return FALSE;
if(!other_value.pr__mode().is_bound()) return FALSE;
if((other_value.pr__mode().ispresent() ? !single_value->field_pr__mode.match((const BITSTRING&)other_value.pr__mode(), legacy) : !single_value->field_pr__mode.match_omit(legacy)))return FALSE;
if(!other_value.ch__coding__cmd().is_bound()) return FALSE;
if(!single_value->field_ch__coding__cmd.match(other_value.ch__coding__cmd(), legacy))return FALSE;
if(!other_value.tlli__block__chan__coding().is_bound()) return FALSE;
if(!single_value->field_tlli__block__chan__coding.match(other_value.tlli__block__chan__coding(), legacy))return FALSE;
if(!other_value.alpha__present().is_bound()) return FALSE;
if(!single_value->field_alpha__present.match(other_value.alpha__present(), legacy))return FALSE;
if(!other_value.alpha().is_bound()) return FALSE;
if((other_value.alpha().ispresent() ? !single_value->field_alpha.match((const INTEGER&)other_value.alpha(), legacy) : !single_value->field_alpha.match_omit(legacy)))return FALSE;
if(!other_value.gamma().is_bound()) return FALSE;
if(!single_value->field_gamma.match(other_value.gamma(), legacy))return FALSE;
if(!other_value.ta__index__present().is_bound()) return FALSE;
if(!single_value->field_ta__index__present.match(other_value.ta__index__present(), legacy))return FALSE;
if(!other_value.ta__index().is_bound()) return FALSE;
if((other_value.ta__index().ispresent() ? !single_value->field_ta__index.match((const INTEGER&)other_value.ta__index(), legacy) : !single_value->field_ta__index.match_omit(legacy)))return FALSE;
if(!other_value.tbf__starting__time__present().is_bound()) return FALSE;
if(!single_value->field_tbf__starting__time__present.match(other_value.tbf__starting__time__present(), legacy))return FALSE;
if(!other_value.tbf__starting__time().is_bound()) return FALSE;
if((other_value.tbf__starting__time().ispresent() ? !single_value->field_tbf__starting__time.match((const TbfStartingTime&)other_value.tbf__starting__time(), legacy) : !single_value->field_tbf__starting__time.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssignDyn.");
}
return FALSE;
}

boolean PacketUlAssignDyn_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_tfi__assignment.is_bound()
 || single_value->field_polling.is_bound()
 || single_value->field_spare.is_bound()
 || single_value->field_usf.is_bound()
 || single_value->field_usf__granularity.is_bound()
 || single_value->field_p0__present.is_bound()
 || (single_value->field_p0.is_omit() || single_value->field_p0.is_bound())
 || (single_value->field_pr__mode.is_omit() || single_value->field_pr__mode.is_bound())
 || single_value->field_ch__coding__cmd.is_bound()
 || single_value->field_tlli__block__chan__coding.is_bound()
 || single_value->field_alpha__present.is_bound()
 || (single_value->field_alpha.is_omit() || single_value->field_alpha.is_bound())
 || single_value->field_gamma.is_bound()
 || single_value->field_ta__index__present.is_bound()
 || (single_value->field_ta__index.is_omit() || single_value->field_ta__index.is_bound())
 || single_value->field_tbf__starting__time__present.is_bound()
 || (single_value->field_tbf__starting__time.is_omit() || single_value->field_tbf__starting__time.is_bound());
}

boolean PacketUlAssignDyn_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_tfi__assignment.is_value()
 && single_value->field_polling.is_value()
 && single_value->field_spare.is_value()
 && single_value->field_usf.is_value()
 && single_value->field_usf__granularity.is_value()
 && single_value->field_p0__present.is_value()
 && (single_value->field_p0.is_omit() || single_value->field_p0.is_value())
 && (single_value->field_pr__mode.is_omit() || single_value->field_pr__mode.is_value())
 && single_value->field_ch__coding__cmd.is_value()
 && single_value->field_tlli__block__chan__coding.is_value()
 && single_value->field_alpha__present.is_value()
 && (single_value->field_alpha.is_omit() || single_value->field_alpha.is_value())
 && single_value->field_gamma.is_value()
 && single_value->field_ta__index__present.is_value()
 && (single_value->field_ta__index.is_omit() || single_value->field_ta__index.is_value())
 && single_value->field_tbf__starting__time__present.is_value()
 && (single_value->field_tbf__starting__time.is_omit() || single_value->field_tbf__starting__time.is_value());
}

void PacketUlAssignDyn_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

PacketUlAssignDyn PacketUlAssignDyn_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
PacketUlAssignDyn ret_val;
if (single_value->field_tfi__assignment.is_bound()) {
ret_val.tfi__assignment() = single_value->field_tfi__assignment.valueof();
}
if (single_value->field_polling.is_bound()) {
ret_val.polling() = single_value->field_polling.valueof();
}
if (single_value->field_spare.is_bound()) {
ret_val.spare() = single_value->field_spare.valueof();
}
if (single_value->field_usf.is_bound()) {
ret_val.usf() = single_value->field_usf.valueof();
}
if (single_value->field_usf__granularity.is_bound()) {
ret_val.usf__granularity() = single_value->field_usf__granularity.valueof();
}
if (single_value->field_p0__present.is_bound()) {
ret_val.p0__present() = single_value->field_p0__present.valueof();
}
if (single_value->field_p0.is_omit()) ret_val.p0() = OMIT_VALUE;
else if (single_value->field_p0.is_bound()) {
ret_val.p0() = single_value->field_p0.valueof();
}
if (single_value->field_pr__mode.is_omit()) ret_val.pr__mode() = OMIT_VALUE;
else if (single_value->field_pr__mode.is_bound()) {
ret_val.pr__mode() = single_value->field_pr__mode.valueof();
}
if (single_value->field_ch__coding__cmd.is_bound()) {
ret_val.ch__coding__cmd() = single_value->field_ch__coding__cmd.valueof();
}
if (single_value->field_tlli__block__chan__coding.is_bound()) {
ret_val.tlli__block__chan__coding() = single_value->field_tlli__block__chan__coding.valueof();
}
if (single_value->field_alpha__present.is_bound()) {
ret_val.alpha__present() = single_value->field_alpha__present.valueof();
}
if (single_value->field_alpha.is_omit()) ret_val.alpha() = OMIT_VALUE;
else if (single_value->field_alpha.is_bound()) {
ret_val.alpha() = single_value->field_alpha.valueof();
}
if (single_value->field_gamma.is_bound()) {
ret_val.gamma() = single_value->field_gamma.valueof();
}
if (single_value->field_ta__index__present.is_bound()) {
ret_val.ta__index__present() = single_value->field_ta__index__present.valueof();
}
if (single_value->field_ta__index.is_omit()) ret_val.ta__index() = OMIT_VALUE;
else if (single_value->field_ta__index.is_bound()) {
ret_val.ta__index() = single_value->field_ta__index.valueof();
}
if (single_value->field_tbf__starting__time__present.is_bound()) {
ret_val.tbf__starting__time__present() = single_value->field_tbf__starting__time__present.valueof();
}
if (single_value->field_tbf__starting__time.is_omit()) ret_val.tbf__starting__time() = OMIT_VALUE;
else if (single_value->field_tbf__starting__time.is_bound()) {
ret_val.tbf__starting__time() = single_value->field_tbf__starting__time.valueof();
}
return ret_val;
}

void PacketUlAssignDyn_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.PacketUlAssignDyn.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new PacketUlAssignDyn_template[list_length];
}

PacketUlAssignDyn_template& PacketUlAssignDyn_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.PacketUlAssignDyn.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.PacketUlAssignDyn.");
return value_list.list_value[list_index];
}

INTEGER_template& PacketUlAssignDyn_template::tfi__assignment()
{
set_specific();
return single_value->field_tfi__assignment;
}

const INTEGER_template& PacketUlAssignDyn_template::tfi__assignment() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tfi_assignment of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_tfi__assignment;
}

BITSTRING_template& PacketUlAssignDyn_template::polling()
{
set_specific();
return single_value->field_polling;
}

const BITSTRING_template& PacketUlAssignDyn_template::polling() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field polling of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_polling;
}

BITSTRING_template& PacketUlAssignDyn_template::spare()
{
set_specific();
return single_value->field_spare;
}

const BITSTRING_template& PacketUlAssignDyn_template::spare() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field spare of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_spare;
}

INTEGER_template& PacketUlAssignDyn_template::usf()
{
set_specific();
return single_value->field_usf;
}

const INTEGER_template& PacketUlAssignDyn_template::usf() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field usf of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_usf;
}

BITSTRING_template& PacketUlAssignDyn_template::usf__granularity()
{
set_specific();
return single_value->field_usf__granularity;
}

const BITSTRING_template& PacketUlAssignDyn_template::usf__granularity() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field usf_granularity of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_usf__granularity;
}

BITSTRING_template& PacketUlAssignDyn_template::p0__present()
{
set_specific();
return single_value->field_p0__present;
}

const BITSTRING_template& PacketUlAssignDyn_template::p0__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field p0_present of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_p0__present;
}

INTEGER_template& PacketUlAssignDyn_template::p0()
{
set_specific();
return single_value->field_p0;
}

const INTEGER_template& PacketUlAssignDyn_template::p0() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field p0 of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_p0;
}

BITSTRING_template& PacketUlAssignDyn_template::pr__mode()
{
set_specific();
return single_value->field_pr__mode;
}

const BITSTRING_template& PacketUlAssignDyn_template::pr__mode() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field pr_mode of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_pr__mode;
}

RLCMAC__CSN1__Types::ChCodingCommand_template& PacketUlAssignDyn_template::ch__coding__cmd()
{
set_specific();
return single_value->field_ch__coding__cmd;
}

const RLCMAC__CSN1__Types::ChCodingCommand_template& PacketUlAssignDyn_template::ch__coding__cmd() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ch_coding_cmd of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_ch__coding__cmd;
}

BITSTRING_template& PacketUlAssignDyn_template::tlli__block__chan__coding()
{
set_specific();
return single_value->field_tlli__block__chan__coding;
}

const BITSTRING_template& PacketUlAssignDyn_template::tlli__block__chan__coding() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tlli_block_chan_coding of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_tlli__block__chan__coding;
}

BITSTRING_template& PacketUlAssignDyn_template::alpha__present()
{
set_specific();
return single_value->field_alpha__present;
}

const BITSTRING_template& PacketUlAssignDyn_template::alpha__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha_present of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_alpha__present;
}

INTEGER_template& PacketUlAssignDyn_template::alpha()
{
set_specific();
return single_value->field_alpha;
}

const INTEGER_template& PacketUlAssignDyn_template::alpha() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_alpha;
}

INTEGER_template& PacketUlAssignDyn_template::gamma()
{
set_specific();
return single_value->field_gamma;
}

const INTEGER_template& PacketUlAssignDyn_template::gamma() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field gamma of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_gamma;
}

BITSTRING_template& PacketUlAssignDyn_template::ta__index__present()
{
set_specific();
return single_value->field_ta__index__present;
}

const BITSTRING_template& PacketUlAssignDyn_template::ta__index__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ta_index_present of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_ta__index__present;
}

INTEGER_template& PacketUlAssignDyn_template::ta__index()
{
set_specific();
return single_value->field_ta__index;
}

const INTEGER_template& PacketUlAssignDyn_template::ta__index() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ta_index of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_ta__index;
}

BITSTRING_template& PacketUlAssignDyn_template::tbf__starting__time__present()
{
set_specific();
return single_value->field_tbf__starting__time__present;
}

const BITSTRING_template& PacketUlAssignDyn_template::tbf__starting__time__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tbf_starting_time_present of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_tbf__starting__time__present;
}

TbfStartingTime_template& PacketUlAssignDyn_template::tbf__starting__time()
{
set_specific();
return single_value->field_tbf__starting__time;
}

const TbfStartingTime_template& PacketUlAssignDyn_template::tbf__starting__time() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tbf_starting_time of a non-specific template of type @GSM_RestOctets.PacketUlAssignDyn.");
return single_value->field_tbf__starting__time;
}

int PacketUlAssignDyn_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignDyn which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 12;
      if (single_value->field_p0.is_present()) ret_val++;
      if (single_value->field_pr__mode.is_present()) ret_val++;
      if (single_value->field_alpha.is_present()) ret_val++;
      if (single_value->field_ta__index.is_present()) ret_val++;
      if (single_value->field_tbf__starting__time.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignDyn containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignDyn containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignDyn containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignDyn containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignDyn containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignDyn containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignDyn containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignDyn containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssignDyn.");
  }
  return 0;
}

void PacketUlAssignDyn_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ tfi_assignment := ");
single_value->field_tfi__assignment.log();
TTCN_Logger::log_event_str(", polling := ");
single_value->field_polling.log();
TTCN_Logger::log_event_str(", spare := ");
single_value->field_spare.log();
TTCN_Logger::log_event_str(", usf := ");
single_value->field_usf.log();
TTCN_Logger::log_event_str(", usf_granularity := ");
single_value->field_usf__granularity.log();
TTCN_Logger::log_event_str(", p0_present := ");
single_value->field_p0__present.log();
TTCN_Logger::log_event_str(", p0 := ");
single_value->field_p0.log();
TTCN_Logger::log_event_str(", pr_mode := ");
single_value->field_pr__mode.log();
TTCN_Logger::log_event_str(", ch_coding_cmd := ");
single_value->field_ch__coding__cmd.log();
TTCN_Logger::log_event_str(", tlli_block_chan_coding := ");
single_value->field_tlli__block__chan__coding.log();
TTCN_Logger::log_event_str(", alpha_present := ");
single_value->field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
single_value->field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log();
TTCN_Logger::log_event_str(", ta_index_present := ");
single_value->field_ta__index__present.log();
TTCN_Logger::log_event_str(", ta_index := ");
single_value->field_ta__index.log();
TTCN_Logger::log_event_str(", tbf_starting_time_present := ");
single_value->field_tbf__starting__time__present.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
single_value->field_tbf__starting__time.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void PacketUlAssignDyn_template::log_match(const PacketUlAssignDyn& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_tfi__assignment.match(match_value.tfi__assignment(), legacy)){
TTCN_Logger::log_logmatch_info(".tfi_assignment");
single_value->field_tfi__assignment.log_match(match_value.tfi__assignment(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_polling.match(match_value.polling(), legacy)){
TTCN_Logger::log_logmatch_info(".polling");
single_value->field_polling.log_match(match_value.polling(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_spare.match(match_value.spare(), legacy)){
TTCN_Logger::log_logmatch_info(".spare");
single_value->field_spare.log_match(match_value.spare(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_usf.match(match_value.usf(), legacy)){
TTCN_Logger::log_logmatch_info(".usf");
single_value->field_usf.log_match(match_value.usf(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_usf__granularity.match(match_value.usf__granularity(), legacy)){
TTCN_Logger::log_logmatch_info(".usf_granularity");
single_value->field_usf__granularity.log_match(match_value.usf__granularity(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_p0__present.match(match_value.p0__present(), legacy)){
TTCN_Logger::log_logmatch_info(".p0_present");
single_value->field_p0__present.log_match(match_value.p0__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.p0().ispresent()){
if(!single_value->field_p0.match(match_value.p0(), legacy)){
TTCN_Logger::log_logmatch_info(".p0");
single_value->field_p0.log_match(match_value.p0(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_p0.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".p0 := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_p0.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.pr__mode().ispresent()){
if(!single_value->field_pr__mode.match(match_value.pr__mode(), legacy)){
TTCN_Logger::log_logmatch_info(".pr_mode");
single_value->field_pr__mode.log_match(match_value.pr__mode(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_pr__mode.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".pr_mode := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_pr__mode.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_ch__coding__cmd.match(match_value.ch__coding__cmd(), legacy)){
TTCN_Logger::log_logmatch_info(".ch_coding_cmd");
single_value->field_ch__coding__cmd.log_match(match_value.ch__coding__cmd(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_tlli__block__chan__coding.match(match_value.tlli__block__chan__coding(), legacy)){
TTCN_Logger::log_logmatch_info(".tlli_block_chan_coding");
single_value->field_tlli__block__chan__coding.log_match(match_value.tlli__block__chan__coding(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_alpha__present.match(match_value.alpha__present(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha_present");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.alpha().ispresent()){
if(!single_value->field_alpha.match(match_value.alpha(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha");
single_value->field_alpha.log_match(match_value.alpha(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_alpha.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".alpha := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_alpha.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_gamma.match(match_value.gamma(), legacy)){
TTCN_Logger::log_logmatch_info(".gamma");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_ta__index__present.match(match_value.ta__index__present(), legacy)){
TTCN_Logger::log_logmatch_info(".ta_index_present");
single_value->field_ta__index__present.log_match(match_value.ta__index__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.ta__index().ispresent()){
if(!single_value->field_ta__index.match(match_value.ta__index(), legacy)){
TTCN_Logger::log_logmatch_info(".ta_index");
single_value->field_ta__index.log_match(match_value.ta__index(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_ta__index.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".ta_index := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_ta__index.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_tbf__starting__time__present.match(match_value.tbf__starting__time__present(), legacy)){
TTCN_Logger::log_logmatch_info(".tbf_starting_time_present");
single_value->field_tbf__starting__time__present.log_match(match_value.tbf__starting__time__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.tbf__starting__time().ispresent()){
if(!single_value->field_tbf__starting__time.match(match_value.tbf__starting__time(), legacy)){
TTCN_Logger::log_logmatch_info(".tbf_starting_time");
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_tbf__starting__time.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".tbf_starting_time := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_tbf__starting__time.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ tfi_assignment := ");
single_value->field_tfi__assignment.log_match(match_value.tfi__assignment(), legacy);
TTCN_Logger::log_event_str(", polling := ");
single_value->field_polling.log_match(match_value.polling(), legacy);
TTCN_Logger::log_event_str(", spare := ");
single_value->field_spare.log_match(match_value.spare(), legacy);
TTCN_Logger::log_event_str(", usf := ");
single_value->field_usf.log_match(match_value.usf(), legacy);
TTCN_Logger::log_event_str(", usf_granularity := ");
single_value->field_usf__granularity.log_match(match_value.usf__granularity(), legacy);
TTCN_Logger::log_event_str(", p0_present := ");
single_value->field_p0__present.log_match(match_value.p0__present(), legacy);
TTCN_Logger::log_event_str(", p0 := ");
if (match_value.p0().ispresent()) {
single_value->field_p0.log_match(match_value.p0(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_p0.log();
if (single_value->field_p0.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", pr_mode := ");
if (match_value.pr__mode().ispresent()) {
single_value->field_pr__mode.log_match(match_value.pr__mode(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_pr__mode.log();
if (single_value->field_pr__mode.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", ch_coding_cmd := ");
single_value->field_ch__coding__cmd.log_match(match_value.ch__coding__cmd(), legacy);
TTCN_Logger::log_event_str(", tlli_block_chan_coding := ");
single_value->field_tlli__block__chan__coding.log_match(match_value.tlli__block__chan__coding(), legacy);
TTCN_Logger::log_event_str(", alpha_present := ");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::log_event_str(", alpha := ");
if (match_value.alpha().ispresent()) {
single_value->field_alpha.log_match(match_value.alpha(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_alpha.log();
if (single_value->field_alpha.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::log_event_str(", ta_index_present := ");
single_value->field_ta__index__present.log_match(match_value.ta__index__present(), legacy);
TTCN_Logger::log_event_str(", ta_index := ");
if (match_value.ta__index().ispresent()) {
single_value->field_ta__index.log_match(match_value.ta__index(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_ta__index.log();
if (single_value->field_ta__index.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", tbf_starting_time_present := ");
single_value->field_tbf__starting__time__present.log_match(match_value.tbf__starting__time__present(), legacy);
TTCN_Logger::log_event_str(", tbf_starting_time := ");
if (match_value.tbf__starting__time().ispresent()) {
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_tbf__starting__time.log();
if (single_value->field_tbf__starting__time.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void PacketUlAssignDyn_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (tfi__assignment().is_bound()) tfi__assignment().set_implicit_omit();
if (polling().is_bound()) polling().set_implicit_omit();
if (spare().is_bound()) spare().set_implicit_omit();
if (usf().is_bound()) usf().set_implicit_omit();
if (usf__granularity().is_bound()) usf__granularity().set_implicit_omit();
if (p0__present().is_bound()) p0__present().set_implicit_omit();
if (!p0().is_bound()) p0() = OMIT_VALUE;
else p0().set_implicit_omit();
if (!pr__mode().is_bound()) pr__mode() = OMIT_VALUE;
else pr__mode().set_implicit_omit();
if (ch__coding__cmd().is_bound()) ch__coding__cmd().set_implicit_omit();
if (tlli__block__chan__coding().is_bound()) tlli__block__chan__coding().set_implicit_omit();
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (ta__index__present().is_bound()) ta__index__present().set_implicit_omit();
if (!ta__index().is_bound()) ta__index() = OMIT_VALUE;
else ta__index().set_implicit_omit();
if (tbf__starting__time__present().is_bound()) tbf__starting__time__present().set_implicit_omit();
if (!tbf__starting__time().is_bound()) tbf__starting__time() = OMIT_VALUE;
else tbf__starting__time().set_implicit_omit();
}

void PacketUlAssignDyn_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_tfi__assignment.encode_text(text_buf);
single_value->field_polling.encode_text(text_buf);
single_value->field_spare.encode_text(text_buf);
single_value->field_usf.encode_text(text_buf);
single_value->field_usf__granularity.encode_text(text_buf);
single_value->field_p0__present.encode_text(text_buf);
single_value->field_p0.encode_text(text_buf);
single_value->field_pr__mode.encode_text(text_buf);
single_value->field_ch__coding__cmd.encode_text(text_buf);
single_value->field_tlli__block__chan__coding.encode_text(text_buf);
single_value->field_alpha__present.encode_text(text_buf);
single_value->field_alpha.encode_text(text_buf);
single_value->field_gamma.encode_text(text_buf);
single_value->field_ta__index__present.encode_text(text_buf);
single_value->field_ta__index.encode_text(text_buf);
single_value->field_tbf__starting__time__present.encode_text(text_buf);
single_value->field_tbf__starting__time.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssignDyn.");
}
}

void PacketUlAssignDyn_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_tfi__assignment.decode_text(text_buf);
single_value->field_polling.decode_text(text_buf);
single_value->field_spare.decode_text(text_buf);
single_value->field_usf.decode_text(text_buf);
single_value->field_usf__granularity.decode_text(text_buf);
single_value->field_p0__present.decode_text(text_buf);
single_value->field_p0.decode_text(text_buf);
single_value->field_pr__mode.decode_text(text_buf);
single_value->field_ch__coding__cmd.decode_text(text_buf);
single_value->field_tlli__block__chan__coding.decode_text(text_buf);
single_value->field_alpha__present.decode_text(text_buf);
single_value->field_alpha.decode_text(text_buf);
single_value->field_gamma.decode_text(text_buf);
single_value->field_ta__index__present.decode_text(text_buf);
single_value->field_ta__index.decode_text(text_buf);
single_value->field_tbf__starting__time__present.decode_text(text_buf);
single_value->field_tbf__starting__time.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new PacketUlAssignDyn_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.PacketUlAssignDyn.");
}
}

void PacketUlAssignDyn_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    PacketUlAssignDyn_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (17<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.PacketUlAssignDyn has 17 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) tfi__assignment().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) polling().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) spare().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) usf().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) usf__granularity().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) p0__present().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) p0().set_param(*param.get_elem(6));
    if (param.get_size()>7 && param.get_elem(7)->get_type()!=Module_Param::MP_NotUsed) pr__mode().set_param(*param.get_elem(7));
    if (param.get_size()>8 && param.get_elem(8)->get_type()!=Module_Param::MP_NotUsed) ch__coding__cmd().set_param(*param.get_elem(8));
    if (param.get_size()>9 && param.get_elem(9)->get_type()!=Module_Param::MP_NotUsed) tlli__block__chan__coding().set_param(*param.get_elem(9));
    if (param.get_size()>10 && param.get_elem(10)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(10));
    if (param.get_size()>11 && param.get_elem(11)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(11));
    if (param.get_size()>12 && param.get_elem(12)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(12));
    if (param.get_size()>13 && param.get_elem(13)->get_type()!=Module_Param::MP_NotUsed) ta__index__present().set_param(*param.get_elem(13));
    if (param.get_size()>14 && param.get_elem(14)->get_type()!=Module_Param::MP_NotUsed) ta__index().set_param(*param.get_elem(14));
    if (param.get_size()>15 && param.get_elem(15)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time__present().set_param(*param.get_elem(15));
    if (param.get_size()>16 && param.get_elem(16)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(16));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tfi_assignment")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tfi__assignment().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "polling")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          polling().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "spare")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          spare().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "usf")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          usf().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "usf_granularity")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          usf__granularity().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pr_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pr__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ch_coding_cmd")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ch__coding__cmd().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tlli_block_chan_coding")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tlli__block__chan__coding().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketUlAssignDyn: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    PacketUlAssignDyn_template* precondition = new PacketUlAssignDyn_template;
    precondition->set_param(*param.get_elem(0));
    PacketUlAssignDyn_template* implied_template = new PacketUlAssignDyn_template;
    implied_template->set_param(*param.get_elem(1));
    *this = PacketUlAssignDyn_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.PacketUlAssignDyn");
  }
  is_ifpresent = param.get_ifpresent();
}

void PacketUlAssignDyn_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_tfi__assignment.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_polling.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_spare.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_usf.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_usf__granularity.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_p0__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_p0.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_pr__mode.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_ch__coding__cmd.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_tlli__block__chan__coding.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_alpha__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_alpha.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_gamma.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_ta__index__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_ta__index.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_tbf__starting__time__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
single_value->field_tbf__starting__time.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.PacketUlAssignDyn");
}

boolean PacketUlAssignDyn_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean PacketUlAssignDyn_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

PacketUlAssignSgl::PacketUlAssignSgl()
{
}

PacketUlAssignSgl::PacketUlAssignSgl(const BITSTRING& par_alpha__present,
    const OPTIONAL< INTEGER >& par_alpha,
    const INTEGER& par_gamma,
    const BITSTRING& par_padding,
    const TbfStartingTime& par_tbf__starting__time)
  :   field_alpha__present(par_alpha__present),
  field_alpha(par_alpha),
  field_gamma(par_gamma),
  field_padding(par_padding),
  field_tbf__starting__time(par_tbf__starting__time)
{
}

PacketUlAssignSgl::PacketUlAssignSgl(const PacketUlAssignSgl& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.PacketUlAssignSgl.");
if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
else field_alpha__present.clean_up();
if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
else field_alpha.clean_up();
if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
else field_gamma.clean_up();
if (other_value.padding().is_bound()) field_padding = other_value.padding();
else field_padding.clean_up();
if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
else field_tbf__starting__time.clean_up();
}

void PacketUlAssignSgl::clean_up()
{
field_alpha__present.clean_up();
field_alpha.clean_up();
field_gamma.clean_up();
field_padding.clean_up();
field_tbf__starting__time.clean_up();
}

const TTCN_Typedescriptor_t* PacketUlAssignSgl::get_descriptor() const { return &PacketUlAssignSgl_descr_; }
PacketUlAssignSgl& PacketUlAssignSgl::operator=(const PacketUlAssignSgl& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.PacketUlAssignSgl.");
  if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
  else field_alpha__present.clean_up();
  if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
  else field_alpha.clean_up();
  if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
  else field_gamma.clean_up();
  if (other_value.padding().is_bound()) field_padding = other_value.padding();
  else field_padding.clean_up();
  if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
  else field_tbf__starting__time.clean_up();
}
return *this;
}

boolean PacketUlAssignSgl::operator==(const PacketUlAssignSgl& other_value) const
{
return field_alpha__present==other_value.field_alpha__present
  && field_alpha==other_value.field_alpha
  && field_gamma==other_value.field_gamma
  && field_padding==other_value.field_padding
  && field_tbf__starting__time==other_value.field_tbf__starting__time;
}

boolean PacketUlAssignSgl::is_bound() const
{
return (field_alpha__present.is_bound())
  || (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_bound())
  || (field_gamma.is_bound())
  || (field_padding.is_bound())
  || (field_tbf__starting__time.is_bound());
}
boolean PacketUlAssignSgl::is_value() const
{
return field_alpha__present.is_value()
  && (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_value())
  && field_gamma.is_value()
  && field_padding.is_value()
  && field_tbf__starting__time.is_value();
}
int PacketUlAssignSgl::size_of() const
{
  int ret_val = 4;
  if (field_alpha.ispresent()) ret_val++;
  return ret_val;
}

void PacketUlAssignSgl::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ alpha_present := ");
field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
field_gamma.log();
TTCN_Logger::log_event_str(", padding := ");
field_padding.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
field_tbf__starting__time.log();
TTCN_Logger::log_event_str(" }");
}

void PacketUlAssignSgl::set_implicit_omit()
{
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (padding().is_bound()) padding().set_implicit_omit();
if (tbf__starting__time().is_bound()) tbf__starting__time().set_implicit_omit();
}

void PacketUlAssignSgl::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (5<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.PacketUlAssignSgl has 5 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) padding().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(4));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "padding")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          padding().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketUlAssignSgl: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.PacketUlAssignSgl");
  }
}

void PacketUlAssignSgl::encode_text(Text_Buf& text_buf) const
{
field_alpha__present.encode_text(text_buf);
field_alpha.encode_text(text_buf);
field_gamma.encode_text(text_buf);
field_padding.encode_text(text_buf);
field_tbf__starting__time.encode_text(text_buf);
}

void PacketUlAssignSgl::decode_text(Text_Buf& text_buf)
{
field_alpha__present.decode_text(text_buf);
field_alpha.decode_text(text_buf);
field_gamma.decode_text(text_buf);
field_padding.decode_text(text_buf);
field_tbf__starting__time.decode_text(text_buf);
}

void PacketUlAssignSgl::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void PacketUlAssignSgl::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int PacketUlAssignSgl::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, PacketUlAssignSgl_alpha__present_descr_.raw->forceomit);
  decoded_field_length = field_alpha__present.RAW_decode(PacketUlAssignSgl_alpha__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_alpha__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_alpha = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, PacketUlAssignSgl_alpha_descr_.raw->forceomit);
  decoded_field_length = field_alpha().RAW_decode(PacketUlAssignSgl_alpha_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_alpha = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_alpha=OMIT_VALUE;
  RAW_Force_Omit field_2_force_omit(2, force_omit, PacketUlAssignSgl_gamma_descr_.raw->forceomit);
  decoded_field_length = field_gamma.RAW_decode(PacketUlAssignSgl_gamma_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_3_force_omit(3, force_omit, PacketUlAssignSgl_padding_descr_.raw->forceomit);
  decoded_field_length = field_padding.RAW_decode(PacketUlAssignSgl_padding_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_3_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_4_force_omit(4, force_omit, PacketUlAssignSgl_tbf__starting__time_descr_.raw->forceomit);
  decoded_field_length = field_tbf__starting__time.RAW_decode(PacketUlAssignSgl_tbf__starting__time_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_4_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int PacketUlAssignSgl::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 5;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(5);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, PacketUlAssignSgl_alpha__present_descr_.raw);
  if (field_alpha.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, PacketUlAssignSgl_alpha_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, PacketUlAssignSgl_gamma_descr_.raw);
  myleaf.body.node.nodes[3] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 3, PacketUlAssignSgl_padding_descr_.raw);
  myleaf.body.node.nodes[4] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 4, PacketUlAssignSgl_tbf__starting__time_descr_.raw);
  encoded_length += field_alpha__present.RAW_encode(PacketUlAssignSgl_alpha__present_descr_, *myleaf.body.node.nodes[0]);
  if (field_alpha.ispresent()) {
  encoded_length += field_alpha().RAW_encode(PacketUlAssignSgl_alpha_descr_, *myleaf.body.node.nodes[1]);
  }
  encoded_length += field_gamma.RAW_encode(PacketUlAssignSgl_gamma_descr_, *myleaf.body.node.nodes[2]);
  encoded_length += field_padding.RAW_encode(PacketUlAssignSgl_padding_descr_, *myleaf.body.node.nodes[3]);
  encoded_length += field_tbf__starting__time.RAW_encode(PacketUlAssignSgl_tbf__starting__time_descr_, *myleaf.body.node.nodes[4]);
  if (field_alpha.ispresent() && (field_alpha__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketUlAssignSgl_alpha__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct PacketUlAssignSgl_template::single_value_struct {
BITSTRING_template field_alpha__present;
INTEGER_template field_alpha;
INTEGER_template field_gamma;
BITSTRING_template field_padding;
TbfStartingTime_template field_tbf__starting__time;
};

void PacketUlAssignSgl_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_alpha__present = ANY_VALUE;
single_value->field_alpha = ANY_OR_OMIT;
single_value->field_gamma = ANY_VALUE;
single_value->field_padding = ANY_VALUE;
single_value->field_tbf__starting__time = ANY_VALUE;
}
}
}

void PacketUlAssignSgl_template::copy_value(const PacketUlAssignSgl& other_value)
{
single_value = new single_value_struct;
if (other_value.alpha__present().is_bound()) {
  single_value->field_alpha__present = other_value.alpha__present();
} else {
  single_value->field_alpha__present.clean_up();
}
if (other_value.alpha().is_bound()) {
  if (other_value.alpha().ispresent()) single_value->field_alpha = other_value.alpha()();
  else single_value->field_alpha = OMIT_VALUE;
} else {
  single_value->field_alpha.clean_up();
}
if (other_value.gamma().is_bound()) {
  single_value->field_gamma = other_value.gamma();
} else {
  single_value->field_gamma.clean_up();
}
if (other_value.padding().is_bound()) {
  single_value->field_padding = other_value.padding();
} else {
  single_value->field_padding.clean_up();
}
if (other_value.tbf__starting__time().is_bound()) {
  single_value->field_tbf__starting__time = other_value.tbf__starting__time();
} else {
  single_value->field_tbf__starting__time.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void PacketUlAssignSgl_template::copy_template(const PacketUlAssignSgl_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.alpha__present().get_selection()) {
single_value->field_alpha__present = other_value.alpha__present();
} else {
single_value->field_alpha__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.alpha().get_selection()) {
single_value->field_alpha = other_value.alpha();
} else {
single_value->field_alpha.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.gamma().get_selection()) {
single_value->field_gamma = other_value.gamma();
} else {
single_value->field_gamma.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.padding().get_selection()) {
single_value->field_padding = other_value.padding();
} else {
single_value->field_padding.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tbf__starting__time().get_selection()) {
single_value->field_tbf__starting__time = other_value.tbf__starting__time();
} else {
single_value->field_tbf__starting__time.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new PacketUlAssignSgl_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new PacketUlAssignSgl_template(*other_value.implication_.precondition);
implication_.implied_template = new PacketUlAssignSgl_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssignSgl.");
break;
}
set_selection(other_value);
}

PacketUlAssignSgl_template::PacketUlAssignSgl_template()
{
}

PacketUlAssignSgl_template::PacketUlAssignSgl_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

PacketUlAssignSgl_template::PacketUlAssignSgl_template(const PacketUlAssignSgl& other_value)
{
copy_value(other_value);
}

PacketUlAssignSgl_template::PacketUlAssignSgl_template(const OPTIONAL<PacketUlAssignSgl>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlAssignSgl&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.PacketUlAssignSgl from an unbound optional field.");
}
}

PacketUlAssignSgl_template::PacketUlAssignSgl_template(PacketUlAssignSgl_template* p_precondition, PacketUlAssignSgl_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

PacketUlAssignSgl_template::PacketUlAssignSgl_template(Dynamic_Match_Interface<PacketUlAssignSgl>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<PacketUlAssignSgl>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

PacketUlAssignSgl_template::PacketUlAssignSgl_template(const PacketUlAssignSgl_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

PacketUlAssignSgl_template::~PacketUlAssignSgl_template()
{
clean_up();
}

PacketUlAssignSgl_template& PacketUlAssignSgl_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

PacketUlAssignSgl_template& PacketUlAssignSgl_template::operator=(const PacketUlAssignSgl& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

PacketUlAssignSgl_template& PacketUlAssignSgl_template::operator=(const OPTIONAL<PacketUlAssignSgl>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlAssignSgl&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.PacketUlAssignSgl.");
}
return *this;
}

PacketUlAssignSgl_template& PacketUlAssignSgl_template::operator=(const PacketUlAssignSgl_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean PacketUlAssignSgl_template::match(const PacketUlAssignSgl& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.alpha__present().is_bound()) return FALSE;
if(!single_value->field_alpha__present.match(other_value.alpha__present(), legacy))return FALSE;
if(!other_value.alpha().is_bound()) return FALSE;
if((other_value.alpha().ispresent() ? !single_value->field_alpha.match((const INTEGER&)other_value.alpha(), legacy) : !single_value->field_alpha.match_omit(legacy)))return FALSE;
if(!other_value.gamma().is_bound()) return FALSE;
if(!single_value->field_gamma.match(other_value.gamma(), legacy))return FALSE;
if(!other_value.padding().is_bound()) return FALSE;
if(!single_value->field_padding.match(other_value.padding(), legacy))return FALSE;
if(!other_value.tbf__starting__time().is_bound()) return FALSE;
if(!single_value->field_tbf__starting__time.match(other_value.tbf__starting__time(), legacy))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssignSgl.");
}
return FALSE;
}

boolean PacketUlAssignSgl_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_alpha__present.is_bound()
 || (single_value->field_alpha.is_omit() || single_value->field_alpha.is_bound())
 || single_value->field_gamma.is_bound()
 || single_value->field_padding.is_bound()
 || single_value->field_tbf__starting__time.is_bound();
}

boolean PacketUlAssignSgl_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_alpha__present.is_value()
 && (single_value->field_alpha.is_omit() || single_value->field_alpha.is_value())
 && single_value->field_gamma.is_value()
 && single_value->field_padding.is_value()
 && single_value->field_tbf__starting__time.is_value();
}

void PacketUlAssignSgl_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

PacketUlAssignSgl PacketUlAssignSgl_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.PacketUlAssignSgl.");
PacketUlAssignSgl ret_val;
if (single_value->field_alpha__present.is_bound()) {
ret_val.alpha__present() = single_value->field_alpha__present.valueof();
}
if (single_value->field_alpha.is_omit()) ret_val.alpha() = OMIT_VALUE;
else if (single_value->field_alpha.is_bound()) {
ret_val.alpha() = single_value->field_alpha.valueof();
}
if (single_value->field_gamma.is_bound()) {
ret_val.gamma() = single_value->field_gamma.valueof();
}
if (single_value->field_padding.is_bound()) {
ret_val.padding() = single_value->field_padding.valueof();
}
if (single_value->field_tbf__starting__time.is_bound()) {
ret_val.tbf__starting__time() = single_value->field_tbf__starting__time.valueof();
}
return ret_val;
}

void PacketUlAssignSgl_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.PacketUlAssignSgl.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new PacketUlAssignSgl_template[list_length];
}

PacketUlAssignSgl_template& PacketUlAssignSgl_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.PacketUlAssignSgl.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.PacketUlAssignSgl.");
return value_list.list_value[list_index];
}

BITSTRING_template& PacketUlAssignSgl_template::alpha__present()
{
set_specific();
return single_value->field_alpha__present;
}

const BITSTRING_template& PacketUlAssignSgl_template::alpha__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha_present of a non-specific template of type @GSM_RestOctets.PacketUlAssignSgl.");
return single_value->field_alpha__present;
}

INTEGER_template& PacketUlAssignSgl_template::alpha()
{
set_specific();
return single_value->field_alpha;
}

const INTEGER_template& PacketUlAssignSgl_template::alpha() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha of a non-specific template of type @GSM_RestOctets.PacketUlAssignSgl.");
return single_value->field_alpha;
}

INTEGER_template& PacketUlAssignSgl_template::gamma()
{
set_specific();
return single_value->field_gamma;
}

const INTEGER_template& PacketUlAssignSgl_template::gamma() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field gamma of a non-specific template of type @GSM_RestOctets.PacketUlAssignSgl.");
return single_value->field_gamma;
}

BITSTRING_template& PacketUlAssignSgl_template::padding()
{
set_specific();
return single_value->field_padding;
}

const BITSTRING_template& PacketUlAssignSgl_template::padding() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field padding of a non-specific template of type @GSM_RestOctets.PacketUlAssignSgl.");
return single_value->field_padding;
}

TbfStartingTime_template& PacketUlAssignSgl_template::tbf__starting__time()
{
set_specific();
return single_value->field_tbf__starting__time;
}

const TbfStartingTime_template& PacketUlAssignSgl_template::tbf__starting__time() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tbf_starting_time of a non-specific template of type @GSM_RestOctets.PacketUlAssignSgl.");
return single_value->field_tbf__starting__time;
}

int PacketUlAssignSgl_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignSgl which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 4;
      if (single_value->field_alpha.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignSgl containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignSgl containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignSgl containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignSgl containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignSgl containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignSgl containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignSgl containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlAssignSgl containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssignSgl.");
  }
  return 0;
}

void PacketUlAssignSgl_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ alpha_present := ");
single_value->field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
single_value->field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log();
TTCN_Logger::log_event_str(", padding := ");
single_value->field_padding.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
single_value->field_tbf__starting__time.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void PacketUlAssignSgl_template::log_match(const PacketUlAssignSgl& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_alpha__present.match(match_value.alpha__present(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha_present");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.alpha().ispresent()){
if(!single_value->field_alpha.match(match_value.alpha(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha");
single_value->field_alpha.log_match(match_value.alpha(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_alpha.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".alpha := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_alpha.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_gamma.match(match_value.gamma(), legacy)){
TTCN_Logger::log_logmatch_info(".gamma");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_padding.match(match_value.padding(), legacy)){
TTCN_Logger::log_logmatch_info(".padding");
single_value->field_padding.log_match(match_value.padding(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_tbf__starting__time.match(match_value.tbf__starting__time(), legacy)){
TTCN_Logger::log_logmatch_info(".tbf_starting_time");
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ alpha_present := ");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::log_event_str(", alpha := ");
if (match_value.alpha().ispresent()) {
single_value->field_alpha.log_match(match_value.alpha(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_alpha.log();
if (single_value->field_alpha.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::log_event_str(", padding := ");
single_value->field_padding.log_match(match_value.padding(), legacy);
TTCN_Logger::log_event_str(", tbf_starting_time := ");
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void PacketUlAssignSgl_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (padding().is_bound()) padding().set_implicit_omit();
if (tbf__starting__time().is_bound()) tbf__starting__time().set_implicit_omit();
}

void PacketUlAssignSgl_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_alpha__present.encode_text(text_buf);
single_value->field_alpha.encode_text(text_buf);
single_value->field_gamma.encode_text(text_buf);
single_value->field_padding.encode_text(text_buf);
single_value->field_tbf__starting__time.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlAssignSgl.");
}
}

void PacketUlAssignSgl_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_alpha__present.decode_text(text_buf);
single_value->field_alpha.decode_text(text_buf);
single_value->field_gamma.decode_text(text_buf);
single_value->field_padding.decode_text(text_buf);
single_value->field_tbf__starting__time.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new PacketUlAssignSgl_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.PacketUlAssignSgl.");
}
}

void PacketUlAssignSgl_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    PacketUlAssignSgl_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (5<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.PacketUlAssignSgl has 5 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) padding().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(4));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "padding")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          padding().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketUlAssignSgl: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    PacketUlAssignSgl_template* precondition = new PacketUlAssignSgl_template;
    precondition->set_param(*param.get_elem(0));
    PacketUlAssignSgl_template* implied_template = new PacketUlAssignSgl_template;
    implied_template->set_param(*param.get_elem(1));
    *this = PacketUlAssignSgl_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.PacketUlAssignSgl");
  }
  is_ifpresent = param.get_ifpresent();
}

void PacketUlAssignSgl_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_alpha__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignSgl");
single_value->field_alpha.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignSgl");
single_value->field_gamma.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignSgl");
single_value->field_padding.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignSgl");
single_value->field_tbf__starting__time.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlAssignSgl");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.PacketUlAssignSgl");
}

boolean PacketUlAssignSgl_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean PacketUlAssignSgl_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

PacketDlAssign::PacketDlAssign()
{
}

PacketDlAssign::PacketDlAssign(const OCTETSTRING& par_tlli,
    const BITSTRING& par_group1__present,
    const OPTIONAL< PacketDlAssG1 >& par_group1,
    const BITSTRING& par_ta__index__present,
    const OPTIONAL< INTEGER >& par_ta__index,
    const BITSTRING& par_tbf__starting__time__present,
    const OPTIONAL< TbfStartingTime >& par_tbf__starting__time,
    const BITSTRING& par_p0__present,
    const OPTIONAL< INTEGER >& par_p0,
    const OPTIONAL< BITSTRING >& par_pr__mode)
  :   field_tlli(par_tlli),
  field_group1__present(par_group1__present),
  field_group1(par_group1),
  field_ta__index__present(par_ta__index__present),
  field_ta__index(par_ta__index),
  field_tbf__starting__time__present(par_tbf__starting__time__present),
  field_tbf__starting__time(par_tbf__starting__time),
  field_p0__present(par_p0__present),
  field_p0(par_p0),
  field_pr__mode(par_pr__mode)
{
}

PacketDlAssign::PacketDlAssign(const PacketDlAssign& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.PacketDlAssign.");
if (other_value.tlli().is_bound()) field_tlli = other_value.tlli();
else field_tlli.clean_up();
if (other_value.group1__present().is_bound()) field_group1__present = other_value.group1__present();
else field_group1__present.clean_up();
if (other_value.group1().is_bound()) field_group1 = other_value.group1();
else field_group1.clean_up();
if (other_value.ta__index__present().is_bound()) field_ta__index__present = other_value.ta__index__present();
else field_ta__index__present.clean_up();
if (other_value.ta__index().is_bound()) field_ta__index = other_value.ta__index();
else field_ta__index.clean_up();
if (other_value.tbf__starting__time__present().is_bound()) field_tbf__starting__time__present = other_value.tbf__starting__time__present();
else field_tbf__starting__time__present.clean_up();
if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
else field_tbf__starting__time.clean_up();
if (other_value.p0__present().is_bound()) field_p0__present = other_value.p0__present();
else field_p0__present.clean_up();
if (other_value.p0().is_bound()) field_p0 = other_value.p0();
else field_p0.clean_up();
if (other_value.pr__mode().is_bound()) field_pr__mode = other_value.pr__mode();
else field_pr__mode.clean_up();
}

void PacketDlAssign::clean_up()
{
field_tlli.clean_up();
field_group1__present.clean_up();
field_group1.clean_up();
field_ta__index__present.clean_up();
field_ta__index.clean_up();
field_tbf__starting__time__present.clean_up();
field_tbf__starting__time.clean_up();
field_p0__present.clean_up();
field_p0.clean_up();
field_pr__mode.clean_up();
}

const TTCN_Typedescriptor_t* PacketDlAssign::get_descriptor() const { return &PacketDlAssign_descr_; }
PacketDlAssign& PacketDlAssign::operator=(const PacketDlAssign& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.PacketDlAssign.");
  if (other_value.tlli().is_bound()) field_tlli = other_value.tlli();
  else field_tlli.clean_up();
  if (other_value.group1__present().is_bound()) field_group1__present = other_value.group1__present();
  else field_group1__present.clean_up();
  if (other_value.group1().is_bound()) field_group1 = other_value.group1();
  else field_group1.clean_up();
  if (other_value.ta__index__present().is_bound()) field_ta__index__present = other_value.ta__index__present();
  else field_ta__index__present.clean_up();
  if (other_value.ta__index().is_bound()) field_ta__index = other_value.ta__index();
  else field_ta__index.clean_up();
  if (other_value.tbf__starting__time__present().is_bound()) field_tbf__starting__time__present = other_value.tbf__starting__time__present();
  else field_tbf__starting__time__present.clean_up();
  if (other_value.tbf__starting__time().is_bound()) field_tbf__starting__time = other_value.tbf__starting__time();
  else field_tbf__starting__time.clean_up();
  if (other_value.p0__present().is_bound()) field_p0__present = other_value.p0__present();
  else field_p0__present.clean_up();
  if (other_value.p0().is_bound()) field_p0 = other_value.p0();
  else field_p0.clean_up();
  if (other_value.pr__mode().is_bound()) field_pr__mode = other_value.pr__mode();
  else field_pr__mode.clean_up();
}
return *this;
}

boolean PacketDlAssign::operator==(const PacketDlAssign& other_value) const
{
return field_tlli==other_value.field_tlli
  && field_group1__present==other_value.field_group1__present
  && field_group1==other_value.field_group1
  && field_ta__index__present==other_value.field_ta__index__present
  && field_ta__index==other_value.field_ta__index
  && field_tbf__starting__time__present==other_value.field_tbf__starting__time__present
  && field_tbf__starting__time==other_value.field_tbf__starting__time
  && field_p0__present==other_value.field_p0__present
  && field_p0==other_value.field_p0
  && field_pr__mode==other_value.field_pr__mode;
}

boolean PacketDlAssign::is_bound() const
{
return (field_tlli.is_bound())
  || (field_group1__present.is_bound())
  || (OPTIONAL_OMIT == field_group1.get_selection() || field_group1.is_bound())
  || (field_ta__index__present.is_bound())
  || (OPTIONAL_OMIT == field_ta__index.get_selection() || field_ta__index.is_bound())
  || (field_tbf__starting__time__present.is_bound())
  || (OPTIONAL_OMIT == field_tbf__starting__time.get_selection() || field_tbf__starting__time.is_bound())
  || (field_p0__present.is_bound())
  || (OPTIONAL_OMIT == field_p0.get_selection() || field_p0.is_bound())
  || (OPTIONAL_OMIT == field_pr__mode.get_selection() || field_pr__mode.is_bound());
}
boolean PacketDlAssign::is_value() const
{
return field_tlli.is_value()
  && field_group1__present.is_value()
  && (OPTIONAL_OMIT == field_group1.get_selection() || field_group1.is_value())
  && field_ta__index__present.is_value()
  && (OPTIONAL_OMIT == field_ta__index.get_selection() || field_ta__index.is_value())
  && field_tbf__starting__time__present.is_value()
  && (OPTIONAL_OMIT == field_tbf__starting__time.get_selection() || field_tbf__starting__time.is_value())
  && field_p0__present.is_value()
  && (OPTIONAL_OMIT == field_p0.get_selection() || field_p0.is_value())
  && (OPTIONAL_OMIT == field_pr__mode.get_selection() || field_pr__mode.is_value());
}
int PacketDlAssign::size_of() const
{
  int ret_val = 5;
  if (field_group1.ispresent()) ret_val++;
  if (field_ta__index.ispresent()) ret_val++;
  if (field_tbf__starting__time.ispresent()) ret_val++;
  if (field_p0.ispresent()) ret_val++;
  if (field_pr__mode.ispresent()) ret_val++;
  return ret_val;
}

void PacketDlAssign::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ tlli := ");
field_tlli.log();
TTCN_Logger::log_event_str(", group1_present := ");
field_group1__present.log();
TTCN_Logger::log_event_str(", group1 := ");
field_group1.log();
TTCN_Logger::log_event_str(", ta_index_present := ");
field_ta__index__present.log();
TTCN_Logger::log_event_str(", ta_index := ");
field_ta__index.log();
TTCN_Logger::log_event_str(", tbf_starting_time_present := ");
field_tbf__starting__time__present.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
field_tbf__starting__time.log();
TTCN_Logger::log_event_str(", p0_present := ");
field_p0__present.log();
TTCN_Logger::log_event_str(", p0 := ");
field_p0.log();
TTCN_Logger::log_event_str(", pr_mode := ");
field_pr__mode.log();
TTCN_Logger::log_event_str(" }");
}

void PacketDlAssign::set_implicit_omit()
{
if (tlli().is_bound()) tlli().set_implicit_omit();
if (group1__present().is_bound()) group1__present().set_implicit_omit();
if (!group1().is_bound()) group1() = OMIT_VALUE;
else group1().set_implicit_omit();
if (ta__index__present().is_bound()) ta__index__present().set_implicit_omit();
if (!ta__index().is_bound()) ta__index() = OMIT_VALUE;
else ta__index().set_implicit_omit();
if (tbf__starting__time__present().is_bound()) tbf__starting__time__present().set_implicit_omit();
if (!tbf__starting__time().is_bound()) tbf__starting__time() = OMIT_VALUE;
else tbf__starting__time().set_implicit_omit();
if (p0__present().is_bound()) p0__present().set_implicit_omit();
if (!p0().is_bound()) p0() = OMIT_VALUE;
else p0().set_implicit_omit();
if (!pr__mode().is_bound()) pr__mode() = OMIT_VALUE;
else pr__mode().set_implicit_omit();
}

void PacketDlAssign::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (10<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.PacketDlAssign has 10 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) tlli().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) group1__present().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) group1().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) ta__index__present().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) ta__index().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time__present().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(6));
    if (param.get_size()>7 && param.get_elem(7)->get_type()!=Module_Param::MP_NotUsed) p0__present().set_param(*param.get_elem(7));
    if (param.get_size()>8 && param.get_elem(8)->get_type()!=Module_Param::MP_NotUsed) p0().set_param(*param.get_elem(8));
    if (param.get_size()>9 && param.get_elem(9)->get_type()!=Module_Param::MP_NotUsed) pr__mode().set_param(*param.get_elem(9));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tlli")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tlli().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "group1_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          group1__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "group1")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          group1().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pr_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pr__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketDlAssign: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.PacketDlAssign");
  }
}

void PacketDlAssign::encode_text(Text_Buf& text_buf) const
{
field_tlli.encode_text(text_buf);
field_group1__present.encode_text(text_buf);
field_group1.encode_text(text_buf);
field_ta__index__present.encode_text(text_buf);
field_ta__index.encode_text(text_buf);
field_tbf__starting__time__present.encode_text(text_buf);
field_tbf__starting__time.encode_text(text_buf);
field_p0__present.encode_text(text_buf);
field_p0.encode_text(text_buf);
field_pr__mode.encode_text(text_buf);
}

void PacketDlAssign::decode_text(Text_Buf& text_buf)
{
field_tlli.decode_text(text_buf);
field_group1__present.decode_text(text_buf);
field_group1.decode_text(text_buf);
field_ta__index__present.decode_text(text_buf);
field_ta__index.decode_text(text_buf);
field_tbf__starting__time__present.decode_text(text_buf);
field_tbf__starting__time.decode_text(text_buf);
field_p0__present.decode_text(text_buf);
field_p0.decode_text(text_buf);
field_pr__mode.decode_text(text_buf);
}

void PacketDlAssign::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void PacketDlAssign::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int PacketDlAssign::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, PacketDlAssign_tlli_descr_.raw->forceomit);
  decoded_field_length = field_tlli.RAW_decode(PacketDlAssign_tlli_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_1_force_omit(1, force_omit, PacketDlAssign_group1__present_descr_.raw->forceomit);
  decoded_field_length = field_group1__present.RAW_decode(PacketDlAssign_group1__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_group1__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(2)) {
    field_group1 = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_2_force_omit(2, force_omit, PacketDlAssign_group1_descr_.raw->forceomit);
  decoded_field_length = field_group1().RAW_decode(PacketDlAssign_group1_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 1) {
  field_group1 = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_group1=OMIT_VALUE;
  RAW_Force_Omit field_3_force_omit(3, force_omit, PacketDlAssign_ta__index__present_descr_.raw->forceomit);
  decoded_field_length = field_ta__index__present.RAW_decode(PacketDlAssign_ta__index__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_3_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_ta__index__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(4)) {
    field_ta__index = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_4_force_omit(4, force_omit, PacketDlAssign_ta__index_descr_.raw->forceomit);
  decoded_field_length = field_ta__index().RAW_decode(PacketDlAssign_ta__index_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_4_force_omit);
  if (decoded_field_length < 1) {
  field_ta__index = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_ta__index=OMIT_VALUE;
  RAW_Force_Omit field_5_force_omit(5, force_omit, PacketDlAssign_tbf__starting__time__present_descr_.raw->forceomit);
  decoded_field_length = field_tbf__starting__time__present.RAW_decode(PacketDlAssign_tbf__starting__time__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_5_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_tbf__starting__time__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(6)) {
    field_tbf__starting__time = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_6_force_omit(6, force_omit, PacketDlAssign_tbf__starting__time_descr_.raw->forceomit);
  decoded_field_length = field_tbf__starting__time().RAW_decode(PacketDlAssign_tbf__starting__time_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_6_force_omit);
  if (decoded_field_length < 1) {
  field_tbf__starting__time = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_tbf__starting__time=OMIT_VALUE;
  RAW_Force_Omit field_7_force_omit(7, force_omit, PacketDlAssign_p0__present_descr_.raw->forceomit);
  decoded_field_length = field_p0__present.RAW_decode(PacketDlAssign_p0__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_7_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_p0__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(8)) {
    field_p0 = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_8_force_omit(8, force_omit, PacketDlAssign_p0_descr_.raw->forceomit);
  decoded_field_length = field_p0().RAW_decode(PacketDlAssign_p0_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_8_force_omit);
  if (decoded_field_length < 1) {
  field_p0 = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_p0=OMIT_VALUE;
  if (limit > 0 && field_p0__present ==  bs_0){
  if (force_omit != NULL && (*force_omit)(9)) {
    field_pr__mode = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_9_force_omit(9, force_omit, PacketDlAssign_pr__mode_descr_.raw->forceomit);
  decoded_field_length = field_pr__mode().RAW_decode(PacketDlAssign_pr__mode_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_9_force_omit);
  if (decoded_field_length < 1) {
  field_pr__mode = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_pr__mode=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int PacketDlAssign::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 10;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(10);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, PacketDlAssign_tlli_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, PacketDlAssign_group1__present_descr_.raw);
  if (field_group1.ispresent()) {
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, PacketDlAssign_group1_descr_.raw);
  }
  else myleaf.body.node.nodes[2] = NULL;
  myleaf.body.node.nodes[3] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 3, PacketDlAssign_ta__index__present_descr_.raw);
  if (field_ta__index.ispresent()) {
  myleaf.body.node.nodes[4] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 4, PacketDlAssign_ta__index_descr_.raw);
  }
  else myleaf.body.node.nodes[4] = NULL;
  myleaf.body.node.nodes[5] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 5, PacketDlAssign_tbf__starting__time__present_descr_.raw);
  if (field_tbf__starting__time.ispresent()) {
  myleaf.body.node.nodes[6] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 6, PacketDlAssign_tbf__starting__time_descr_.raw);
  }
  else myleaf.body.node.nodes[6] = NULL;
  myleaf.body.node.nodes[7] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 7, PacketDlAssign_p0__present_descr_.raw);
  if (field_p0.ispresent()) {
  myleaf.body.node.nodes[8] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 8, PacketDlAssign_p0_descr_.raw);
  }
  else myleaf.body.node.nodes[8] = NULL;
  if (field_pr__mode.ispresent()) {
  myleaf.body.node.nodes[9] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 9, PacketDlAssign_pr__mode_descr_.raw);
  }
  else myleaf.body.node.nodes[9] = NULL;
  encoded_length += field_tlli.RAW_encode(PacketDlAssign_tlli_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_group1__present.RAW_encode(PacketDlAssign_group1__present_descr_, *myleaf.body.node.nodes[1]);
  if (field_group1.ispresent()) {
  encoded_length += field_group1().RAW_encode(PacketDlAssign_group1_descr_, *myleaf.body.node.nodes[2]);
  }
  encoded_length += field_ta__index__present.RAW_encode(PacketDlAssign_ta__index__present_descr_, *myleaf.body.node.nodes[3]);
  if (field_ta__index.ispresent()) {
  encoded_length += field_ta__index().RAW_encode(PacketDlAssign_ta__index_descr_, *myleaf.body.node.nodes[4]);
  }
  encoded_length += field_tbf__starting__time__present.RAW_encode(PacketDlAssign_tbf__starting__time__present_descr_, *myleaf.body.node.nodes[5]);
  if (field_tbf__starting__time.ispresent()) {
  encoded_length += field_tbf__starting__time().RAW_encode(PacketDlAssign_tbf__starting__time_descr_, *myleaf.body.node.nodes[6]);
  }
  encoded_length += field_p0__present.RAW_encode(PacketDlAssign_p0__present_descr_, *myleaf.body.node.nodes[7]);
  if (field_p0.ispresent()) {
  encoded_length += field_p0().RAW_encode(PacketDlAssign_p0_descr_, *myleaf.body.node.nodes[8]);
  }
  if (field_pr__mode.ispresent()) {
  encoded_length += field_pr__mode().RAW_encode(PacketDlAssign_pr__mode_descr_, *myleaf.body.node.nodes[9]);
  }
  if (field_group1.ispresent() && (field_group1__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={1};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketDlAssign_group1__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_ta__index.ispresent() && (field_ta__index__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={3};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketDlAssign_ta__index__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_tbf__starting__time.ispresent() && (field_tbf__starting__time__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={5};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketDlAssign_tbf__starting__time__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_p0.ispresent() && (field_p0__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={7};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketDlAssign_p0__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  if (field_pr__mode.ispresent() && (field_p0__present !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={7};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(PacketDlAssign_p0__present_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct PacketDlAssign_template::single_value_struct {
OCTETSTRING_template field_tlli;
BITSTRING_template field_group1__present;
PacketDlAssG1_template field_group1;
BITSTRING_template field_ta__index__present;
INTEGER_template field_ta__index;
BITSTRING_template field_tbf__starting__time__present;
TbfStartingTime_template field_tbf__starting__time;
BITSTRING_template field_p0__present;
INTEGER_template field_p0;
BITSTRING_template field_pr__mode;
};

void PacketDlAssign_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_tlli = ANY_VALUE;
single_value->field_group1__present = ANY_VALUE;
single_value->field_group1 = ANY_OR_OMIT;
single_value->field_ta__index__present = ANY_VALUE;
single_value->field_ta__index = ANY_OR_OMIT;
single_value->field_tbf__starting__time__present = ANY_VALUE;
single_value->field_tbf__starting__time = ANY_OR_OMIT;
single_value->field_p0__present = ANY_VALUE;
single_value->field_p0 = ANY_OR_OMIT;
single_value->field_pr__mode = ANY_OR_OMIT;
}
}
}

void PacketDlAssign_template::copy_value(const PacketDlAssign& other_value)
{
single_value = new single_value_struct;
if (other_value.tlli().is_bound()) {
  single_value->field_tlli = other_value.tlli();
} else {
  single_value->field_tlli.clean_up();
}
if (other_value.group1__present().is_bound()) {
  single_value->field_group1__present = other_value.group1__present();
} else {
  single_value->field_group1__present.clean_up();
}
if (other_value.group1().is_bound()) {
  if (other_value.group1().ispresent()) single_value->field_group1 = other_value.group1()();
  else single_value->field_group1 = OMIT_VALUE;
} else {
  single_value->field_group1.clean_up();
}
if (other_value.ta__index__present().is_bound()) {
  single_value->field_ta__index__present = other_value.ta__index__present();
} else {
  single_value->field_ta__index__present.clean_up();
}
if (other_value.ta__index().is_bound()) {
  if (other_value.ta__index().ispresent()) single_value->field_ta__index = other_value.ta__index()();
  else single_value->field_ta__index = OMIT_VALUE;
} else {
  single_value->field_ta__index.clean_up();
}
if (other_value.tbf__starting__time__present().is_bound()) {
  single_value->field_tbf__starting__time__present = other_value.tbf__starting__time__present();
} else {
  single_value->field_tbf__starting__time__present.clean_up();
}
if (other_value.tbf__starting__time().is_bound()) {
  if (other_value.tbf__starting__time().ispresent()) single_value->field_tbf__starting__time = other_value.tbf__starting__time()();
  else single_value->field_tbf__starting__time = OMIT_VALUE;
} else {
  single_value->field_tbf__starting__time.clean_up();
}
if (other_value.p0__present().is_bound()) {
  single_value->field_p0__present = other_value.p0__present();
} else {
  single_value->field_p0__present.clean_up();
}
if (other_value.p0().is_bound()) {
  if (other_value.p0().ispresent()) single_value->field_p0 = other_value.p0()();
  else single_value->field_p0 = OMIT_VALUE;
} else {
  single_value->field_p0.clean_up();
}
if (other_value.pr__mode().is_bound()) {
  if (other_value.pr__mode().ispresent()) single_value->field_pr__mode = other_value.pr__mode()();
  else single_value->field_pr__mode = OMIT_VALUE;
} else {
  single_value->field_pr__mode.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void PacketDlAssign_template::copy_template(const PacketDlAssign_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.tlli().get_selection()) {
single_value->field_tlli = other_value.tlli();
} else {
single_value->field_tlli.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.group1__present().get_selection()) {
single_value->field_group1__present = other_value.group1__present();
} else {
single_value->field_group1__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.group1().get_selection()) {
single_value->field_group1 = other_value.group1();
} else {
single_value->field_group1.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ta__index__present().get_selection()) {
single_value->field_ta__index__present = other_value.ta__index__present();
} else {
single_value->field_ta__index__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ta__index().get_selection()) {
single_value->field_ta__index = other_value.ta__index();
} else {
single_value->field_ta__index.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tbf__starting__time__present().get_selection()) {
single_value->field_tbf__starting__time__present = other_value.tbf__starting__time__present();
} else {
single_value->field_tbf__starting__time__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.tbf__starting__time().get_selection()) {
single_value->field_tbf__starting__time = other_value.tbf__starting__time();
} else {
single_value->field_tbf__starting__time.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.p0__present().get_selection()) {
single_value->field_p0__present = other_value.p0__present();
} else {
single_value->field_p0__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.p0().get_selection()) {
single_value->field_p0 = other_value.p0();
} else {
single_value->field_p0.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.pr__mode().get_selection()) {
single_value->field_pr__mode = other_value.pr__mode();
} else {
single_value->field_pr__mode.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new PacketDlAssign_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new PacketDlAssign_template(*other_value.implication_.precondition);
implication_.implied_template = new PacketDlAssign_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.PacketDlAssign.");
break;
}
set_selection(other_value);
}

PacketDlAssign_template::PacketDlAssign_template()
{
}

PacketDlAssign_template::PacketDlAssign_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

PacketDlAssign_template::PacketDlAssign_template(const PacketDlAssign& other_value)
{
copy_value(other_value);
}

PacketDlAssign_template::PacketDlAssign_template(const OPTIONAL<PacketDlAssign>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketDlAssign&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.PacketDlAssign from an unbound optional field.");
}
}

PacketDlAssign_template::PacketDlAssign_template(PacketDlAssign_template* p_precondition, PacketDlAssign_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

PacketDlAssign_template::PacketDlAssign_template(Dynamic_Match_Interface<PacketDlAssign>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<PacketDlAssign>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

PacketDlAssign_template::PacketDlAssign_template(const PacketDlAssign_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

PacketDlAssign_template::~PacketDlAssign_template()
{
clean_up();
}

PacketDlAssign_template& PacketDlAssign_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

PacketDlAssign_template& PacketDlAssign_template::operator=(const PacketDlAssign& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

PacketDlAssign_template& PacketDlAssign_template::operator=(const OPTIONAL<PacketDlAssign>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketDlAssign&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.PacketDlAssign.");
}
return *this;
}

PacketDlAssign_template& PacketDlAssign_template::operator=(const PacketDlAssign_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean PacketDlAssign_template::match(const PacketDlAssign& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.tlli().is_bound()) return FALSE;
if(!single_value->field_tlli.match(other_value.tlli(), legacy))return FALSE;
if(!other_value.group1__present().is_bound()) return FALSE;
if(!single_value->field_group1__present.match(other_value.group1__present(), legacy))return FALSE;
if(!other_value.group1().is_bound()) return FALSE;
if((other_value.group1().ispresent() ? !single_value->field_group1.match((const PacketDlAssG1&)other_value.group1(), legacy) : !single_value->field_group1.match_omit(legacy)))return FALSE;
if(!other_value.ta__index__present().is_bound()) return FALSE;
if(!single_value->field_ta__index__present.match(other_value.ta__index__present(), legacy))return FALSE;
if(!other_value.ta__index().is_bound()) return FALSE;
if((other_value.ta__index().ispresent() ? !single_value->field_ta__index.match((const INTEGER&)other_value.ta__index(), legacy) : !single_value->field_ta__index.match_omit(legacy)))return FALSE;
if(!other_value.tbf__starting__time__present().is_bound()) return FALSE;
if(!single_value->field_tbf__starting__time__present.match(other_value.tbf__starting__time__present(), legacy))return FALSE;
if(!other_value.tbf__starting__time().is_bound()) return FALSE;
if((other_value.tbf__starting__time().ispresent() ? !single_value->field_tbf__starting__time.match((const TbfStartingTime&)other_value.tbf__starting__time(), legacy) : !single_value->field_tbf__starting__time.match_omit(legacy)))return FALSE;
if(!other_value.p0__present().is_bound()) return FALSE;
if(!single_value->field_p0__present.match(other_value.p0__present(), legacy))return FALSE;
if(!other_value.p0().is_bound()) return FALSE;
if((other_value.p0().ispresent() ? !single_value->field_p0.match((const INTEGER&)other_value.p0(), legacy) : !single_value->field_p0.match_omit(legacy)))return FALSE;
if(!other_value.pr__mode().is_bound()) return FALSE;
if((other_value.pr__mode().ispresent() ? !single_value->field_pr__mode.match((const BITSTRING&)other_value.pr__mode(), legacy) : !single_value->field_pr__mode.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.PacketDlAssign.");
}
return FALSE;
}

boolean PacketDlAssign_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_tlli.is_bound()
 || single_value->field_group1__present.is_bound()
 || (single_value->field_group1.is_omit() || single_value->field_group1.is_bound())
 || single_value->field_ta__index__present.is_bound()
 || (single_value->field_ta__index.is_omit() || single_value->field_ta__index.is_bound())
 || single_value->field_tbf__starting__time__present.is_bound()
 || (single_value->field_tbf__starting__time.is_omit() || single_value->field_tbf__starting__time.is_bound())
 || single_value->field_p0__present.is_bound()
 || (single_value->field_p0.is_omit() || single_value->field_p0.is_bound())
 || (single_value->field_pr__mode.is_omit() || single_value->field_pr__mode.is_bound());
}

boolean PacketDlAssign_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_tlli.is_value()
 && single_value->field_group1__present.is_value()
 && (single_value->field_group1.is_omit() || single_value->field_group1.is_value())
 && single_value->field_ta__index__present.is_value()
 && (single_value->field_ta__index.is_omit() || single_value->field_ta__index.is_value())
 && single_value->field_tbf__starting__time__present.is_value()
 && (single_value->field_tbf__starting__time.is_omit() || single_value->field_tbf__starting__time.is_value())
 && single_value->field_p0__present.is_value()
 && (single_value->field_p0.is_omit() || single_value->field_p0.is_value())
 && (single_value->field_pr__mode.is_omit() || single_value->field_pr__mode.is_value());
}

void PacketDlAssign_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

PacketDlAssign PacketDlAssign_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
PacketDlAssign ret_val;
if (single_value->field_tlli.is_bound()) {
ret_val.tlli() = single_value->field_tlli.valueof();
}
if (single_value->field_group1__present.is_bound()) {
ret_val.group1__present() = single_value->field_group1__present.valueof();
}
if (single_value->field_group1.is_omit()) ret_val.group1() = OMIT_VALUE;
else if (single_value->field_group1.is_bound()) {
ret_val.group1() = single_value->field_group1.valueof();
}
if (single_value->field_ta__index__present.is_bound()) {
ret_val.ta__index__present() = single_value->field_ta__index__present.valueof();
}
if (single_value->field_ta__index.is_omit()) ret_val.ta__index() = OMIT_VALUE;
else if (single_value->field_ta__index.is_bound()) {
ret_val.ta__index() = single_value->field_ta__index.valueof();
}
if (single_value->field_tbf__starting__time__present.is_bound()) {
ret_val.tbf__starting__time__present() = single_value->field_tbf__starting__time__present.valueof();
}
if (single_value->field_tbf__starting__time.is_omit()) ret_val.tbf__starting__time() = OMIT_VALUE;
else if (single_value->field_tbf__starting__time.is_bound()) {
ret_val.tbf__starting__time() = single_value->field_tbf__starting__time.valueof();
}
if (single_value->field_p0__present.is_bound()) {
ret_val.p0__present() = single_value->field_p0__present.valueof();
}
if (single_value->field_p0.is_omit()) ret_val.p0() = OMIT_VALUE;
else if (single_value->field_p0.is_bound()) {
ret_val.p0() = single_value->field_p0.valueof();
}
if (single_value->field_pr__mode.is_omit()) ret_val.pr__mode() = OMIT_VALUE;
else if (single_value->field_pr__mode.is_bound()) {
ret_val.pr__mode() = single_value->field_pr__mode.valueof();
}
return ret_val;
}

void PacketDlAssign_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.PacketDlAssign.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new PacketDlAssign_template[list_length];
}

PacketDlAssign_template& PacketDlAssign_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.PacketDlAssign.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.PacketDlAssign.");
return value_list.list_value[list_index];
}

OCTETSTRING_template& PacketDlAssign_template::tlli()
{
set_specific();
return single_value->field_tlli;
}

const OCTETSTRING_template& PacketDlAssign_template::tlli() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tlli of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_tlli;
}

BITSTRING_template& PacketDlAssign_template::group1__present()
{
set_specific();
return single_value->field_group1__present;
}

const BITSTRING_template& PacketDlAssign_template::group1__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field group1_present of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_group1__present;
}

PacketDlAssG1_template& PacketDlAssign_template::group1()
{
set_specific();
return single_value->field_group1;
}

const PacketDlAssG1_template& PacketDlAssign_template::group1() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field group1 of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_group1;
}

BITSTRING_template& PacketDlAssign_template::ta__index__present()
{
set_specific();
return single_value->field_ta__index__present;
}

const BITSTRING_template& PacketDlAssign_template::ta__index__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ta_index_present of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_ta__index__present;
}

INTEGER_template& PacketDlAssign_template::ta__index()
{
set_specific();
return single_value->field_ta__index;
}

const INTEGER_template& PacketDlAssign_template::ta__index() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ta_index of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_ta__index;
}

BITSTRING_template& PacketDlAssign_template::tbf__starting__time__present()
{
set_specific();
return single_value->field_tbf__starting__time__present;
}

const BITSTRING_template& PacketDlAssign_template::tbf__starting__time__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tbf_starting_time_present of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_tbf__starting__time__present;
}

TbfStartingTime_template& PacketDlAssign_template::tbf__starting__time()
{
set_specific();
return single_value->field_tbf__starting__time;
}

const TbfStartingTime_template& PacketDlAssign_template::tbf__starting__time() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tbf_starting_time of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_tbf__starting__time;
}

BITSTRING_template& PacketDlAssign_template::p0__present()
{
set_specific();
return single_value->field_p0__present;
}

const BITSTRING_template& PacketDlAssign_template::p0__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field p0_present of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_p0__present;
}

INTEGER_template& PacketDlAssign_template::p0()
{
set_specific();
return single_value->field_p0;
}

const INTEGER_template& PacketDlAssign_template::p0() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field p0 of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_p0;
}

BITSTRING_template& PacketDlAssign_template::pr__mode()
{
set_specific();
return single_value->field_pr__mode;
}

const BITSTRING_template& PacketDlAssign_template::pr__mode() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field pr_mode of a non-specific template of type @GSM_RestOctets.PacketDlAssign.");
return single_value->field_pr__mode;
}

int PacketDlAssign_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssign which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 5;
      if (single_value->field_group1.is_present()) ret_val++;
      if (single_value->field_ta__index.is_present()) ret_val++;
      if (single_value->field_tbf__starting__time.is_present()) ret_val++;
      if (single_value->field_p0.is_present()) ret_val++;
      if (single_value->field_pr__mode.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssign containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssign containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssign containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssign containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssign containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssign containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssign containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssign containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.PacketDlAssign.");
  }
  return 0;
}

void PacketDlAssign_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ tlli := ");
single_value->field_tlli.log();
TTCN_Logger::log_event_str(", group1_present := ");
single_value->field_group1__present.log();
TTCN_Logger::log_event_str(", group1 := ");
single_value->field_group1.log();
TTCN_Logger::log_event_str(", ta_index_present := ");
single_value->field_ta__index__present.log();
TTCN_Logger::log_event_str(", ta_index := ");
single_value->field_ta__index.log();
TTCN_Logger::log_event_str(", tbf_starting_time_present := ");
single_value->field_tbf__starting__time__present.log();
TTCN_Logger::log_event_str(", tbf_starting_time := ");
single_value->field_tbf__starting__time.log();
TTCN_Logger::log_event_str(", p0_present := ");
single_value->field_p0__present.log();
TTCN_Logger::log_event_str(", p0 := ");
single_value->field_p0.log();
TTCN_Logger::log_event_str(", pr_mode := ");
single_value->field_pr__mode.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void PacketDlAssign_template::log_match(const PacketDlAssign& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_tlli.match(match_value.tlli(), legacy)){
TTCN_Logger::log_logmatch_info(".tlli");
single_value->field_tlli.log_match(match_value.tlli(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_group1__present.match(match_value.group1__present(), legacy)){
TTCN_Logger::log_logmatch_info(".group1_present");
single_value->field_group1__present.log_match(match_value.group1__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.group1().ispresent()){
if(!single_value->field_group1.match(match_value.group1(), legacy)){
TTCN_Logger::log_logmatch_info(".group1");
single_value->field_group1.log_match(match_value.group1(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_group1.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".group1 := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_group1.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_ta__index__present.match(match_value.ta__index__present(), legacy)){
TTCN_Logger::log_logmatch_info(".ta_index_present");
single_value->field_ta__index__present.log_match(match_value.ta__index__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.ta__index().ispresent()){
if(!single_value->field_ta__index.match(match_value.ta__index(), legacy)){
TTCN_Logger::log_logmatch_info(".ta_index");
single_value->field_ta__index.log_match(match_value.ta__index(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_ta__index.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".ta_index := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_ta__index.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_tbf__starting__time__present.match(match_value.tbf__starting__time__present(), legacy)){
TTCN_Logger::log_logmatch_info(".tbf_starting_time_present");
single_value->field_tbf__starting__time__present.log_match(match_value.tbf__starting__time__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.tbf__starting__time().ispresent()){
if(!single_value->field_tbf__starting__time.match(match_value.tbf__starting__time(), legacy)){
TTCN_Logger::log_logmatch_info(".tbf_starting_time");
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_tbf__starting__time.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".tbf_starting_time := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_tbf__starting__time.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_p0__present.match(match_value.p0__present(), legacy)){
TTCN_Logger::log_logmatch_info(".p0_present");
single_value->field_p0__present.log_match(match_value.p0__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.p0().ispresent()){
if(!single_value->field_p0.match(match_value.p0(), legacy)){
TTCN_Logger::log_logmatch_info(".p0");
single_value->field_p0.log_match(match_value.p0(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_p0.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".p0 := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_p0.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if (match_value.pr__mode().ispresent()){
if(!single_value->field_pr__mode.match(match_value.pr__mode(), legacy)){
TTCN_Logger::log_logmatch_info(".pr_mode");
single_value->field_pr__mode.log_match(match_value.pr__mode(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_pr__mode.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".pr_mode := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_pr__mode.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ tlli := ");
single_value->field_tlli.log_match(match_value.tlli(), legacy);
TTCN_Logger::log_event_str(", group1_present := ");
single_value->field_group1__present.log_match(match_value.group1__present(), legacy);
TTCN_Logger::log_event_str(", group1 := ");
if (match_value.group1().ispresent()) {
single_value->field_group1.log_match(match_value.group1(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_group1.log();
if (single_value->field_group1.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", ta_index_present := ");
single_value->field_ta__index__present.log_match(match_value.ta__index__present(), legacy);
TTCN_Logger::log_event_str(", ta_index := ");
if (match_value.ta__index().ispresent()) {
single_value->field_ta__index.log_match(match_value.ta__index(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_ta__index.log();
if (single_value->field_ta__index.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", tbf_starting_time_present := ");
single_value->field_tbf__starting__time__present.log_match(match_value.tbf__starting__time__present(), legacy);
TTCN_Logger::log_event_str(", tbf_starting_time := ");
if (match_value.tbf__starting__time().ispresent()) {
single_value->field_tbf__starting__time.log_match(match_value.tbf__starting__time(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_tbf__starting__time.log();
if (single_value->field_tbf__starting__time.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", p0_present := ");
single_value->field_p0__present.log_match(match_value.p0__present(), legacy);
TTCN_Logger::log_event_str(", p0 := ");
if (match_value.p0().ispresent()) {
single_value->field_p0.log_match(match_value.p0(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_p0.log();
if (single_value->field_p0.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", pr_mode := ");
if (match_value.pr__mode().ispresent()) {
single_value->field_pr__mode.log_match(match_value.pr__mode(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_pr__mode.log();
if (single_value->field_pr__mode.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void PacketDlAssign_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (tlli().is_bound()) tlli().set_implicit_omit();
if (group1__present().is_bound()) group1__present().set_implicit_omit();
if (!group1().is_bound()) group1() = OMIT_VALUE;
else group1().set_implicit_omit();
if (ta__index__present().is_bound()) ta__index__present().set_implicit_omit();
if (!ta__index().is_bound()) ta__index() = OMIT_VALUE;
else ta__index().set_implicit_omit();
if (tbf__starting__time__present().is_bound()) tbf__starting__time__present().set_implicit_omit();
if (!tbf__starting__time().is_bound()) tbf__starting__time() = OMIT_VALUE;
else tbf__starting__time().set_implicit_omit();
if (p0__present().is_bound()) p0__present().set_implicit_omit();
if (!p0().is_bound()) p0() = OMIT_VALUE;
else p0().set_implicit_omit();
if (!pr__mode().is_bound()) pr__mode() = OMIT_VALUE;
else pr__mode().set_implicit_omit();
}

void PacketDlAssign_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_tlli.encode_text(text_buf);
single_value->field_group1__present.encode_text(text_buf);
single_value->field_group1.encode_text(text_buf);
single_value->field_ta__index__present.encode_text(text_buf);
single_value->field_ta__index.encode_text(text_buf);
single_value->field_tbf__starting__time__present.encode_text(text_buf);
single_value->field_tbf__starting__time.encode_text(text_buf);
single_value->field_p0__present.encode_text(text_buf);
single_value->field_p0.encode_text(text_buf);
single_value->field_pr__mode.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.PacketDlAssign.");
}
}

void PacketDlAssign_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_tlli.decode_text(text_buf);
single_value->field_group1__present.decode_text(text_buf);
single_value->field_group1.decode_text(text_buf);
single_value->field_ta__index__present.decode_text(text_buf);
single_value->field_ta__index.decode_text(text_buf);
single_value->field_tbf__starting__time__present.decode_text(text_buf);
single_value->field_tbf__starting__time.decode_text(text_buf);
single_value->field_p0__present.decode_text(text_buf);
single_value->field_p0.decode_text(text_buf);
single_value->field_pr__mode.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new PacketDlAssign_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.PacketDlAssign.");
}
}

void PacketDlAssign_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    PacketDlAssign_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (10<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.PacketDlAssign has 10 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) tlli().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) group1__present().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) group1().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) ta__index__present().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) ta__index().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time__present().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) tbf__starting__time().set_param(*param.get_elem(6));
    if (param.get_size()>7 && param.get_elem(7)->get_type()!=Module_Param::MP_NotUsed) p0__present().set_param(*param.get_elem(7));
    if (param.get_size()>8 && param.get_elem(8)->get_type()!=Module_Param::MP_NotUsed) p0().set_param(*param.get_elem(8));
    if (param.get_size()>9 && param.get_elem(9)->get_type()!=Module_Param::MP_NotUsed) pr__mode().set_param(*param.get_elem(9));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tlli")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tlli().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "group1_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          group1__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "group1")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          group1().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_index")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__index().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tbf_starting_time")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tbf__starting__time().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "p0")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          p0().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pr_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pr__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketDlAssign: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    PacketDlAssign_template* precondition = new PacketDlAssign_template;
    precondition->set_param(*param.get_elem(0));
    PacketDlAssign_template* implied_template = new PacketDlAssign_template;
    implied_template->set_param(*param.get_elem(1));
    *this = PacketDlAssign_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.PacketDlAssign");
  }
  is_ifpresent = param.get_ifpresent();
}

void PacketDlAssign_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_tlli.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
single_value->field_group1__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
single_value->field_group1.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
single_value->field_ta__index__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
single_value->field_ta__index.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
single_value->field_tbf__starting__time__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
single_value->field_tbf__starting__time.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
single_value->field_p0__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
single_value->field_p0.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
single_value->field_pr__mode.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.PacketDlAssign");
}

boolean PacketDlAssign_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean PacketDlAssign_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

PacketDlAssG1::PacketDlAssG1()
{
}

PacketDlAssG1::PacketDlAssG1(const INTEGER& par_tfi__assignment,
    const BITSTRING& par_rlc__mode,
    const BITSTRING& par_alpha__present,
    const OPTIONAL< INTEGER >& par_alpha,
    const INTEGER& par_gamma,
    const BITSTRING& par_polling,
    const BITSTRING& par_ta__valid)
  :   field_tfi__assignment(par_tfi__assignment),
  field_rlc__mode(par_rlc__mode),
  field_alpha__present(par_alpha__present),
  field_alpha(par_alpha),
  field_gamma(par_gamma),
  field_polling(par_polling),
  field_ta__valid(par_ta__valid)
{
}

PacketDlAssG1::PacketDlAssG1(const PacketDlAssG1& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.PacketDlAssG1.");
if (other_value.tfi__assignment().is_bound()) field_tfi__assignment = other_value.tfi__assignment();
else field_tfi__assignment.clean_up();
if (other_value.rlc__mode().is_bound()) field_rlc__mode = other_value.rlc__mode();
else field_rlc__mode.clean_up();
if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
else field_alpha__present.clean_up();
if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
else field_alpha.clean_up();
if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
else field_gamma.clean_up();
if (other_value.polling().is_bound()) field_polling = other_value.polling();
else field_polling.clean_up();
if (other_value.ta__valid().is_bound()) field_ta__valid = other_value.ta__valid();
else field_ta__valid.clean_up();
}

void PacketDlAssG1::clean_up()
{
field_tfi__assignment.clean_up();
field_rlc__mode.clean_up();
field_alpha__present.clean_up();
field_alpha.clean_up();
field_gamma.clean_up();
field_polling.clean_up();
field_ta__valid.clean_up();
}

const TTCN_Typedescriptor_t* PacketDlAssG1::get_descriptor() const { return &PacketDlAssG1_descr_; }
PacketDlAssG1& PacketDlAssG1::operator=(const PacketDlAssG1& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.PacketDlAssG1.");
  if (other_value.tfi__assignment().is_bound()) field_tfi__assignment = other_value.tfi__assignment();
  else field_tfi__assignment.clean_up();
  if (other_value.rlc__mode().is_bound()) field_rlc__mode = other_value.rlc__mode();
  else field_rlc__mode.clean_up();
  if (other_value.alpha__present().is_bound()) field_alpha__present = other_value.alpha__present();
  else field_alpha__present.clean_up();
  if (other_value.alpha().is_bound()) field_alpha = other_value.alpha();
  else field_alpha.clean_up();
  if (other_value.gamma().is_bound()) field_gamma = other_value.gamma();
  else field_gamma.clean_up();
  if (other_value.polling().is_bound()) field_polling = other_value.polling();
  else field_polling.clean_up();
  if (other_value.ta__valid().is_bound()) field_ta__valid = other_value.ta__valid();
  else field_ta__valid.clean_up();
}
return *this;
}

boolean PacketDlAssG1::operator==(const PacketDlAssG1& other_value) const
{
return field_tfi__assignment==other_value.field_tfi__assignment
  && field_rlc__mode==other_value.field_rlc__mode
  && field_alpha__present==other_value.field_alpha__present
  && field_alpha==other_value.field_alpha
  && field_gamma==other_value.field_gamma
  && field_polling==other_value.field_polling
  && field_ta__valid==other_value.field_ta__valid;
}

boolean PacketDlAssG1::is_bound() const
{
return (field_tfi__assignment.is_bound())
  || (field_rlc__mode.is_bound())
  || (field_alpha__present.is_bound())
  || (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_bound())
  || (field_gamma.is_bound())
  || (field_polling.is_bound())
  || (field_ta__valid.is_bound());
}
boolean PacketDlAssG1::is_value() const
{
return field_tfi__assignment.is_value()
  && field_rlc__mode.is_value()
  && field_alpha__present.is_value()
  && (OPTIONAL_OMIT == field_alpha.get_selection() || field_alpha.is_value())
  && field_gamma.is_value()
  && field_polling.is_value()
  && field_ta__valid.is_value();
}
int PacketDlAssG1::size_of() const
{
  int ret_val = 6;
  if (field_alpha.ispresent()) ret_val++;
  return ret_val;
}

void PacketDlAssG1::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ tfi_assignment := ");
field_tfi__assignment.log();
TTCN_Logger::log_event_str(", rlc_mode := ");
field_rlc__mode.log();
TTCN_Logger::log_event_str(", alpha_present := ");
field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
field_gamma.log();
TTCN_Logger::log_event_str(", polling := ");
field_polling.log();
TTCN_Logger::log_event_str(", ta_valid := ");
field_ta__valid.log();
TTCN_Logger::log_event_str(" }");
}

void PacketDlAssG1::set_implicit_omit()
{
if (tfi__assignment().is_bound()) tfi__assignment().set_implicit_omit();
if (rlc__mode().is_bound()) rlc__mode().set_implicit_omit();
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (polling().is_bound()) polling().set_implicit_omit();
if (ta__valid().is_bound()) ta__valid().set_implicit_omit();
}

void PacketDlAssG1::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (7<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.PacketDlAssG1 has 7 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) tfi__assignment().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) rlc__mode().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) polling().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) ta__valid().set_param(*param.get_elem(6));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tfi_assignment")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tfi__assignment().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "rlc_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          rlc__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "polling")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          polling().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_valid")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__valid().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketDlAssG1: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.PacketDlAssG1");
  }
}

void PacketDlAssG1::encode_text(Text_Buf& text_buf) const
{
field_tfi__assignment.encode_text(text_buf);
field_rlc__mode.encode_text(text_buf);
field_alpha__present.encode_text(text_buf);
field_alpha.encode_text(text_buf);
field_gamma.encode_text(text_buf);
field_polling.encode_text(text_buf);
field_ta__valid.encode_text(text_buf);
}

void PacketDlAssG1::decode_text(Text_Buf& text_buf)
{
field_tfi__assignment.decode_text(text_buf);
field_rlc__mode.decode_text(text_buf);
field_alpha__present.decode_text(text_buf);
field_alpha.decode_text(text_buf);
field_gamma.decode_text(text_buf);
field_polling.decode_text(text_buf);
field_ta__valid.decode_text(text_buf);
}

void PacketDlAssG1::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void PacketDlAssG1::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int PacketDlAssG1::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, PacketDlAssG1_tfi__assignment_descr_.raw->forceomit);
  decoded_field_length = field_tfi__assignment.RAW_decode(PacketDlAssG1_tfi__assignment_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_1_force_omit(1, force_omit, PacketDlAssG1_rlc__mode_descr_.raw->forceomit);
  decoded_field_length = field_rlc__mode.RAW_decode(PacketDlAssG1_rlc__mode_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_2_force_omit(2, force_omit, PacketDlAssG1_alpha__present_descr_.raw->forceomit);
  decoded_field_length = field_alpha__present.RAW_decode(PacketDlAssG1_alpha__present_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0){
  if (force_omit != NULL && (*force_omit)(3)) {
    field_alpha = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_3_force_omit(3, force_omit, PacketDlAssG1_alpha_descr_.raw->forceomit);
  decoded_field_length = field_alpha().RAW_decode(PacketDlAssG1_alpha_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_3_force_omit);
  if (decoded_field_length < 1) {
  field_alpha = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_alpha=OMIT_VALUE;
  RAW_Force_Omit field_4_force_omit(4, force_omit, PacketDlAssG1_gamma_descr_.raw->forceomit);
  decoded_field_length = field_gamma.RAW_decode(PacketDlAssG1_gamma_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_4_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_5_force_omit(5, force_omit, PacketDlAssG1_polling_descr_.raw->forceomit);
  decoded_field_length = field_polling.RAW_decode(PacketDlAssG1_polling_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_5_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_6_force_omit(6, force_omit, PacketDlAssG1_ta__valid_descr_.raw->forceomit);
  decoded_field_length = field_ta__valid.RAW_decode(PacketDlAssG1_ta__valid_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_6_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int PacketDlAssG1::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 7;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(7);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, PacketDlAssG1_tfi__assignment_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, PacketDlAssG1_rlc__mode_descr_.raw);
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, PacketDlAssG1_alpha__present_descr_.raw);
  if (field_alpha.ispresent()) {
  myleaf.body.node.nodes[3] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 3, PacketDlAssG1_alpha_descr_.raw);
  }
  else myleaf.body.node.nodes[3] = NULL;
  myleaf.body.node.nodes[4] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 4, PacketDlAssG1_gamma_descr_.raw);
  myleaf.body.node.nodes[5] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 5, PacketDlAssG1_polling_descr_.raw);
  myleaf.body.node.nodes[6] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 6, PacketDlAssG1_ta__valid_descr_.raw);
  encoded_length += field_tfi__assignment.RAW_encode(PacketDlAssG1_tfi__assignment_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_rlc__mode.RAW_encode(PacketDlAssG1_rlc__mode_descr_, *myleaf.body.node.nodes[1]);
  encoded_length += field_alpha__present.RAW_encode(PacketDlAssG1_alpha__present_descr_, *myleaf.body.node.nodes[2]);
  if (field_alpha.ispresent()) {
  encoded_length += field_alpha().RAW_encode(PacketDlAssG1_alpha_descr_, *myleaf.body.node.nodes[3]);
  }
  encoded_length += field_gamma.RAW_encode(PacketDlAssG1_gamma_descr_, *myleaf.body.node.nodes[4]);
  encoded_length += field_polling.RAW_encode(PacketDlAssG1_polling_descr_, *myleaf.body.node.nodes[5]);
  encoded_length += field_ta__valid.RAW_encode(PacketDlAssG1_ta__valid_descr_, *myleaf.body.node.nodes[6]);
  return myleaf.length = encoded_length;
}

struct PacketDlAssG1_template::single_value_struct {
INTEGER_template field_tfi__assignment;
BITSTRING_template field_rlc__mode;
BITSTRING_template field_alpha__present;
INTEGER_template field_alpha;
INTEGER_template field_gamma;
BITSTRING_template field_polling;
BITSTRING_template field_ta__valid;
};

void PacketDlAssG1_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_tfi__assignment = ANY_VALUE;
single_value->field_rlc__mode = ANY_VALUE;
single_value->field_alpha__present = ANY_VALUE;
single_value->field_alpha = ANY_OR_OMIT;
single_value->field_gamma = ANY_VALUE;
single_value->field_polling = ANY_VALUE;
single_value->field_ta__valid = ANY_VALUE;
}
}
}

void PacketDlAssG1_template::copy_value(const PacketDlAssG1& other_value)
{
single_value = new single_value_struct;
if (other_value.tfi__assignment().is_bound()) {
  single_value->field_tfi__assignment = other_value.tfi__assignment();
} else {
  single_value->field_tfi__assignment.clean_up();
}
if (other_value.rlc__mode().is_bound()) {
  single_value->field_rlc__mode = other_value.rlc__mode();
} else {
  single_value->field_rlc__mode.clean_up();
}
if (other_value.alpha__present().is_bound()) {
  single_value->field_alpha__present = other_value.alpha__present();
} else {
  single_value->field_alpha__present.clean_up();
}
if (other_value.alpha().is_bound()) {
  if (other_value.alpha().ispresent()) single_value->field_alpha = other_value.alpha()();
  else single_value->field_alpha = OMIT_VALUE;
} else {
  single_value->field_alpha.clean_up();
}
if (other_value.gamma().is_bound()) {
  single_value->field_gamma = other_value.gamma();
} else {
  single_value->field_gamma.clean_up();
}
if (other_value.polling().is_bound()) {
  single_value->field_polling = other_value.polling();
} else {
  single_value->field_polling.clean_up();
}
if (other_value.ta__valid().is_bound()) {
  single_value->field_ta__valid = other_value.ta__valid();
} else {
  single_value->field_ta__valid.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void PacketDlAssG1_template::copy_template(const PacketDlAssG1_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.tfi__assignment().get_selection()) {
single_value->field_tfi__assignment = other_value.tfi__assignment();
} else {
single_value->field_tfi__assignment.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.rlc__mode().get_selection()) {
single_value->field_rlc__mode = other_value.rlc__mode();
} else {
single_value->field_rlc__mode.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.alpha__present().get_selection()) {
single_value->field_alpha__present = other_value.alpha__present();
} else {
single_value->field_alpha__present.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.alpha().get_selection()) {
single_value->field_alpha = other_value.alpha();
} else {
single_value->field_alpha.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.gamma().get_selection()) {
single_value->field_gamma = other_value.gamma();
} else {
single_value->field_gamma.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.polling().get_selection()) {
single_value->field_polling = other_value.polling();
} else {
single_value->field_polling.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ta__valid().get_selection()) {
single_value->field_ta__valid = other_value.ta__valid();
} else {
single_value->field_ta__valid.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new PacketDlAssG1_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new PacketDlAssG1_template(*other_value.implication_.precondition);
implication_.implied_template = new PacketDlAssG1_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.PacketDlAssG1.");
break;
}
set_selection(other_value);
}

PacketDlAssG1_template::PacketDlAssG1_template()
{
}

PacketDlAssG1_template::PacketDlAssG1_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

PacketDlAssG1_template::PacketDlAssG1_template(const PacketDlAssG1& other_value)
{
copy_value(other_value);
}

PacketDlAssG1_template::PacketDlAssG1_template(const OPTIONAL<PacketDlAssG1>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketDlAssG1&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.PacketDlAssG1 from an unbound optional field.");
}
}

PacketDlAssG1_template::PacketDlAssG1_template(PacketDlAssG1_template* p_precondition, PacketDlAssG1_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

PacketDlAssG1_template::PacketDlAssG1_template(Dynamic_Match_Interface<PacketDlAssG1>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<PacketDlAssG1>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

PacketDlAssG1_template::PacketDlAssG1_template(const PacketDlAssG1_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

PacketDlAssG1_template::~PacketDlAssG1_template()
{
clean_up();
}

PacketDlAssG1_template& PacketDlAssG1_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

PacketDlAssG1_template& PacketDlAssG1_template::operator=(const PacketDlAssG1& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

PacketDlAssG1_template& PacketDlAssG1_template::operator=(const OPTIONAL<PacketDlAssG1>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketDlAssG1&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.PacketDlAssG1.");
}
return *this;
}

PacketDlAssG1_template& PacketDlAssG1_template::operator=(const PacketDlAssG1_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean PacketDlAssG1_template::match(const PacketDlAssG1& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.tfi__assignment().is_bound()) return FALSE;
if(!single_value->field_tfi__assignment.match(other_value.tfi__assignment(), legacy))return FALSE;
if(!other_value.rlc__mode().is_bound()) return FALSE;
if(!single_value->field_rlc__mode.match(other_value.rlc__mode(), legacy))return FALSE;
if(!other_value.alpha__present().is_bound()) return FALSE;
if(!single_value->field_alpha__present.match(other_value.alpha__present(), legacy))return FALSE;
if(!other_value.alpha().is_bound()) return FALSE;
if((other_value.alpha().ispresent() ? !single_value->field_alpha.match((const INTEGER&)other_value.alpha(), legacy) : !single_value->field_alpha.match_omit(legacy)))return FALSE;
if(!other_value.gamma().is_bound()) return FALSE;
if(!single_value->field_gamma.match(other_value.gamma(), legacy))return FALSE;
if(!other_value.polling().is_bound()) return FALSE;
if(!single_value->field_polling.match(other_value.polling(), legacy))return FALSE;
if(!other_value.ta__valid().is_bound()) return FALSE;
if(!single_value->field_ta__valid.match(other_value.ta__valid(), legacy))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.PacketDlAssG1.");
}
return FALSE;
}

boolean PacketDlAssG1_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_tfi__assignment.is_bound()
 || single_value->field_rlc__mode.is_bound()
 || single_value->field_alpha__present.is_bound()
 || (single_value->field_alpha.is_omit() || single_value->field_alpha.is_bound())
 || single_value->field_gamma.is_bound()
 || single_value->field_polling.is_bound()
 || single_value->field_ta__valid.is_bound();
}

boolean PacketDlAssG1_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_tfi__assignment.is_value()
 && single_value->field_rlc__mode.is_value()
 && single_value->field_alpha__present.is_value()
 && (single_value->field_alpha.is_omit() || single_value->field_alpha.is_value())
 && single_value->field_gamma.is_value()
 && single_value->field_polling.is_value()
 && single_value->field_ta__valid.is_value();
}

void PacketDlAssG1_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

PacketDlAssG1 PacketDlAssG1_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.PacketDlAssG1.");
PacketDlAssG1 ret_val;
if (single_value->field_tfi__assignment.is_bound()) {
ret_val.tfi__assignment() = single_value->field_tfi__assignment.valueof();
}
if (single_value->field_rlc__mode.is_bound()) {
ret_val.rlc__mode() = single_value->field_rlc__mode.valueof();
}
if (single_value->field_alpha__present.is_bound()) {
ret_val.alpha__present() = single_value->field_alpha__present.valueof();
}
if (single_value->field_alpha.is_omit()) ret_val.alpha() = OMIT_VALUE;
else if (single_value->field_alpha.is_bound()) {
ret_val.alpha() = single_value->field_alpha.valueof();
}
if (single_value->field_gamma.is_bound()) {
ret_val.gamma() = single_value->field_gamma.valueof();
}
if (single_value->field_polling.is_bound()) {
ret_val.polling() = single_value->field_polling.valueof();
}
if (single_value->field_ta__valid.is_bound()) {
ret_val.ta__valid() = single_value->field_ta__valid.valueof();
}
return ret_val;
}

void PacketDlAssG1_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.PacketDlAssG1.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new PacketDlAssG1_template[list_length];
}

PacketDlAssG1_template& PacketDlAssG1_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.PacketDlAssG1.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.PacketDlAssG1.");
return value_list.list_value[list_index];
}

INTEGER_template& PacketDlAssG1_template::tfi__assignment()
{
set_specific();
return single_value->field_tfi__assignment;
}

const INTEGER_template& PacketDlAssG1_template::tfi__assignment() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field tfi_assignment of a non-specific template of type @GSM_RestOctets.PacketDlAssG1.");
return single_value->field_tfi__assignment;
}

BITSTRING_template& PacketDlAssG1_template::rlc__mode()
{
set_specific();
return single_value->field_rlc__mode;
}

const BITSTRING_template& PacketDlAssG1_template::rlc__mode() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field rlc_mode of a non-specific template of type @GSM_RestOctets.PacketDlAssG1.");
return single_value->field_rlc__mode;
}

BITSTRING_template& PacketDlAssG1_template::alpha__present()
{
set_specific();
return single_value->field_alpha__present;
}

const BITSTRING_template& PacketDlAssG1_template::alpha__present() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha_present of a non-specific template of type @GSM_RestOctets.PacketDlAssG1.");
return single_value->field_alpha__present;
}

INTEGER_template& PacketDlAssG1_template::alpha()
{
set_specific();
return single_value->field_alpha;
}

const INTEGER_template& PacketDlAssG1_template::alpha() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field alpha of a non-specific template of type @GSM_RestOctets.PacketDlAssG1.");
return single_value->field_alpha;
}

INTEGER_template& PacketDlAssG1_template::gamma()
{
set_specific();
return single_value->field_gamma;
}

const INTEGER_template& PacketDlAssG1_template::gamma() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field gamma of a non-specific template of type @GSM_RestOctets.PacketDlAssG1.");
return single_value->field_gamma;
}

BITSTRING_template& PacketDlAssG1_template::polling()
{
set_specific();
return single_value->field_polling;
}

const BITSTRING_template& PacketDlAssG1_template::polling() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field polling of a non-specific template of type @GSM_RestOctets.PacketDlAssG1.");
return single_value->field_polling;
}

BITSTRING_template& PacketDlAssG1_template::ta__valid()
{
set_specific();
return single_value->field_ta__valid;
}

const BITSTRING_template& PacketDlAssG1_template::ta__valid() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ta_valid of a non-specific template of type @GSM_RestOctets.PacketDlAssG1.");
return single_value->field_ta__valid;
}

int PacketDlAssG1_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssG1 which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 6;
      if (single_value->field_alpha.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssG1 containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssG1 containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssG1 containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssG1 containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssG1 containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssG1 containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssG1 containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketDlAssG1 containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.PacketDlAssG1.");
  }
  return 0;
}

void PacketDlAssG1_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ tfi_assignment := ");
single_value->field_tfi__assignment.log();
TTCN_Logger::log_event_str(", rlc_mode := ");
single_value->field_rlc__mode.log();
TTCN_Logger::log_event_str(", alpha_present := ");
single_value->field_alpha__present.log();
TTCN_Logger::log_event_str(", alpha := ");
single_value->field_alpha.log();
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log();
TTCN_Logger::log_event_str(", polling := ");
single_value->field_polling.log();
TTCN_Logger::log_event_str(", ta_valid := ");
single_value->field_ta__valid.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void PacketDlAssG1_template::log_match(const PacketDlAssG1& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_tfi__assignment.match(match_value.tfi__assignment(), legacy)){
TTCN_Logger::log_logmatch_info(".tfi_assignment");
single_value->field_tfi__assignment.log_match(match_value.tfi__assignment(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_rlc__mode.match(match_value.rlc__mode(), legacy)){
TTCN_Logger::log_logmatch_info(".rlc_mode");
single_value->field_rlc__mode.log_match(match_value.rlc__mode(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_alpha__present.match(match_value.alpha__present(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha_present");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.alpha().ispresent()){
if(!single_value->field_alpha.match(match_value.alpha(), legacy)){
TTCN_Logger::log_logmatch_info(".alpha");
single_value->field_alpha.log_match(match_value.alpha(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_alpha.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".alpha := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_alpha.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
if(!single_value->field_gamma.match(match_value.gamma(), legacy)){
TTCN_Logger::log_logmatch_info(".gamma");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_polling.match(match_value.polling(), legacy)){
TTCN_Logger::log_logmatch_info(".polling");
single_value->field_polling.log_match(match_value.polling(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_ta__valid.match(match_value.ta__valid(), legacy)){
TTCN_Logger::log_logmatch_info(".ta_valid");
single_value->field_ta__valid.log_match(match_value.ta__valid(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ tfi_assignment := ");
single_value->field_tfi__assignment.log_match(match_value.tfi__assignment(), legacy);
TTCN_Logger::log_event_str(", rlc_mode := ");
single_value->field_rlc__mode.log_match(match_value.rlc__mode(), legacy);
TTCN_Logger::log_event_str(", alpha_present := ");
single_value->field_alpha__present.log_match(match_value.alpha__present(), legacy);
TTCN_Logger::log_event_str(", alpha := ");
if (match_value.alpha().ispresent()) {
single_value->field_alpha.log_match(match_value.alpha(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_alpha.log();
if (single_value->field_alpha.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(", gamma := ");
single_value->field_gamma.log_match(match_value.gamma(), legacy);
TTCN_Logger::log_event_str(", polling := ");
single_value->field_polling.log_match(match_value.polling(), legacy);
TTCN_Logger::log_event_str(", ta_valid := ");
single_value->field_ta__valid.log_match(match_value.ta__valid(), legacy);
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void PacketDlAssG1_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (tfi__assignment().is_bound()) tfi__assignment().set_implicit_omit();
if (rlc__mode().is_bound()) rlc__mode().set_implicit_omit();
if (alpha__present().is_bound()) alpha__present().set_implicit_omit();
if (!alpha().is_bound()) alpha() = OMIT_VALUE;
else alpha().set_implicit_omit();
if (gamma().is_bound()) gamma().set_implicit_omit();
if (polling().is_bound()) polling().set_implicit_omit();
if (ta__valid().is_bound()) ta__valid().set_implicit_omit();
}

void PacketDlAssG1_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_tfi__assignment.encode_text(text_buf);
single_value->field_rlc__mode.encode_text(text_buf);
single_value->field_alpha__present.encode_text(text_buf);
single_value->field_alpha.encode_text(text_buf);
single_value->field_gamma.encode_text(text_buf);
single_value->field_polling.encode_text(text_buf);
single_value->field_ta__valid.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.PacketDlAssG1.");
}
}

void PacketDlAssG1_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_tfi__assignment.decode_text(text_buf);
single_value->field_rlc__mode.decode_text(text_buf);
single_value->field_alpha__present.decode_text(text_buf);
single_value->field_alpha.decode_text(text_buf);
single_value->field_gamma.decode_text(text_buf);
single_value->field_polling.decode_text(text_buf);
single_value->field_ta__valid.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new PacketDlAssG1_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.PacketDlAssG1.");
}
}

void PacketDlAssG1_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    PacketDlAssG1_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (7<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.PacketDlAssG1 has 7 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) tfi__assignment().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) rlc__mode().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) alpha__present().set_param(*param.get_elem(2));
    if (param.get_size()>3 && param.get_elem(3)->get_type()!=Module_Param::MP_NotUsed) alpha().set_param(*param.get_elem(3));
    if (param.get_size()>4 && param.get_elem(4)->get_type()!=Module_Param::MP_NotUsed) gamma().set_param(*param.get_elem(4));
    if (param.get_size()>5 && param.get_elem(5)->get_type()!=Module_Param::MP_NotUsed) polling().set_param(*param.get_elem(5));
    if (param.get_size()>6 && param.get_elem(6)->get_type()!=Module_Param::MP_NotUsed) ta__valid().set_param(*param.get_elem(6));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "tfi_assignment")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          tfi__assignment().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "rlc_mode")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          rlc__mode().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha_present")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha__present().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "alpha")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          alpha().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "gamma")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          gamma().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "polling")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          polling().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ta_valid")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ta__valid().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketDlAssG1: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    PacketDlAssG1_template* precondition = new PacketDlAssG1_template;
    precondition->set_param(*param.get_elem(0));
    PacketDlAssG1_template* implied_template = new PacketDlAssG1_template;
    implied_template->set_param(*param.get_elem(1));
    *this = PacketDlAssG1_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.PacketDlAssG1");
  }
  is_ifpresent = param.get_ifpresent();
}

void PacketDlAssG1_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_tfi__assignment.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssG1");
single_value->field_rlc__mode.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssG1");
single_value->field_alpha__present.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssG1");
single_value->field_alpha.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssG1");
single_value->field_gamma.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssG1");
single_value->field_polling.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssG1");
single_value->field_ta__valid.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketDlAssG1");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.PacketDlAssG1");
}

boolean PacketDlAssG1_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean PacketDlAssG1_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

PacketUlDlAssign::PacketUlDlAssign()
{
}

PacketUlDlAssign::PacketUlDlAssign(const BITSTRING& par_ass__disc,
    const PacketUlDlAssignUnion& par_ass)
  :   field_ass__disc(par_ass__disc),
  field_ass(par_ass)
{
}

PacketUlDlAssign::PacketUlDlAssign(const PacketUlDlAssign& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.PacketUlDlAssign.");
if (other_value.ass__disc().is_bound()) field_ass__disc = other_value.ass__disc();
else field_ass__disc.clean_up();
if (other_value.ass().is_bound()) field_ass = other_value.ass();
else field_ass.clean_up();
}

void PacketUlDlAssign::clean_up()
{
field_ass__disc.clean_up();
field_ass.clean_up();
}

const TTCN_Typedescriptor_t* PacketUlDlAssign::get_descriptor() const { return &PacketUlDlAssign_descr_; }
PacketUlDlAssign& PacketUlDlAssign::operator=(const PacketUlDlAssign& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.PacketUlDlAssign.");
  if (other_value.ass__disc().is_bound()) field_ass__disc = other_value.ass__disc();
  else field_ass__disc.clean_up();
  if (other_value.ass().is_bound()) field_ass = other_value.ass();
  else field_ass.clean_up();
}
return *this;
}

boolean PacketUlDlAssign::operator==(const PacketUlDlAssign& other_value) const
{
return field_ass__disc==other_value.field_ass__disc
  && field_ass==other_value.field_ass;
}

boolean PacketUlDlAssign::is_bound() const
{
return (field_ass__disc.is_bound())
  || (field_ass.is_bound());
}
boolean PacketUlDlAssign::is_value() const
{
return field_ass__disc.is_value()
  && field_ass.is_value();
}
void PacketUlDlAssign::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ ass_disc := ");
field_ass__disc.log();
TTCN_Logger::log_event_str(", ass := ");
field_ass.log();
TTCN_Logger::log_event_str(" }");
}

void PacketUlDlAssign::set_implicit_omit()
{
if (ass__disc().is_bound()) ass__disc().set_implicit_omit();
if (ass().is_bound()) ass().set_implicit_omit();
}

void PacketUlDlAssign::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.PacketUlDlAssign has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) ass__disc().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) ass().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ass_disc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ass__disc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ass")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ass().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketUlDlAssign: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.PacketUlDlAssign");
  }
}

void PacketUlDlAssign::encode_text(Text_Buf& text_buf) const
{
field_ass__disc.encode_text(text_buf);
field_ass.encode_text(text_buf);
}

void PacketUlDlAssign::decode_text(Text_Buf& text_buf)
{
field_ass__disc.decode_text(text_buf);
field_ass.decode_text(text_buf);
}

void PacketUlDlAssign::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void PacketUlDlAssign::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int PacketUlDlAssign::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  int selected_field = -1;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, PacketUlDlAssign_ass__disc_descr_.raw->forceomit);
  decoded_field_length = field_ass__disc.RAW_decode(PacketUlDlAssign_ass__disc_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (field_ass__disc ==  bs_0) selected_field = 1;
  else if (field_ass__disc ==  bs_1) selected_field = 0;
  else selected_field = -1;
  RAW_Force_Omit field_1_force_omit(1, force_omit, PacketUlDlAssign_ass_descr_.raw->forceomit);
  decoded_field_length = field_ass.RAW_decode(PacketUlDlAssign_ass_descr_, p_buf, limit, local_top_order, no_err, selected_field, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int PacketUlDlAssign::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 2;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(2);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, PacketUlDlAssign_ass__disc_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, PacketUlDlAssign_ass_descr_.raw);
  encoded_length += field_ass__disc.RAW_encode(PacketUlDlAssign_ass__disc_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_ass.RAW_encode(PacketUlDlAssign_ass_descr_, *myleaf.body.node.nodes[1]);
  switch (field_ass.get_selection()) {
  case PacketUlDlAssignUnion::ALT_dl:
  if (field_ass__disc !=  bs_0) {
  RAW_enc_tr_pos pr_pos;
  pr_pos.level = myleaf.curr_pos.level + 1;
  int new_pos[] = { 0 };
  pr_pos.pos = init_new_tree_pos(myleaf.curr_pos, 1, new_pos);
  RAW_enc_tree* temp_leaf = myleaf.get_node(pr_pos);
  if (temp_leaf != NULL)
     bs_0.RAW_encode(PacketUlDlAssign_ass__disc_descr_,*temp_leaf);
  else
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  free_tree_pos(pr_pos.pos);
  }
  break;
  case PacketUlDlAssignUnion::ALT_ul:
  if (field_ass__disc !=  bs_1) {
  RAW_enc_tr_pos pr_pos;
  pr_pos.level = myleaf.curr_pos.level + 1;
  int new_pos[] = { 0 };
  pr_pos.pos = init_new_tree_pos(myleaf.curr_pos, 1, new_pos);
  RAW_enc_tree* temp_leaf = myleaf.get_node(pr_pos);
  if (temp_leaf != NULL)
     bs_1.RAW_encode(PacketUlDlAssign_ass__disc_descr_,*temp_leaf);
  else
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  free_tree_pos(pr_pos.pos);
  }
  break;
  default:;
  }
  return myleaf.length = encoded_length;
}

struct PacketUlDlAssign_template::single_value_struct {
BITSTRING_template field_ass__disc;
PacketUlDlAssignUnion_template field_ass;
};

void PacketUlDlAssign_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_ass__disc = ANY_VALUE;
single_value->field_ass = ANY_VALUE;
}
}
}

void PacketUlDlAssign_template::copy_value(const PacketUlDlAssign& other_value)
{
single_value = new single_value_struct;
if (other_value.ass__disc().is_bound()) {
  single_value->field_ass__disc = other_value.ass__disc();
} else {
  single_value->field_ass__disc.clean_up();
}
if (other_value.ass().is_bound()) {
  single_value->field_ass = other_value.ass();
} else {
  single_value->field_ass.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void PacketUlDlAssign_template::copy_template(const PacketUlDlAssign_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.ass__disc().get_selection()) {
single_value->field_ass__disc = other_value.ass__disc();
} else {
single_value->field_ass__disc.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ass().get_selection()) {
single_value->field_ass = other_value.ass();
} else {
single_value->field_ass.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new PacketUlDlAssign_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new PacketUlDlAssign_template(*other_value.implication_.precondition);
implication_.implied_template = new PacketUlDlAssign_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlDlAssign.");
break;
}
set_selection(other_value);
}

PacketUlDlAssign_template::PacketUlDlAssign_template()
{
}

PacketUlDlAssign_template::PacketUlDlAssign_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

PacketUlDlAssign_template::PacketUlDlAssign_template(const PacketUlDlAssign& other_value)
{
copy_value(other_value);
}

PacketUlDlAssign_template::PacketUlDlAssign_template(const OPTIONAL<PacketUlDlAssign>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlDlAssign&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.PacketUlDlAssign from an unbound optional field.");
}
}

PacketUlDlAssign_template::PacketUlDlAssign_template(PacketUlDlAssign_template* p_precondition, PacketUlDlAssign_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

PacketUlDlAssign_template::PacketUlDlAssign_template(Dynamic_Match_Interface<PacketUlDlAssign>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<PacketUlDlAssign>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

PacketUlDlAssign_template::PacketUlDlAssign_template(const PacketUlDlAssign_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

PacketUlDlAssign_template::~PacketUlDlAssign_template()
{
clean_up();
}

PacketUlDlAssign_template& PacketUlDlAssign_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

PacketUlDlAssign_template& PacketUlDlAssign_template::operator=(const PacketUlDlAssign& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

PacketUlDlAssign_template& PacketUlDlAssign_template::operator=(const OPTIONAL<PacketUlDlAssign>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const PacketUlDlAssign&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.PacketUlDlAssign.");
}
return *this;
}

PacketUlDlAssign_template& PacketUlDlAssign_template::operator=(const PacketUlDlAssign_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean PacketUlDlAssign_template::match(const PacketUlDlAssign& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.ass__disc().is_bound()) return FALSE;
if(!single_value->field_ass__disc.match(other_value.ass__disc(), legacy))return FALSE;
if(!other_value.ass().is_bound()) return FALSE;
if(!single_value->field_ass.match(other_value.ass(), legacy))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlDlAssign.");
}
return FALSE;
}

boolean PacketUlDlAssign_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_ass__disc.is_bound()
 || single_value->field_ass.is_bound();
}

boolean PacketUlDlAssign_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_ass__disc.is_value()
 && single_value->field_ass.is_value();
}

void PacketUlDlAssign_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

PacketUlDlAssign PacketUlDlAssign_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.PacketUlDlAssign.");
PacketUlDlAssign ret_val;
if (single_value->field_ass__disc.is_bound()) {
ret_val.ass__disc() = single_value->field_ass__disc.valueof();
}
if (single_value->field_ass.is_bound()) {
ret_val.ass() = single_value->field_ass.valueof();
}
return ret_val;
}

void PacketUlDlAssign_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.PacketUlDlAssign.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new PacketUlDlAssign_template[list_length];
}

PacketUlDlAssign_template& PacketUlDlAssign_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.PacketUlDlAssign.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.PacketUlDlAssign.");
return value_list.list_value[list_index];
}

BITSTRING_template& PacketUlDlAssign_template::ass__disc()
{
set_specific();
return single_value->field_ass__disc;
}

const BITSTRING_template& PacketUlDlAssign_template::ass__disc() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ass_disc of a non-specific template of type @GSM_RestOctets.PacketUlDlAssign.");
return single_value->field_ass__disc;
}

PacketUlDlAssignUnion_template& PacketUlDlAssign_template::ass()
{
set_specific();
return single_value->field_ass;
}

const PacketUlDlAssignUnion_template& PacketUlDlAssign_template::ass() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ass of a non-specific template of type @GSM_RestOctets.PacketUlDlAssign.");
return single_value->field_ass;
}

int PacketUlDlAssign_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlDlAssign which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
    return 2;
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlDlAssign containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlDlAssign containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlDlAssign containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlDlAssign containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlDlAssign containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlDlAssign containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlDlAssign containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.PacketUlDlAssign containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlDlAssign.");
  }
  return 0;
}

void PacketUlDlAssign_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ ass_disc := ");
single_value->field_ass__disc.log();
TTCN_Logger::log_event_str(", ass := ");
single_value->field_ass.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void PacketUlDlAssign_template::log_match(const PacketUlDlAssign& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_ass__disc.match(match_value.ass__disc(), legacy)){
TTCN_Logger::log_logmatch_info(".ass_disc");
single_value->field_ass__disc.log_match(match_value.ass__disc(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_ass.match(match_value.ass(), legacy)){
TTCN_Logger::log_logmatch_info(".ass");
single_value->field_ass.log_match(match_value.ass(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ ass_disc := ");
single_value->field_ass__disc.log_match(match_value.ass__disc(), legacy);
TTCN_Logger::log_event_str(", ass := ");
single_value->field_ass.log_match(match_value.ass(), legacy);
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void PacketUlDlAssign_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (ass__disc().is_bound()) ass__disc().set_implicit_omit();
if (ass().is_bound()) ass().set_implicit_omit();
}

void PacketUlDlAssign_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_ass__disc.encode_text(text_buf);
single_value->field_ass.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.PacketUlDlAssign.");
}
}

void PacketUlDlAssign_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_ass__disc.decode_text(text_buf);
single_value->field_ass.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new PacketUlDlAssign_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.PacketUlDlAssign.");
}
}

void PacketUlDlAssign_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    PacketUlDlAssign_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.PacketUlDlAssign has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) ass__disc().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) ass().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ass_disc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ass__disc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ass")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ass().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.PacketUlDlAssign: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    PacketUlDlAssign_template* precondition = new PacketUlDlAssign_template;
    precondition->set_param(*param.get_elem(0));
    PacketUlDlAssign_template* implied_template = new PacketUlDlAssign_template;
    implied_template->set_param(*param.get_elem(1));
    *this = PacketUlDlAssign_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.PacketUlDlAssign");
  }
  is_ifpresent = param.get_ifpresent();
}

void PacketUlDlAssign_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_ass__disc.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlDlAssign");
single_value->field_ass.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.PacketUlDlAssign");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.PacketUlDlAssign");
}

boolean PacketUlDlAssign_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean PacketUlDlAssign_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

IaRestOctHH::IaRestOctHH()
{
}

IaRestOctHH::IaRestOctHH(const BITSTRING& par_pa__disc,
    const PacketAssignUnion& par_pa)
  :   field_pa__disc(par_pa__disc),
  field_pa(par_pa)
{
}

IaRestOctHH::IaRestOctHH(const IaRestOctHH& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.IaRestOctHH.");
if (other_value.pa__disc().is_bound()) field_pa__disc = other_value.pa__disc();
else field_pa__disc.clean_up();
if (other_value.pa().is_bound()) field_pa = other_value.pa();
else field_pa.clean_up();
}

void IaRestOctHH::clean_up()
{
field_pa__disc.clean_up();
field_pa.clean_up();
}

const TTCN_Typedescriptor_t* IaRestOctHH::get_descriptor() const { return &IaRestOctHH_descr_; }
IaRestOctHH& IaRestOctHH::operator=(const IaRestOctHH& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.IaRestOctHH.");
  if (other_value.pa__disc().is_bound()) field_pa__disc = other_value.pa__disc();
  else field_pa__disc.clean_up();
  if (other_value.pa().is_bound()) field_pa = other_value.pa();
  else field_pa.clean_up();
}
return *this;
}

boolean IaRestOctHH::operator==(const IaRestOctHH& other_value) const
{
return field_pa__disc==other_value.field_pa__disc
  && field_pa==other_value.field_pa;
}

boolean IaRestOctHH::is_bound() const
{
return (field_pa__disc.is_bound())
  || (field_pa.is_bound());
}
boolean IaRestOctHH::is_value() const
{
return field_pa__disc.is_value()
  && field_pa.is_value();
}
void IaRestOctHH::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ pa_disc := ");
field_pa__disc.log();
TTCN_Logger::log_event_str(", pa := ");
field_pa.log();
TTCN_Logger::log_event_str(" }");
}

void IaRestOctHH::set_implicit_omit()
{
if (pa__disc().is_bound()) pa__disc().set_implicit_omit();
if (pa().is_bound()) pa().set_implicit_omit();
}

void IaRestOctHH::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.IaRestOctHH has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) pa__disc().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) pa().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pa_disc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pa__disc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pa")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pa().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctHH: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.IaRestOctHH");
  }
}

void IaRestOctHH::encode_text(Text_Buf& text_buf) const
{
field_pa__disc.encode_text(text_buf);
field_pa.encode_text(text_buf);
}

void IaRestOctHH::decode_text(Text_Buf& text_buf)
{
field_pa__disc.decode_text(text_buf);
field_pa.decode_text(text_buf);
}

void IaRestOctHH::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void IaRestOctHH::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int IaRestOctHH::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  int selected_field = -1;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, IaRestOctHH_pa__disc_descr_.raw->forceomit);
  decoded_field_length = field_pa__disc.RAW_decode(IaRestOctHH_pa__disc_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (field_pa__disc ==  bs_0) selected_field = 0;
  else if (field_pa__disc ==  bs_1) selected_field = 1;
  else selected_field = -1;
  RAW_Force_Omit field_1_force_omit(1, force_omit, IaRestOctHH_pa_descr_.raw->forceomit);
  decoded_field_length = field_pa.RAW_decode(IaRestOctHH_pa_descr_, p_buf, limit, local_top_order, no_err, selected_field, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int IaRestOctHH::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 2;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(2);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, IaRestOctHH_pa__disc_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, IaRestOctHH_pa_descr_.raw);
  encoded_length += field_pa__disc.RAW_encode(IaRestOctHH_pa__disc_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_pa.RAW_encode(IaRestOctHH_pa_descr_, *myleaf.body.node.nodes[1]);
  switch (field_pa.get_selection()) {
  case PacketAssignUnion::ALT_spa:
  if (field_pa__disc !=  bs_0) {
  RAW_enc_tr_pos pr_pos;
  pr_pos.level = myleaf.curr_pos.level + 1;
  int new_pos[] = { 0 };
  pr_pos.pos = init_new_tree_pos(myleaf.curr_pos, 1, new_pos);
  RAW_enc_tree* temp_leaf = myleaf.get_node(pr_pos);
  if (temp_leaf != NULL)
     bs_0.RAW_encode(IaRestOctHH_pa__disc_descr_,*temp_leaf);
  else
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  free_tree_pos(pr_pos.pos);
  }
  break;
  case PacketAssignUnion::ALT_uldl:
  if (field_pa__disc !=  bs_1) {
  RAW_enc_tr_pos pr_pos;
  pr_pos.level = myleaf.curr_pos.level + 1;
  int new_pos[] = { 0 };
  pr_pos.pos = init_new_tree_pos(myleaf.curr_pos, 1, new_pos);
  RAW_enc_tree* temp_leaf = myleaf.get_node(pr_pos);
  if (temp_leaf != NULL)
     bs_1.RAW_encode(IaRestOctHH_pa__disc_descr_,*temp_leaf);
  else
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  free_tree_pos(pr_pos.pos);
  }
  break;
  default:;
  }
  return myleaf.length = encoded_length;
}

struct IaRestOctHH_template::single_value_struct {
BITSTRING_template field_pa__disc;
PacketAssignUnion_template field_pa;
};

void IaRestOctHH_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_pa__disc = ANY_VALUE;
single_value->field_pa = ANY_VALUE;
}
}
}

void IaRestOctHH_template::copy_value(const IaRestOctHH& other_value)
{
single_value = new single_value_struct;
if (other_value.pa__disc().is_bound()) {
  single_value->field_pa__disc = other_value.pa__disc();
} else {
  single_value->field_pa__disc.clean_up();
}
if (other_value.pa().is_bound()) {
  single_value->field_pa = other_value.pa();
} else {
  single_value->field_pa.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void IaRestOctHH_template::copy_template(const IaRestOctHH_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.pa__disc().get_selection()) {
single_value->field_pa__disc = other_value.pa__disc();
} else {
single_value->field_pa__disc.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.pa().get_selection()) {
single_value->field_pa = other_value.pa();
} else {
single_value->field_pa.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new IaRestOctHH_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new IaRestOctHH_template(*other_value.implication_.precondition);
implication_.implied_template = new IaRestOctHH_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctHH.");
break;
}
set_selection(other_value);
}

IaRestOctHH_template::IaRestOctHH_template()
{
}

IaRestOctHH_template::IaRestOctHH_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

IaRestOctHH_template::IaRestOctHH_template(const IaRestOctHH& other_value)
{
copy_value(other_value);
}

IaRestOctHH_template::IaRestOctHH_template(const OPTIONAL<IaRestOctHH>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctHH&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.IaRestOctHH from an unbound optional field.");
}
}

IaRestOctHH_template::IaRestOctHH_template(IaRestOctHH_template* p_precondition, IaRestOctHH_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

IaRestOctHH_template::IaRestOctHH_template(Dynamic_Match_Interface<IaRestOctHH>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<IaRestOctHH>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

IaRestOctHH_template::IaRestOctHH_template(const IaRestOctHH_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

IaRestOctHH_template::~IaRestOctHH_template()
{
clean_up();
}

IaRestOctHH_template& IaRestOctHH_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

IaRestOctHH_template& IaRestOctHH_template::operator=(const IaRestOctHH& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

IaRestOctHH_template& IaRestOctHH_template::operator=(const OPTIONAL<IaRestOctHH>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IaRestOctHH&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.IaRestOctHH.");
}
return *this;
}

IaRestOctHH_template& IaRestOctHH_template::operator=(const IaRestOctHH_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean IaRestOctHH_template::match(const IaRestOctHH& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.pa__disc().is_bound()) return FALSE;
if(!single_value->field_pa__disc.match(other_value.pa__disc(), legacy))return FALSE;
if(!other_value.pa().is_bound()) return FALSE;
if(!single_value->field_pa.match(other_value.pa(), legacy))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctHH.");
}
return FALSE;
}

boolean IaRestOctHH_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_pa__disc.is_bound()
 || single_value->field_pa.is_bound();
}

boolean IaRestOctHH_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_pa__disc.is_value()
 && single_value->field_pa.is_value();
}

void IaRestOctHH_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

IaRestOctHH IaRestOctHH_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.IaRestOctHH.");
IaRestOctHH ret_val;
if (single_value->field_pa__disc.is_bound()) {
ret_val.pa__disc() = single_value->field_pa__disc.valueof();
}
if (single_value->field_pa.is_bound()) {
ret_val.pa() = single_value->field_pa.valueof();
}
return ret_val;
}

void IaRestOctHH_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.IaRestOctHH.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new IaRestOctHH_template[list_length];
}

IaRestOctHH_template& IaRestOctHH_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.IaRestOctHH.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.IaRestOctHH.");
return value_list.list_value[list_index];
}

BITSTRING_template& IaRestOctHH_template::pa__disc()
{
set_specific();
return single_value->field_pa__disc;
}

const BITSTRING_template& IaRestOctHH_template::pa__disc() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field pa_disc of a non-specific template of type @GSM_RestOctets.IaRestOctHH.");
return single_value->field_pa__disc;
}

PacketAssignUnion_template& IaRestOctHH_template::pa()
{
set_specific();
return single_value->field_pa;
}

const PacketAssignUnion_template& IaRestOctHH_template::pa() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field pa of a non-specific template of type @GSM_RestOctets.IaRestOctHH.");
return single_value->field_pa;
}

int IaRestOctHH_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHH which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
    return 2;
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHH containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHH containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHH containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHH containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHH containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHH containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHH containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IaRestOctHH containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctHH.");
  }
  return 0;
}

void IaRestOctHH_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ pa_disc := ");
single_value->field_pa__disc.log();
TTCN_Logger::log_event_str(", pa := ");
single_value->field_pa.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void IaRestOctHH_template::log_match(const IaRestOctHH& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_pa__disc.match(match_value.pa__disc(), legacy)){
TTCN_Logger::log_logmatch_info(".pa_disc");
single_value->field_pa__disc.log_match(match_value.pa__disc(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_pa.match(match_value.pa(), legacy)){
TTCN_Logger::log_logmatch_info(".pa");
single_value->field_pa.log_match(match_value.pa(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ pa_disc := ");
single_value->field_pa__disc.log_match(match_value.pa__disc(), legacy);
TTCN_Logger::log_event_str(", pa := ");
single_value->field_pa.log_match(match_value.pa(), legacy);
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void IaRestOctHH_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (pa__disc().is_bound()) pa__disc().set_implicit_omit();
if (pa().is_bound()) pa().set_implicit_omit();
}

void IaRestOctHH_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_pa__disc.encode_text(text_buf);
single_value->field_pa.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.IaRestOctHH.");
}
}

void IaRestOctHH_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_pa__disc.decode_text(text_buf);
single_value->field_pa.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new IaRestOctHH_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.IaRestOctHH.");
}
}

void IaRestOctHH_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    IaRestOctHH_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.IaRestOctHH has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) pa__disc().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) pa().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pa_disc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pa__disc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "pa")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          pa().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IaRestOctHH: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    IaRestOctHH_template* precondition = new IaRestOctHH_template;
    precondition->set_param(*param.get_elem(0));
    IaRestOctHH_template* implied_template = new IaRestOctHH_template;
    implied_template->set_param(*param.get_elem(1));
    *this = IaRestOctHH_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.IaRestOctHH");
  }
  is_ifpresent = param.get_ifpresent();
}

void IaRestOctHH_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_pa__disc.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctHH");
single_value->field_pa.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IaRestOctHH");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.IaRestOctHH");
}

boolean IaRestOctHH_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean IaRestOctHH_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}


const ExtRAOpt ExtRAList::UNBOUND_ELEM;
ExtRAList::ExtRAList()
{
val_ptr = NULL;
}

ExtRAList::ExtRAList(null_type)
{
val_ptr = new recordof_setof_struct;
val_ptr->ref_count = 1;
val_ptr->n_elements = 0;
val_ptr->value_elements = NULL;
}

ExtRAList::ExtRAList(const ExtRAList& other_value)
{
if (!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.ExtRAList.");
val_ptr = other_value.val_ptr;
val_ptr->ref_count++;
}

ExtRAList::~ExtRAList()
{
clean_up();
if (val_ptr != NULL) val_ptr = NULL;
}

void ExtRAList::clean_up()
{
if (val_ptr != NULL) {
if (val_ptr->ref_count > 1) {
val_ptr->ref_count--;
val_ptr = NULL;
}
else if (val_ptr->ref_count == 1) {
for (int elem_count = 0; elem_count < val_ptr->n_elements;
elem_count++)
if (val_ptr->value_elements[elem_count] != NULL)
delete val_ptr->value_elements[elem_count];
free_pointers((void**)val_ptr->value_elements);
delete val_ptr;
val_ptr = NULL;
}
else
TTCN_error("Internal error: Invalid reference counter in a record of/set of value.");
}
}

ExtRAList& ExtRAList::operator=(null_type)
{
clean_up();
val_ptr = new recordof_setof_struct;
val_ptr->ref_count = 1;
val_ptr->n_elements = 0;
val_ptr->value_elements = NULL;
return *this;
}

ExtRAList& ExtRAList::operator=(const ExtRAList& other_value)
{
if (other_value.val_ptr == NULL) TTCN_error("Assigning an unbound value of type @GSM_RestOctets.ExtRAList.");
if (this != &other_value) {
clean_up();
val_ptr = other_value.val_ptr;
val_ptr->ref_count++;
}
return *this;
}

boolean ExtRAList::operator==(null_type) const
{
if (val_ptr == NULL)
TTCN_error("The left operand of comparison is an unbound value of type @GSM_RestOctets.ExtRAList.");
return val_ptr->n_elements == 0 ;
}

boolean ExtRAList::operator==(const ExtRAList& other_value) const
{
if (val_ptr == NULL) TTCN_error("The left operand of comparison is an unbound value of type @GSM_RestOctets.ExtRAList.");
if (other_value.val_ptr == NULL) TTCN_error("The right operand of comparison is an unbound value of type @GSM_RestOctets.ExtRAList.");
if (val_ptr == other_value.val_ptr) return TRUE;
if (val_ptr->n_elements != (other_value.val_ptr)->n_elements)
return FALSE;
for (int elem_count = 0; elem_count < val_ptr->n_elements; elem_count++){
if (val_ptr->value_elements[elem_count] != NULL){
if ((other_value.val_ptr)->value_elements[elem_count] != NULL){
  if (*val_ptr->value_elements[elem_count] != *(other_value.val_ptr)->value_elements[elem_count]) return FALSE;
} else return FALSE;
} else {
if ((other_value.val_ptr)->value_elements[elem_count] != NULL) return FALSE;
}
}
return TRUE;
}

ExtRAOpt& ExtRAList::operator[](int index_value)
{
if (index_value < 0) TTCN_error("Accessing an element of type @GSM_RestOctets.ExtRAList using a negative index: %d.", index_value);
if (val_ptr == NULL) {
val_ptr = new recordof_setof_struct;
val_ptr->ref_count = 1;
val_ptr->n_elements = 0;
val_ptr->value_elements = NULL;
} else if (val_ptr->ref_count > 1) {
struct recordof_setof_struct *new_val_ptr = new recordof_setof_struct;
new_val_ptr->ref_count = 1;
new_val_ptr->n_elements = (index_value >= val_ptr->n_elements) ? index_value + 1 : val_ptr->n_elements;
new_val_ptr->value_elements = (ExtRAOpt**)allocate_pointers(new_val_ptr->n_elements);
for (int elem_count = 0; elem_count < val_ptr->n_elements; elem_count++){
if (val_ptr->value_elements[elem_count] != NULL){
new_val_ptr->value_elements[elem_count] = new ExtRAOpt(*(val_ptr->value_elements[elem_count]));
}
}
clean_up();
val_ptr = new_val_ptr;
}
if (index_value >= val_ptr->n_elements) set_size(index_value + 1);
if (val_ptr->value_elements[index_value] == NULL) {
val_ptr->value_elements[index_value] = new ExtRAOpt;
}
return *val_ptr->value_elements[index_value];
}

ExtRAOpt& ExtRAList::operator[](const INTEGER& index_value)
{
index_value.must_bound("Using an unbound integer value for indexing a value of type @GSM_RestOctets.ExtRAList.");
return (*this)[(int)index_value];
}

const ExtRAOpt& ExtRAList::operator[](int index_value) const
{
if (val_ptr == NULL)
TTCN_error("Accessing an element in an unbound value of type @GSM_RestOctets.ExtRAList.");
if (index_value < 0) TTCN_error("Accessing an element of type @GSM_RestOctets.ExtRAList using a negative index: %d.", index_value);
if (index_value >= val_ptr->n_elements) TTCN_error("Index overflow in a value of type @GSM_RestOctets.ExtRAList: The index is %d, but the value has only %d elements.", index_value, val_ptr->n_elements);
return (val_ptr->value_elements[index_value] == NULL) ?
UNBOUND_ELEM : *val_ptr->value_elements[index_value];
}

const ExtRAOpt& ExtRAList::operator[](const INTEGER& index_value) const
{
index_value.must_bound("Using an unbound integer value for indexing a value of type @GSM_RestOctets.ExtRAList.");
return (*this)[(int)index_value];
}

ExtRAList ExtRAList::operator<<=(int rotate_count) const
{
return *this >>= (-rotate_count);
}

ExtRAList ExtRAList::operator<<=(const INTEGER& rotate_count) const
{
rotate_count.must_bound("Unbound integer operand of rotate left operator.");
return *this >>= (int)(-rotate_count);
}

ExtRAList ExtRAList::operator>>=(const INTEGER& rotate_count) const
{
rotate_count.must_bound("Unbound integer operand of rotate right operator.");
return *this >>= (int)rotate_count;
}

ExtRAList ExtRAList::operator>>=(int rotate_count) const
{
if (val_ptr == NULL) TTCN_error("Performing rotation operation on an unbound value of type @GSM_RestOctets.ExtRAList.");
if (val_ptr->n_elements == 0) return *this;
int rc;
if (rotate_count>=0) rc = rotate_count % val_ptr->n_elements;
else rc = val_ptr->n_elements - ((-rotate_count) % val_ptr->n_elements);
if (rc == 0) return *this;
ExtRAList ret_val;
ret_val.set_size(val_ptr->n_elements);
for (int i=0; i<val_ptr->n_elements; i++) {
if (val_ptr->value_elements[i] != NULL) {
ret_val.val_ptr->value_elements[(i+rc)%val_ptr->n_elements] =new ExtRAOpt(*val_ptr->value_elements[i]);
}
}
return ret_val;
}

ExtRAList ExtRAList::operator+(const ExtRAList& other_value) const
{
if (val_ptr == NULL || other_value.val_ptr == NULL) TTCN_error("Unbound operand of @GSM_RestOctets.ExtRAList concatenation.");
if (val_ptr->n_elements == 0) return other_value;
if (other_value.val_ptr->n_elements == 0) return *this;
ExtRAList ret_val;
ret_val.set_size(val_ptr->n_elements+other_value.val_ptr->n_elements);
for (int i=0; i<val_ptr->n_elements; i++) {
if (val_ptr->value_elements[i] != NULL) {
ret_val.val_ptr->value_elements[i] = new ExtRAOpt(*val_ptr->value_elements[i]);
}
}
for (int i=0; i<other_value.val_ptr->n_elements; i++) {
if (other_value.val_ptr->value_elements[i] != NULL) {
ret_val.val_ptr->value_elements[i+val_ptr->n_elements] = new ExtRAOpt(*other_value.val_ptr->value_elements[i]);
}
}
return ret_val;
}

ExtRAList ExtRAList::substr(int index, int returncount) const
{
if (val_ptr == NULL) TTCN_error("The first argument of substr() is an unbound value of type @GSM_RestOctets.ExtRAList.");
check_substr_arguments(val_ptr->n_elements, index, returncount, "@GSM_RestOctets.ExtRAList","element");
ExtRAList ret_val;
ret_val.set_size(returncount);
for (int i=0; i<returncount; i++) {
if (val_ptr->value_elements[i+index] != NULL) {
ret_val.val_ptr->value_elements[i] = new ExtRAOpt(*val_ptr->value_elements[i+index]);
}
}
return ret_val;
}

ExtRAList ExtRAList::replace(int index, int len, const ExtRAList& repl) const
{
if (val_ptr == NULL) TTCN_error("The first argument of replace() is an unbound value of type @GSM_RestOctets.ExtRAList.");
if (repl.val_ptr == NULL) TTCN_error("The fourth argument of replace() is an unbound value of type @GSM_RestOctets.ExtRAList.");
check_replace_arguments(val_ptr->n_elements, index, len, "@GSM_RestOctets.ExtRAList","element");
ExtRAList ret_val;
ret_val.set_size(val_ptr->n_elements + repl.val_ptr->n_elements - len);
for (int i = 0; i < index; i++) {
if (val_ptr->value_elements[i] != NULL) {
ret_val.val_ptr->value_elements[i] = new ExtRAOpt(*val_ptr->value_elements[i]);
}
}
for (int i = 0; i < repl.val_ptr->n_elements; i++) {
if (repl.val_ptr->value_elements[i] != NULL) {
ret_val.val_ptr->value_elements[i+index] = new ExtRAOpt(*repl.val_ptr->value_elements[i]);
}
}
for (int i = 0; i < val_ptr->n_elements - index - len; i++) {
if (val_ptr->value_elements[index+i+len] != NULL) {
ret_val.val_ptr->value_elements[index+i+repl.val_ptr->n_elements] = new ExtRAOpt(*val_ptr->value_elements[index+i+len]);
}
}
return ret_val;
}

ExtRAList ExtRAList::replace(int index, int len, const ExtRAList_template& repl) const
{
if (!repl.is_value()) TTCN_error("The fourth argument of function replace() is a template with non-specific value.");
return replace(index, len, repl.valueof());
}

void ExtRAList::set_size(int new_size)
{
if (new_size < 0) TTCN_error("Internal error: Setting a negative size for a value of type @GSM_RestOctets.ExtRAList.");
if (val_ptr == NULL) {
val_ptr = new recordof_setof_struct;
val_ptr->ref_count = 1;
val_ptr->n_elements = 0;
val_ptr->value_elements = NULL;
} else if (val_ptr->ref_count > 1) {
struct recordof_setof_struct *new_val_ptr = new recordof_setof_struct;
new_val_ptr->ref_count = 1;
new_val_ptr->n_elements = (new_size < val_ptr->n_elements) ? new_size : val_ptr->n_elements;
new_val_ptr->value_elements = (ExtRAOpt**)allocate_pointers(new_val_ptr->n_elements);
for (int elem_count = 0; elem_count < new_val_ptr->n_elements; elem_count++) {
if (val_ptr->value_elements[elem_count] != NULL){
new_val_ptr->value_elements[elem_count] = new ExtRAOpt(*(val_ptr->value_elements[elem_count]));
}
}
clean_up();
val_ptr = new_val_ptr;
}
if (new_size > val_ptr->n_elements) {
val_ptr->value_elements = (ExtRAOpt**)reallocate_pointers((void**)val_ptr->value_elements, val_ptr->n_elements, new_size);
#ifdef TITAN_MEMORY_DEBUG_SET_RECORD_OF
if((val_ptr->n_elements/1000)!=(new_size/1000)) TTCN_warning("New size of type @GSM_RestOctets.ExtRAList: %d",new_size);
#endif
val_ptr->n_elements = new_size;
} else if (new_size < val_ptr->n_elements) {
for (int elem_count = new_size; elem_count < val_ptr->n_elements; elem_count++)
if (val_ptr->value_elements[elem_count] != NULL)delete val_ptr->value_elements[elem_count];
val_ptr->value_elements = (ExtRAOpt**)reallocate_pointers((void**)val_ptr->value_elements, val_ptr->n_elements, new_size);
val_ptr->n_elements = new_size;
}
}

boolean ExtRAList::is_value() const
{
if (val_ptr == NULL) return FALSE;
for(int i = 0; i < val_ptr->n_elements; ++i) {
if (val_ptr->value_elements[i] == NULL || !val_ptr->value_elements[i]->is_value()) return FALSE;
}
return TRUE;
}

int ExtRAList::size_of() const
{
if (val_ptr == NULL) TTCN_error("Performing sizeof operation on an unbound value of type @GSM_RestOctets.ExtRAList.");
return val_ptr->n_elements;
}

int ExtRAList::lengthof() const
{
if (val_ptr == NULL) TTCN_error("Performing lengthof operation on an unbound value of type @GSM_RestOctets.ExtRAList.");
for (int my_length=val_ptr->n_elements; my_length>0; my_length--) if (val_ptr->value_elements[my_length-1] != NULL) return my_length;
return 0;
}

void ExtRAList::log() const
{
if (val_ptr == NULL) {;
TTCN_Logger::log_event_unbound();
return;
}
switch (val_ptr->n_elements) {
case 0:
TTCN_Logger::log_event_str("{ }");
break;
default:
TTCN_Logger::log_event_str("{ ");
for (int elem_count = 0; elem_count < val_ptr->n_elements; elem_count++) {
if (elem_count > 0) TTCN_Logger::log_event_str(", ");
(*this)[elem_count].log();
}
TTCN_Logger::log_event_str(" }");
}
}

void ExtRAList::set_implicit_omit()
{
if (val_ptr == NULL) return;
for (int i = 0; i < val_ptr->n_elements; i++) {
if (val_ptr->value_elements[i] != NULL) val_ptr->value_elements[i]->set_implicit_omit();
}
}

void ExtRAList::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE|Module_Param::BC_LIST, "record of value");
  switch (param.get_operation_type()) {
  case Module_Param::OT_ASSIGN:
    if (param.get_type()==Module_Param::MP_Value_List && param.get_size()==0) {
      *this = NULL_VALUE;
      return;
    }
    switch (param.get_type()) {
    case Module_Param::MP_Value_List:
      set_size(param.get_size());
      for (size_t i=0; i<param.get_size(); ++i) {
        Module_Param* const curr = param.get_elem(i);
        if (curr->get_type()!=Module_Param::MP_NotUsed) {
          (*this)[i].set_param(*curr);
          if (!(*this)[i].is_bound()) {
            delete val_ptr->value_elements[i];
            val_ptr->value_elements[i] = NULL;
          }
        }
      }
      break;
    case Module_Param::MP_Indexed_List:
      for (size_t i=0; i<param.get_size(); ++i) {
        Module_Param* const curr = param.get_elem(i);
        (*this)[curr->get_id()->get_index()].set_param(*curr);
        if (!(*this)[curr->get_id()->get_index()].is_bound()) {
          delete val_ptr->value_elements[curr->get_id()->get_index()];
          val_ptr->value_elements[curr->get_id()->get_index()] = NULL;
        }
      }
      break;
    default:
      param.type_error("record of value", "@GSM_RestOctets.ExtRAList");
    }
    break;
  case Module_Param::OT_CONCAT:
    switch (param.get_type()) {
    case Module_Param::MP_Value_List: {
      if (!is_bound()) *this = NULL_VALUE;
      int start_idx = lengthof();
      for (size_t i=0; i<param.get_size(); ++i) {
        Module_Param* const curr = param.get_elem(i);
        if ((curr->get_type()!=Module_Param::MP_NotUsed)) {
          (*this)[start_idx+(int)i].set_param(*curr);
        }
      }
    } break;
    case Module_Param::MP_Indexed_List:
      param.error("Cannot concatenate an indexed value list");
      break;
    default:
      param.type_error("record of value", "@GSM_RestOctets.ExtRAList");
    }
    break;
  default:
    TTCN_error("Internal error: Unknown operation type.");
  }
}

void ExtRAList::encode_text(Text_Buf& text_buf) const
{
if (val_ptr == NULL) TTCN_error("Text encoder: Encoding an unbound value of type @GSM_RestOctets.ExtRAList.");
text_buf.push_int(val_ptr->n_elements);
for (int elem_count = 0; elem_count < val_ptr->n_elements; elem_count++)
(*this)[elem_count].encode_text(text_buf);
}

void ExtRAList::decode_text(Text_Buf& text_buf)
{
clean_up();
val_ptr = new recordof_setof_struct;
val_ptr->ref_count = 1;
val_ptr->n_elements = text_buf.pull_int().get_val();
if (val_ptr->n_elements < 0) TTCN_error("Text decoder: Negative size was received for a value of type @GSM_RestOctets.ExtRAList.");
val_ptr->value_elements = (ExtRAOpt**)allocate_pointers(val_ptr->n_elements);
for (int elem_count = 0; elem_count < val_ptr->n_elements; elem_count++) {
val_ptr->value_elements[elem_count] = new ExtRAOpt;
val_ptr->value_elements[elem_count]->decode_text(text_buf);
}
}

void ExtRAList::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void ExtRAList::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int ExtRAList::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean /*no_err*/, int sel_field, boolean first_call, const RAW_Force_Omit*){
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  int decoded_length=0;
  int decoded_field_length=0;
  size_t start_of_field=0;
  if(first_call) {
    clean_up();
    val_ptr=new recordof_setof_struct;
    val_ptr->ref_count=1;
    val_ptr->n_elements=0;
    val_ptr->value_elements=NULL;
  }
  int start_field=val_ptr->n_elements;
  if(p_td.raw->fieldlength || sel_field!=-1){
    int a=0;
    if(sel_field==-1) sel_field=p_td.raw->fieldlength;
    start_of_field=p_buf.get_pos_bit();
    for(a=0;a<sel_field;a++){
      decoded_field_length=(*this)[a+start_field].RAW_decode(*p_td.oftype_descr,p_buf,limit,top_bit_ord,TRUE);
      if(decoded_field_length < 0){
        while(a>=0){
          delete &(*this)[a+start_field];
          a--;
          val_ptr->n_elements--;
        }
        p_buf.set_pos_bit(start_of_field);
        return decoded_field_length;
      }
      decoded_length+=decoded_field_length;
      limit-=decoded_field_length;
    }
    if(a==0) val_ptr->n_elements=0;
  } else {
    if(limit==0){
      if(!first_call) return -1;
      val_ptr->n_elements=0;
      return decoded_length+p_buf.increase_pos_padd(p_td.raw->padding)+prepaddlength;
    }
    int a=start_field;
    while(limit>0){
      start_of_field=p_buf.get_pos_bit();
      decoded_field_length=(*this)[a].RAW_decode(*p_td.oftype_descr,p_buf,limit,top_bit_ord,TRUE);
      if(decoded_field_length < 0){
        delete &(*this)[a];
        val_ptr->n_elements--;
        p_buf.set_pos_bit(start_of_field);
        if(a>start_field){
        return decoded_length+p_buf.increase_pos_padd(p_td.raw->padding)+prepaddlength;
        } else return -1;
      }
      decoded_length+=decoded_field_length;
      limit-=decoded_field_length;
      a++;
    }
  }
 return decoded_length+p_buf.increase_pos_padd(p_td.raw->padding)+prepaddlength;
}

int ExtRAList::RAW_encode(const TTCN_Typedescriptor_t& p_td,RAW_enc_tree& myleaf) const{
  int encoded_length=0;
  int encoded_num_of_records=p_td.raw->fieldlength?smaller(val_ptr->n_elements, p_td.raw->fieldlength):val_ptr->n_elements;
  myleaf.isleaf=FALSE;
  myleaf.rec_of=TRUE;
  myleaf.body.node.num_of_nodes=encoded_num_of_records;
  myleaf.body.node.nodes=init_nodes_of_enc_tree(encoded_num_of_records);
  for(int a=0;a<encoded_num_of_records;a++){
    myleaf.body.node.nodes[a]=new RAW_enc_tree(TRUE,&myleaf,&(myleaf.curr_pos),a,p_td.oftype_descr->raw);
    encoded_length+=(*this)[a].RAW_encode(*p_td.oftype_descr,*myleaf.body.node.nodes[a]);
  }
 return myleaf.length=encoded_length;
}

void ExtRAList_template::copy_value(const ExtRAList& other_value)
{
if (!other_value.is_bound()) TTCN_error("Initialization of a template of type @GSM_RestOctets.ExtRAList with an unbound value.");
single_value.n_elements = other_value.size_of();
single_value.value_elements = (ExtRAOpt_template**)allocate_pointers(single_value.n_elements);
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++) {
if (other_value[elem_count].is_bound()) {
single_value.value_elements[elem_count] = new ExtRAOpt_template(other_value[elem_count]);
} else {
single_value.value_elements[elem_count] = new ExtRAOpt_template;
}
}
set_selection(SPECIFIC_VALUE);
}

void ExtRAList_template::copy_template(const ExtRAList_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value.n_elements = other_value.single_value.n_elements;
single_value.value_elements = (ExtRAOpt_template**)allocate_pointers(single_value.n_elements);
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++) {
if (UNINITIALIZED_TEMPLATE != other_value.single_value.value_elements[elem_count]->get_selection()) {
single_value.value_elements[elem_count] = new ExtRAOpt_template(*other_value.single_value.value_elements[elem_count]);
} else {
single_value.value_elements[elem_count] = new ExtRAOpt_template;
}
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new ExtRAList_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new ExtRAList_template(*other_value.implication_.precondition);
implication_.implied_template = new ExtRAList_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.ExtRAList.");
break;
}
set_selection(other_value);
}

boolean ExtRAList_template::match_function_specific(const Base_Type *value_ptr, int value_index, const Restricted_Length_Template *template_ptr, int template_index, boolean legacy)
{
if (value_index >= 0) return ((const ExtRAList_template*)template_ptr)->single_value.value_elements[template_index]->match((*(const ExtRAList*)value_ptr)[value_index], legacy);
else return ((const ExtRAList_template*)template_ptr)->single_value.value_elements[template_index]->is_any_or_omit();
}

ExtRAList_template::ExtRAList_template()
{
}

ExtRAList_template::ExtRAList_template(template_sel other_value)
 : Base_Record_Of_Template(other_value)
{
check_single_selection(other_value);
}

ExtRAList_template::ExtRAList_template(null_type)
 : Base_Record_Of_Template(SPECIFIC_VALUE)
{
single_value.n_elements = 0;
single_value.value_elements = NULL;
}

ExtRAList_template::ExtRAList_template(const ExtRAList& other_value)
{
copy_value(other_value);
}

ExtRAList_template::ExtRAList_template(const OPTIONAL<ExtRAList>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const ExtRAList&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.ExtRAList from an unbound optional field.");
}
}

ExtRAList_template::ExtRAList_template(ExtRAList_template* p_precondition, ExtRAList_template* p_implied_template)
 : Base_Record_Of_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

ExtRAList_template::ExtRAList_template(Dynamic_Match_Interface<ExtRAList>* p_dyn_match)
 : Base_Record_Of_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<ExtRAList>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

ExtRAList_template::ExtRAList_template(const ExtRAList_template& other_value)
 : Base_Record_Of_Template()
{
copy_template(other_value);
}

ExtRAList_template::~ExtRAList_template()
{
clean_up();
}

void ExtRAList_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++)
delete single_value.value_elements[elem_count];
free_pointers((void**)single_value.value_elements);
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

ExtRAList_template& ExtRAList_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

ExtRAList_template& ExtRAList_template::operator=(null_type)
{
clean_up();
set_selection(SPECIFIC_VALUE);
single_value.n_elements = 0;
single_value.value_elements = NULL;
return *this;
}

ExtRAList_template& ExtRAList_template::operator=(const ExtRAList& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

ExtRAList_template& ExtRAList_template::operator=(const OPTIONAL<ExtRAList>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const ExtRAList&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.ExtRAList.");
}
return *this;
}

ExtRAList_template& ExtRAList_template::operator=(const ExtRAList_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

ExtRAOpt_template& ExtRAList_template::operator[](int index_value)
{
if (index_value < 0) TTCN_error("Accessing an element of a template for type @GSM_RestOctets.ExtRAList using a negative index: %d.", index_value);
switch (template_selection)
{
  case SPECIFIC_VALUE:
    if(index_value < single_value.n_elements) break;
    // no break
  case OMIT_VALUE:
  case ANY_VALUE:
  case ANY_OR_OMIT:
  case UNINITIALIZED_TEMPLATE:
    set_size(index_value + 1);
    break;
  default:
    TTCN_error("Accessing an element of a non-specific template for type @GSM_RestOctets.ExtRAList.");
    break;
}
return *single_value.value_elements[index_value];
}

ExtRAOpt_template& ExtRAList_template::operator[](const INTEGER& index_value)
{
index_value.must_bound("Using an unbound integer value for indexing a template of type @GSM_RestOctets.ExtRAList.");
return (*this)[(int)index_value];
}

const ExtRAOpt_template& ExtRAList_template::operator[](int index_value) const
{
if (index_value < 0) TTCN_error("Accessing an element of a template for type @GSM_RestOctets.ExtRAList using a negative index: %d.", index_value);
if (template_selection != SPECIFIC_VALUE) TTCN_error("Accessing an element of a non-specific template for type @GSM_RestOctets.ExtRAList.");
if (index_value >= single_value.n_elements) TTCN_error("Index overflow in a template of type @GSM_RestOctets.ExtRAList: The index is %d, but the template has only %d elements.", index_value, single_value.n_elements);
return *single_value.value_elements[index_value];
}

const ExtRAOpt_template& ExtRAList_template::operator[](const INTEGER& index_value) const
{
index_value.must_bound("Using an unbound integer value for indexing a template of type @GSM_RestOctets.ExtRAList.");
return (*this)[(int)index_value];
}

void ExtRAList_template::set_size(int new_size)
{
if (new_size < 0) TTCN_error("Internal error: Setting a negative size for a template of type @GSM_RestOctets.ExtRAList.");
template_sel old_selection = template_selection;
if (old_selection != SPECIFIC_VALUE) {
clean_up();
set_selection(SPECIFIC_VALUE);
single_value.n_elements = 0;
single_value.value_elements = NULL;
}
if (new_size > single_value.n_elements) {
single_value.value_elements = (ExtRAOpt_template**)reallocate_pointers((void**)single_value.value_elements, single_value.n_elements, new_size);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
for (int elem_count = single_value.n_elements; elem_count < new_size; elem_count++)
single_value.value_elements[elem_count] = new ExtRAOpt_template(ANY_VALUE);
} else {
for (int elem_count = single_value.n_elements; elem_count < new_size; elem_count++)
single_value.value_elements[elem_count] = new ExtRAOpt_template;
}
single_value.n_elements = new_size;
} else if (new_size < single_value.n_elements) {
for (int elem_count = new_size; elem_count < single_value.n_elements; elem_count++)
delete single_value.value_elements[elem_count];
single_value.value_elements = (ExtRAOpt_template**)reallocate_pointers((void**)single_value.value_elements, single_value.n_elements, new_size);
single_value.n_elements = new_size;
}
}

int ExtRAList_template::n_elem() const
{
  switch (template_selection) {
  case SPECIFIC_VALUE:
    return single_value.n_elements;
    break;
  case VALUE_LIST:
    return value_list.n_values;
    break;
  default:
    TTCN_error("Performing n_elem");
  }
}

int ExtRAList_template::size_of(boolean is_size) const
{
const char* op_name = is_size ? "size" : "length";
int min_size;
boolean has_any_or_none;
if (is_ifpresent) TTCN_error("Performing %sof() operation on a template of type @GSM_RestOctets.ExtRAList which has an ifpresent attribute.", op_name);
switch (template_selection)
{
case SPECIFIC_VALUE: {
  min_size = 0;
  has_any_or_none = FALSE;
  int elem_count = single_value.n_elements;
  if (!is_size) { while (elem_count>0 && !single_value.value_elements[elem_count-1]->is_bound()) elem_count--; }
  for (int i=0; i<elem_count; i++) {
    switch (single_value.value_elements[i]->get_selection()) {
    case OMIT_VALUE:
      TTCN_error("Performing %sof() operation on a template of type @GSM_RestOctets.ExtRAList containing omit element.", op_name);
    case ANY_OR_OMIT:
      has_any_or_none = TRUE;
      break;
    default:
      min_size++;
      break;
    }
  }
} break;
case OMIT_VALUE:
  TTCN_error("Performing %sof() operation on a template of type @GSM_RestOctets.ExtRAList containing omit value.", op_name);
case ANY_VALUE:
case ANY_OR_OMIT:
  min_size = 0;
  has_any_or_none = TRUE;
  break;
case VALUE_LIST:
{
  if (value_list.n_values<1)
    TTCN_error("Performing %sof() operation on a template of type @GSM_RestOctets.ExtRAList containing an empty list.", op_name);
  int item_size = value_list.list_value[0].size_of(is_size);
  for (unsigned int i = 1; i < value_list.n_values; i++) {
    if (value_list.list_value[i].size_of(is_size)!=item_size)
      TTCN_error("Performing %sof() operation on a template of type @GSM_RestOctets.ExtRAList containing a value list with different sizes.", op_name);
  }
  min_size = item_size;
  has_any_or_none = FALSE;
  break;
}
case COMPLEMENTED_LIST:
  TTCN_error("Performing %sof() operation on a template of type @GSM_RestOctets.ExtRAList containing complemented list.", op_name);
default:
  TTCN_error("Performing %sof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.ExtRAList.", op_name);
}
return check_section_is_single(min_size, has_any_or_none, op_name, "a", "template of type @GSM_RestOctets.ExtRAList");
}

boolean ExtRAList_template::match(const ExtRAList& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
int value_length = other_value.size_of();
if (!match_length(value_length)) return FALSE;
switch (template_selection) {
case SPECIFIC_VALUE:
return match_record_of(&other_value, value_length, this, single_value.n_elements, match_function_specific, legacy);
case OMIT_VALUE:
return FALSE;
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching with an uninitialized/unsupported template of type @GSM_RestOctets.ExtRAList.");
}
return FALSE;
}

boolean ExtRAList_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++)
if (!single_value.value_elements[elem_count]->is_value()) return FALSE;
return TRUE;
}

ExtRAList ExtRAList_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.ExtRAList.");
ExtRAList ret_val;
ret_val.set_size(single_value.n_elements);
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++)
if (single_value.value_elements[elem_count]->is_bound()) {
ret_val[elem_count] = single_value.value_elements[elem_count]->valueof();
}
return ret_val;
}

ExtRAList ExtRAList_template::substr(int index, int returncount) const
{
if (!is_value()) TTCN_error("The first argument of function substr() is a template with non-specific value.");
return valueof().substr(index, returncount);
}

ExtRAList ExtRAList_template::replace(int index, int len, const ExtRAList_template& repl) const
{
if (!is_value()) TTCN_error("The first argument of function replace() is a template with non-specific value.");
if (!repl.is_value()) TTCN_error("The fourth argument of function replace() is a template with non-specific value.");
return valueof().replace(index, len, repl.valueof());
}

ExtRAList ExtRAList_template::replace(int index, int len, const ExtRAList& repl) const
{
if (!is_value()) TTCN_error("The first argument of function replace() is a template with non-specific value.");
return valueof().replace(index, len, repl);
}

void ExtRAList_template::set_type(template_sel template_type, unsigned int list_length)
{
clean_up();
switch (template_type) {
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = list_length;
value_list.list_value = new ExtRAList_template[list_length];
break;
default:
TTCN_error("Internal error: Setting an invalid type for a template of type @GSM_RestOctets.ExtRAList.");
}
set_selection(template_type);
}

ExtRAList_template& ExtRAList_template::list_item(unsigned int list_index)
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST && template_selection != CONJUNCTION_MATCH) TTCN_error("Internal error: Accessing a list element of a non-list template of type @GSM_RestOctets.ExtRAList.");
if (list_index >= value_list.n_values) TTCN_error("Internal error: Index overflow in a value list template of type @GSM_RestOctets.ExtRAList.");
return value_list.list_value[list_index];
}

void ExtRAList_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
if (single_value.n_elements > 0) {
TTCN_Logger::log_event_str("{ ");
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++) {
if (elem_count > 0) TTCN_Logger::log_event_str(", ");
if (permutation_starts_at(elem_count)) TTCN_Logger::log_event_str("permutation(");
single_value.value_elements[elem_count]->log();
if (permutation_ends_at(elem_count)) TTCN_Logger::log_char(')');
}
TTCN_Logger::log_event_str(" }");
} else TTCN_Logger::log_event_str("{ }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_restricted();
log_ifpresent();
}

void ExtRAList_template::log_match(const ExtRAList& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
}else{
if (template_selection == SPECIFIC_VALUE && single_value.n_elements > 0 && get_number_of_permutations() == 0 && single_value.n_elements == match_value.size_of()) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++) {
if(!single_value.value_elements[elem_count]->match(match_value[elem_count], legacy)){
TTCN_Logger::log_logmatch_info("[%d]", elem_count);
single_value.value_elements[elem_count]->log_match(match_value[elem_count], legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
log_match_length(single_value.n_elements);
} else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE && single_value.n_elements > 0 && get_number_of_permutations() == 0 && single_value.n_elements == match_value.size_of()) {
TTCN_Logger::log_event_str("{ ");
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++) {
if (elem_count > 0) TTCN_Logger::log_event_str(", ");
single_value.value_elements[elem_count]->log_match(match_value[elem_count], legacy);
}
TTCN_Logger::log_event_str(" }");
log_match_length(single_value.n_elements);
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void ExtRAList_template::encode_text(Text_Buf& text_buf) const
{
encode_text_permutation(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
text_buf.push_int(single_value.n_elements);
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++)
single_value.value_elements[elem_count]->encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.ExtRAList.");
}
}

void ExtRAList_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_permutation(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value.n_elements = text_buf.pull_int().get_val();
if (single_value.n_elements < 0) TTCN_error("Text decoder: Negative size was received for a template of type @GSM_RestOctets.ExtRAList.");
single_value.value_elements = (ExtRAOpt_template**)allocate_pointers(single_value.n_elements);
for (int elem_count = 0; elem_count < single_value.n_elements; elem_count++) {
single_value.value_elements[elem_count] = new ExtRAOpt_template;
single_value.value_elements[elem_count]->decode_text(text_buf);
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new ExtRAList_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received for a template of type @GSM_RestOctets.ExtRAList.");
}
}

boolean ExtRAList_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean ExtRAList_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int i=0; i<value_list.n_values; i++)
if (value_list.list_value[i].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

void ExtRAList_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
for (int i = 0; i < single_value.n_elements; i++) {
if (single_value.value_elements[i] != NULL) single_value.value_elements[i]->set_implicit_omit();
}
}

void ExtRAList_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE|Module_Param::BC_LIST, "record of template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    ExtRAList_template temp;
    temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = temp;
    break; }
  case Module_Param::MP_Indexed_List:
    if (template_selection!=SPECIFIC_VALUE) set_size(0);
    for (size_t p_i=0; p_i<param.get_size(); ++p_i) {
      (*this)[(int)(param.get_elem(p_i)->get_id()->get_index())].set_param(*param.get_elem(p_i));
    }
    break;
  case Module_Param::MP_Value_List: {
    set_size(param.get_size());
    int curr_idx = 0;
    for (size_t p_i=0; p_i<param.get_size(); ++p_i) {
      switch (param.get_elem(p_i)->get_type()) {
      case Module_Param::MP_NotUsed:
        curr_idx++;
        break;
      case Module_Param::MP_Permutation_Template: {
        int perm_start_idx = curr_idx;
        Module_Param* param_i = param.get_elem(p_i);
        for (size_t perm_i=0; perm_i<param_i->get_size(); perm_i++) {
          (*this)[curr_idx].set_param(*(param_i->get_elem(perm_i)));
          curr_idx++;
        }
        int perm_end_idx = curr_idx - 1;
        add_permutation(perm_start_idx, perm_end_idx);
      } break;
      default:
        (*this)[curr_idx].set_param(*param.get_elem(p_i));
        curr_idx++;
      }
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    ExtRAList_template* precondition = new ExtRAList_template;
    precondition->set_param(*param.get_elem(0));
    ExtRAList_template* implied_template = new ExtRAList_template;
    implied_template->set_param(*param.get_elem(1));
    *this = ExtRAList_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record of template", "@GSM_RestOctets.ExtRAList");
  }
  is_ifpresent = param.get_ifpresent();
  set_length_range(param);
}

void ExtRAList_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
for (int i=0; i<single_value.n_elements; i++) single_value.value_elements[i]->check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.ExtRAList");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.ExtRAList");
}

boolean ExtRAList_template::get_istemplate_kind(const char* type) const {
if (!strcmp(type, "AnyElement")) {
  if (template_selection != SPECIFIC_VALUE) {
    return FALSE;
  }
  for (int i = 0; i < single_value.n_elements; i++) {
    if (single_value.value_elements[i]->get_selection() == ANY_VALUE) {
      return TRUE;
    }
  }
  return FALSE;
} else if (!strcmp(type, "AnyElementsOrNone")) {
  if (template_selection != SPECIFIC_VALUE) {
    return FALSE;
  }
  for (int i = 0; i < single_value.n_elements; i++) {
    if (single_value.value_elements[i]->get_selection() == ANY_OR_OMIT) {
      return TRUE;
    }
  }
  return FALSE;
} else if (!strcmp(type, "permutation")) {
  return number_of_permutations;
} else if (!strcmp(type, "length")) {
  return length_restriction_type != NO_LENGTH_RESTRICTION;
} else {
  return Base_Template::get_istemplate_kind(type);
}
}
ExtRAOpt::ExtRAOpt()
{
}

ExtRAOpt::ExtRAOpt(const BITSTRING& par_presence,
    const OPTIONAL< BITSTRING >& par_ext__ra)
  :   field_presence(par_presence),
  field_ext__ra(par_ext__ra)
{
}

ExtRAOpt::ExtRAOpt(const ExtRAOpt& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.ExtRAOpt.");
if (other_value.presence().is_bound()) field_presence = other_value.presence();
else field_presence.clean_up();
if (other_value.ext__ra().is_bound()) field_ext__ra = other_value.ext__ra();
else field_ext__ra.clean_up();
}

void ExtRAOpt::clean_up()
{
field_presence.clean_up();
field_ext__ra.clean_up();
}

const TTCN_Typedescriptor_t* ExtRAOpt::get_descriptor() const { return &ExtRAOpt_descr_; }
ExtRAOpt& ExtRAOpt::operator=(const ExtRAOpt& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.ExtRAOpt.");
  if (other_value.presence().is_bound()) field_presence = other_value.presence();
  else field_presence.clean_up();
  if (other_value.ext__ra().is_bound()) field_ext__ra = other_value.ext__ra();
  else field_ext__ra.clean_up();
}
return *this;
}

boolean ExtRAOpt::operator==(const ExtRAOpt& other_value) const
{
return field_presence==other_value.field_presence
  && field_ext__ra==other_value.field_ext__ra;
}

boolean ExtRAOpt::is_bound() const
{
return (field_presence.is_bound())
  || (OPTIONAL_OMIT == field_ext__ra.get_selection() || field_ext__ra.is_bound());
}
boolean ExtRAOpt::is_value() const
{
return field_presence.is_value()
  && (OPTIONAL_OMIT == field_ext__ra.get_selection() || field_ext__ra.is_value());
}
int ExtRAOpt::size_of() const
{
  int ret_val = 1;
  if (field_ext__ra.ispresent()) ret_val++;
  return ret_val;
}

void ExtRAOpt::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ presence := ");
field_presence.log();
TTCN_Logger::log_event_str(", ext_ra := ");
field_ext__ra.log();
TTCN_Logger::log_event_str(" }");
}

void ExtRAOpt::set_implicit_omit()
{
if (presence().is_bound()) presence().set_implicit_omit();
if (!ext__ra().is_bound()) ext__ra() = OMIT_VALUE;
else ext__ra().set_implicit_omit();
}

void ExtRAOpt::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.ExtRAOpt has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) ext__ra().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ext_ra")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ext__ra().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.ExtRAOpt: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.ExtRAOpt");
  }
}

void ExtRAOpt::encode_text(Text_Buf& text_buf) const
{
field_presence.encode_text(text_buf);
field_ext__ra.encode_text(text_buf);
}

void ExtRAOpt::decode_text(Text_Buf& text_buf)
{
field_presence.decode_text(text_buf);
field_ext__ra.decode_text(text_buf);
}

void ExtRAOpt::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void ExtRAOpt::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int ExtRAOpt::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, ExtRAOpt_presence_descr_.raw->forceomit);
  decoded_field_length = field_presence.RAW_decode(ExtRAOpt_presence_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_presence ==  bs_0){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_ext__ra = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, ExtRAOpt_ext__ra_descr_.raw->forceomit);
  decoded_field_length = field_ext__ra().RAW_decode(ExtRAOpt_ext__ra_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_ext__ra = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_ext__ra=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int ExtRAOpt::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 2;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(2);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, ExtRAOpt_presence_descr_.raw);
  if (field_ext__ra.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, ExtRAOpt_ext__ra_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  encoded_length += field_presence.RAW_encode(ExtRAOpt_presence_descr_, *myleaf.body.node.nodes[0]);
  if (field_ext__ra.ispresent()) {
  encoded_length += field_ext__ra().RAW_encode(ExtRAOpt_ext__ra_descr_, *myleaf.body.node.nodes[1]);
  }
  if (field_ext__ra.ispresent() && (field_presence !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(ExtRAOpt_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct ExtRAOpt_template::single_value_struct {
BITSTRING_template field_presence;
BITSTRING_template field_ext__ra;
};

void ExtRAOpt_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_presence = ANY_VALUE;
single_value->field_ext__ra = ANY_OR_OMIT;
}
}
}

void ExtRAOpt_template::copy_value(const ExtRAOpt& other_value)
{
single_value = new single_value_struct;
if (other_value.presence().is_bound()) {
  single_value->field_presence = other_value.presence();
} else {
  single_value->field_presence.clean_up();
}
if (other_value.ext__ra().is_bound()) {
  if (other_value.ext__ra().ispresent()) single_value->field_ext__ra = other_value.ext__ra()();
  else single_value->field_ext__ra = OMIT_VALUE;
} else {
  single_value->field_ext__ra.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void ExtRAOpt_template::copy_template(const ExtRAOpt_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.presence().get_selection()) {
single_value->field_presence = other_value.presence();
} else {
single_value->field_presence.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.ext__ra().get_selection()) {
single_value->field_ext__ra = other_value.ext__ra();
} else {
single_value->field_ext__ra.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new ExtRAOpt_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new ExtRAOpt_template(*other_value.implication_.precondition);
implication_.implied_template = new ExtRAOpt_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.ExtRAOpt.");
break;
}
set_selection(other_value);
}

ExtRAOpt_template::ExtRAOpt_template()
{
}

ExtRAOpt_template::ExtRAOpt_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

ExtRAOpt_template::ExtRAOpt_template(const ExtRAOpt& other_value)
{
copy_value(other_value);
}

ExtRAOpt_template::ExtRAOpt_template(const OPTIONAL<ExtRAOpt>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const ExtRAOpt&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.ExtRAOpt from an unbound optional field.");
}
}

ExtRAOpt_template::ExtRAOpt_template(ExtRAOpt_template* p_precondition, ExtRAOpt_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

ExtRAOpt_template::ExtRAOpt_template(Dynamic_Match_Interface<ExtRAOpt>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<ExtRAOpt>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

ExtRAOpt_template::ExtRAOpt_template(const ExtRAOpt_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

ExtRAOpt_template::~ExtRAOpt_template()
{
clean_up();
}

ExtRAOpt_template& ExtRAOpt_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

ExtRAOpt_template& ExtRAOpt_template::operator=(const ExtRAOpt& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

ExtRAOpt_template& ExtRAOpt_template::operator=(const OPTIONAL<ExtRAOpt>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const ExtRAOpt&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.ExtRAOpt.");
}
return *this;
}

ExtRAOpt_template& ExtRAOpt_template::operator=(const ExtRAOpt_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean ExtRAOpt_template::match(const ExtRAOpt& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.presence().is_bound()) return FALSE;
if(!single_value->field_presence.match(other_value.presence(), legacy))return FALSE;
if(!other_value.ext__ra().is_bound()) return FALSE;
if((other_value.ext__ra().ispresent() ? !single_value->field_ext__ra.match((const BITSTRING&)other_value.ext__ra(), legacy) : !single_value->field_ext__ra.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.ExtRAOpt.");
}
return FALSE;
}

boolean ExtRAOpt_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_presence.is_bound()
 || (single_value->field_ext__ra.is_omit() || single_value->field_ext__ra.is_bound());
}

boolean ExtRAOpt_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_presence.is_value()
 && (single_value->field_ext__ra.is_omit() || single_value->field_ext__ra.is_value());
}

void ExtRAOpt_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

ExtRAOpt ExtRAOpt_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.ExtRAOpt.");
ExtRAOpt ret_val;
if (single_value->field_presence.is_bound()) {
ret_val.presence() = single_value->field_presence.valueof();
}
if (single_value->field_ext__ra.is_omit()) ret_val.ext__ra() = OMIT_VALUE;
else if (single_value->field_ext__ra.is_bound()) {
ret_val.ext__ra() = single_value->field_ext__ra.valueof();
}
return ret_val;
}

void ExtRAOpt_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.ExtRAOpt.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new ExtRAOpt_template[list_length];
}

ExtRAOpt_template& ExtRAOpt_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.ExtRAOpt.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.ExtRAOpt.");
return value_list.list_value[list_index];
}

BITSTRING_template& ExtRAOpt_template::presence()
{
set_specific();
return single_value->field_presence;
}

const BITSTRING_template& ExtRAOpt_template::presence() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field presence of a non-specific template of type @GSM_RestOctets.ExtRAOpt.");
return single_value->field_presence;
}

BITSTRING_template& ExtRAOpt_template::ext__ra()
{
set_specific();
return single_value->field_ext__ra;
}

const BITSTRING_template& ExtRAOpt_template::ext__ra() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ext_ra of a non-specific template of type @GSM_RestOctets.ExtRAOpt.");
return single_value->field_ext__ra;
}

int ExtRAOpt_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.ExtRAOpt which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 1;
      if (single_value->field_ext__ra.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.ExtRAOpt containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.ExtRAOpt containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.ExtRAOpt containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.ExtRAOpt containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.ExtRAOpt containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.ExtRAOpt containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.ExtRAOpt containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.ExtRAOpt containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.ExtRAOpt.");
  }
  return 0;
}

void ExtRAOpt_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log();
TTCN_Logger::log_event_str(", ext_ra := ");
single_value->field_ext__ra.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void ExtRAOpt_template::log_match(const ExtRAOpt& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_presence.match(match_value.presence(), legacy)){
TTCN_Logger::log_logmatch_info(".presence");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.ext__ra().ispresent()){
if(!single_value->field_ext__ra.match(match_value.ext__ra(), legacy)){
TTCN_Logger::log_logmatch_info(".ext_ra");
single_value->field_ext__ra.log_match(match_value.ext__ra(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_ext__ra.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".ext_ra := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_ext__ra.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::log_event_str(", ext_ra := ");
if (match_value.ext__ra().ispresent()) {
single_value->field_ext__ra.log_match(match_value.ext__ra(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_ext__ra.log();
if (single_value->field_ext__ra.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void ExtRAOpt_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (presence().is_bound()) presence().set_implicit_omit();
if (!ext__ra().is_bound()) ext__ra() = OMIT_VALUE;
else ext__ra().set_implicit_omit();
}

void ExtRAOpt_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_presence.encode_text(text_buf);
single_value->field_ext__ra.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.ExtRAOpt.");
}
}

void ExtRAOpt_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_presence.decode_text(text_buf);
single_value->field_ext__ra.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new ExtRAOpt_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.ExtRAOpt.");
}
}

void ExtRAOpt_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    ExtRAOpt_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.ExtRAOpt has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) ext__ra().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ext_ra")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ext__ra().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.ExtRAOpt: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    ExtRAOpt_template* precondition = new ExtRAOpt_template;
    precondition->set_param(*param.get_elem(0));
    ExtRAOpt_template* implied_template = new ExtRAOpt_template;
    implied_template->set_param(*param.get_elem(1));
    *this = ExtRAOpt_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.ExtRAOpt");
  }
  is_ifpresent = param.get_ifpresent();
}

void ExtRAOpt_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_presence.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.ExtRAOpt");
single_value->field_ext__ra.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.ExtRAOpt");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.ExtRAOpt");
}

boolean ExtRAOpt_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean ExtRAOpt_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

IARRestOctets::IARRestOctets()
{
}

IARRestOctets::IARRestOctets(const ExtRAList& par_ext__ra__list,
    const BITSTRING& par_rel13__ind,
    const OPTIONAL< INTEGER >& par_rcc)
  :   field_ext__ra__list(par_ext__ra__list),
  field_rel13__ind(par_rel13__ind),
  field_rcc(par_rcc)
{
}

IARRestOctets::IARRestOctets(const IARRestOctets& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.IARRestOctets.");
if (other_value.ext__ra__list().is_bound()) field_ext__ra__list = other_value.ext__ra__list();
else field_ext__ra__list.clean_up();
if (other_value.rel13__ind().is_bound()) field_rel13__ind = other_value.rel13__ind();
else field_rel13__ind.clean_up();
if (other_value.rcc().is_bound()) field_rcc = other_value.rcc();
else field_rcc.clean_up();
}

void IARRestOctets::clean_up()
{
field_ext__ra__list.clean_up();
field_rel13__ind.clean_up();
field_rcc.clean_up();
}

const TTCN_Typedescriptor_t* IARRestOctets::get_descriptor() const { return &IARRestOctets_descr_; }
IARRestOctets& IARRestOctets::operator=(const IARRestOctets& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.IARRestOctets.");
  if (other_value.ext__ra__list().is_bound()) field_ext__ra__list = other_value.ext__ra__list();
  else field_ext__ra__list.clean_up();
  if (other_value.rel13__ind().is_bound()) field_rel13__ind = other_value.rel13__ind();
  else field_rel13__ind.clean_up();
  if (other_value.rcc().is_bound()) field_rcc = other_value.rcc();
  else field_rcc.clean_up();
}
return *this;
}

boolean IARRestOctets::operator==(const IARRestOctets& other_value) const
{
return field_ext__ra__list==other_value.field_ext__ra__list
  && field_rel13__ind==other_value.field_rel13__ind
  && field_rcc==other_value.field_rcc;
}

boolean IARRestOctets::is_bound() const
{
return (field_ext__ra__list.is_bound())
  || (field_rel13__ind.is_bound())
  || (OPTIONAL_OMIT == field_rcc.get_selection() || field_rcc.is_bound());
}
boolean IARRestOctets::is_value() const
{
return field_ext__ra__list.is_value()
  && field_rel13__ind.is_value()
  && (OPTIONAL_OMIT == field_rcc.get_selection() || field_rcc.is_value());
}
int IARRestOctets::size_of() const
{
  int ret_val = 2;
  if (field_rcc.ispresent()) ret_val++;
  return ret_val;
}

void IARRestOctets::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ ext_ra_list := ");
field_ext__ra__list.log();
TTCN_Logger::log_event_str(", rel13_ind := ");
field_rel13__ind.log();
TTCN_Logger::log_event_str(", rcc := ");
field_rcc.log();
TTCN_Logger::log_event_str(" }");
}

void IARRestOctets::set_implicit_omit()
{
if (ext__ra__list().is_bound()) ext__ra__list().set_implicit_omit();
if (rel13__ind().is_bound()) rel13__ind().set_implicit_omit();
if (!rcc().is_bound()) rcc() = OMIT_VALUE;
else rcc().set_implicit_omit();
}

void IARRestOctets::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.IARRestOctets has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) ext__ra__list().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) rel13__ind().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) rcc().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ext_ra_list")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ext__ra__list().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "rel13_ind")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          rel13__ind().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "rcc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          rcc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IARRestOctets: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.IARRestOctets");
  }
}

void IARRestOctets::encode_text(Text_Buf& text_buf) const
{
field_ext__ra__list.encode_text(text_buf);
field_rel13__ind.encode_text(text_buf);
field_rcc.encode_text(text_buf);
}

void IARRestOctets::decode_text(Text_Buf& text_buf)
{
field_ext__ra__list.decode_text(text_buf);
field_rel13__ind.decode_text(text_buf);
field_rcc.decode_text(text_buf);
}

void IARRestOctets::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void IARRestOctets::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int IARRestOctets::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, IARRestOctets_ext__ra__list_descr_.raw->forceomit);
  decoded_field_length = field_ext__ra__list.RAW_decode(IARRestOctets_ext__ra__list_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_1_force_omit(1, force_omit, IARRestOctets_rel13__ind_descr_.raw->forceomit);
  decoded_field_length = field_rel13__ind.RAW_decode(IARRestOctets_rel13__ind_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_rel13__ind ==  bs_0){
  if (force_omit != NULL && (*force_omit)(2)) {
    field_rcc = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_2_force_omit(2, force_omit, IARRestOctets_rcc_descr_.raw->forceomit);
  decoded_field_length = field_rcc().RAW_decode(IARRestOctets_rcc_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_2_force_omit);
  if (decoded_field_length < 1) {
  field_rcc = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_rcc=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int IARRestOctets::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 3;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(3);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, IARRestOctets_ext__ra__list_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, IARRestOctets_rel13__ind_descr_.raw);
  if (field_rcc.ispresent()) {
  myleaf.body.node.nodes[2] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 2, IARRestOctets_rcc_descr_.raw);
  }
  else myleaf.body.node.nodes[2] = NULL;
  encoded_length += field_ext__ra__list.RAW_encode(IARRestOctets_ext__ra__list_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_rel13__ind.RAW_encode(IARRestOctets_rel13__ind_descr_, *myleaf.body.node.nodes[1]);
  if (field_rcc.ispresent()) {
  encoded_length += field_rcc().RAW_encode(IARRestOctets_rcc_descr_, *myleaf.body.node.nodes[2]);
  }
  if (field_rcc.ispresent() && (field_rel13__ind !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={1};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(IARRestOctets_rel13__ind_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct IARRestOctets_template::single_value_struct {
ExtRAList_template field_ext__ra__list;
BITSTRING_template field_rel13__ind;
INTEGER_template field_rcc;
};

void IARRestOctets_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_ext__ra__list = ANY_VALUE;
single_value->field_rel13__ind = ANY_VALUE;
single_value->field_rcc = ANY_OR_OMIT;
}
}
}

void IARRestOctets_template::copy_value(const IARRestOctets& other_value)
{
single_value = new single_value_struct;
if (other_value.ext__ra__list().is_bound()) {
  single_value->field_ext__ra__list = other_value.ext__ra__list();
} else {
  single_value->field_ext__ra__list.clean_up();
}
if (other_value.rel13__ind().is_bound()) {
  single_value->field_rel13__ind = other_value.rel13__ind();
} else {
  single_value->field_rel13__ind.clean_up();
}
if (other_value.rcc().is_bound()) {
  if (other_value.rcc().ispresent()) single_value->field_rcc = other_value.rcc()();
  else single_value->field_rcc = OMIT_VALUE;
} else {
  single_value->field_rcc.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void IARRestOctets_template::copy_template(const IARRestOctets_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.ext__ra__list().get_selection()) {
single_value->field_ext__ra__list = other_value.ext__ra__list();
} else {
single_value->field_ext__ra__list.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.rel13__ind().get_selection()) {
single_value->field_rel13__ind = other_value.rel13__ind();
} else {
single_value->field_rel13__ind.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.rcc().get_selection()) {
single_value->field_rcc = other_value.rcc();
} else {
single_value->field_rcc.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new IARRestOctets_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new IARRestOctets_template(*other_value.implication_.precondition);
implication_.implied_template = new IARRestOctets_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.IARRestOctets.");
break;
}
set_selection(other_value);
}

IARRestOctets_template::IARRestOctets_template()
{
}

IARRestOctets_template::IARRestOctets_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

IARRestOctets_template::IARRestOctets_template(const IARRestOctets& other_value)
{
copy_value(other_value);
}

IARRestOctets_template::IARRestOctets_template(const OPTIONAL<IARRestOctets>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IARRestOctets&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.IARRestOctets from an unbound optional field.");
}
}

IARRestOctets_template::IARRestOctets_template(IARRestOctets_template* p_precondition, IARRestOctets_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

IARRestOctets_template::IARRestOctets_template(Dynamic_Match_Interface<IARRestOctets>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<IARRestOctets>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

IARRestOctets_template::IARRestOctets_template(const IARRestOctets_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

IARRestOctets_template::~IARRestOctets_template()
{
clean_up();
}

IARRestOctets_template& IARRestOctets_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

IARRestOctets_template& IARRestOctets_template::operator=(const IARRestOctets& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

IARRestOctets_template& IARRestOctets_template::operator=(const OPTIONAL<IARRestOctets>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const IARRestOctets&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.IARRestOctets.");
}
return *this;
}

IARRestOctets_template& IARRestOctets_template::operator=(const IARRestOctets_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean IARRestOctets_template::match(const IARRestOctets& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.ext__ra__list().is_bound()) return FALSE;
if(!single_value->field_ext__ra__list.match(other_value.ext__ra__list(), legacy))return FALSE;
if(!other_value.rel13__ind().is_bound()) return FALSE;
if(!single_value->field_rel13__ind.match(other_value.rel13__ind(), legacy))return FALSE;
if(!other_value.rcc().is_bound()) return FALSE;
if((other_value.rcc().ispresent() ? !single_value->field_rcc.match((const INTEGER&)other_value.rcc(), legacy) : !single_value->field_rcc.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.IARRestOctets.");
}
return FALSE;
}

boolean IARRestOctets_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_ext__ra__list.is_bound()
 || single_value->field_rel13__ind.is_bound()
 || (single_value->field_rcc.is_omit() || single_value->field_rcc.is_bound());
}

boolean IARRestOctets_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_ext__ra__list.is_value()
 && single_value->field_rel13__ind.is_value()
 && (single_value->field_rcc.is_omit() || single_value->field_rcc.is_value());
}

void IARRestOctets_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

IARRestOctets IARRestOctets_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.IARRestOctets.");
IARRestOctets ret_val;
if (single_value->field_ext__ra__list.is_bound()) {
ret_val.ext__ra__list() = single_value->field_ext__ra__list.valueof();
}
if (single_value->field_rel13__ind.is_bound()) {
ret_val.rel13__ind() = single_value->field_rel13__ind.valueof();
}
if (single_value->field_rcc.is_omit()) ret_val.rcc() = OMIT_VALUE;
else if (single_value->field_rcc.is_bound()) {
ret_val.rcc() = single_value->field_rcc.valueof();
}
return ret_val;
}

void IARRestOctets_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.IARRestOctets.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new IARRestOctets_template[list_length];
}

IARRestOctets_template& IARRestOctets_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.IARRestOctets.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.IARRestOctets.");
return value_list.list_value[list_index];
}

ExtRAList_template& IARRestOctets_template::ext__ra__list()
{
set_specific();
return single_value->field_ext__ra__list;
}

const ExtRAList_template& IARRestOctets_template::ext__ra__list() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field ext_ra_list of a non-specific template of type @GSM_RestOctets.IARRestOctets.");
return single_value->field_ext__ra__list;
}

BITSTRING_template& IARRestOctets_template::rel13__ind()
{
set_specific();
return single_value->field_rel13__ind;
}

const BITSTRING_template& IARRestOctets_template::rel13__ind() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field rel13_ind of a non-specific template of type @GSM_RestOctets.IARRestOctets.");
return single_value->field_rel13__ind;
}

INTEGER_template& IARRestOctets_template::rcc()
{
set_specific();
return single_value->field_rcc;
}

const INTEGER_template& IARRestOctets_template::rcc() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field rcc of a non-specific template of type @GSM_RestOctets.IARRestOctets.");
return single_value->field_rcc;
}

int IARRestOctets_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IARRestOctets which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 2;
      if (single_value->field_rcc.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.IARRestOctets containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IARRestOctets containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IARRestOctets containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IARRestOctets containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IARRestOctets containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IARRestOctets containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IARRestOctets containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.IARRestOctets containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.IARRestOctets.");
  }
  return 0;
}

void IARRestOctets_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ ext_ra_list := ");
single_value->field_ext__ra__list.log();
TTCN_Logger::log_event_str(", rel13_ind := ");
single_value->field_rel13__ind.log();
TTCN_Logger::log_event_str(", rcc := ");
single_value->field_rcc.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void IARRestOctets_template::log_match(const IARRestOctets& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_ext__ra__list.match(match_value.ext__ra__list(), legacy)){
TTCN_Logger::log_logmatch_info(".ext_ra_list");
single_value->field_ext__ra__list.log_match(match_value.ext__ra__list(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_rel13__ind.match(match_value.rel13__ind(), legacy)){
TTCN_Logger::log_logmatch_info(".rel13_ind");
single_value->field_rel13__ind.log_match(match_value.rel13__ind(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.rcc().ispresent()){
if(!single_value->field_rcc.match(match_value.rcc(), legacy)){
TTCN_Logger::log_logmatch_info(".rcc");
single_value->field_rcc.log_match(match_value.rcc(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_rcc.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".rcc := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_rcc.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ ext_ra_list := ");
single_value->field_ext__ra__list.log_match(match_value.ext__ra__list(), legacy);
TTCN_Logger::log_event_str(", rel13_ind := ");
single_value->field_rel13__ind.log_match(match_value.rel13__ind(), legacy);
TTCN_Logger::log_event_str(", rcc := ");
if (match_value.rcc().ispresent()) {
single_value->field_rcc.log_match(match_value.rcc(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_rcc.log();
if (single_value->field_rcc.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void IARRestOctets_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (ext__ra__list().is_bound()) ext__ra__list().set_implicit_omit();
if (rel13__ind().is_bound()) rel13__ind().set_implicit_omit();
if (!rcc().is_bound()) rcc() = OMIT_VALUE;
else rcc().set_implicit_omit();
}

void IARRestOctets_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_ext__ra__list.encode_text(text_buf);
single_value->field_rel13__ind.encode_text(text_buf);
single_value->field_rcc.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.IARRestOctets.");
}
}

void IARRestOctets_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_ext__ra__list.decode_text(text_buf);
single_value->field_rel13__ind.decode_text(text_buf);
single_value->field_rcc.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new IARRestOctets_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.IARRestOctets.");
}
}

void IARRestOctets_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    IARRestOctets_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (3<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.IARRestOctets has 3 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) ext__ra__list().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) rel13__ind().set_param(*param.get_elem(1));
    if (param.get_size()>2 && param.get_elem(2)->get_type()!=Module_Param::MP_NotUsed) rcc().set_param(*param.get_elem(2));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "ext_ra_list")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          ext__ra__list().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "rel13_ind")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          rel13__ind().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "rcc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          rcc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.IARRestOctets: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    IARRestOctets_template* precondition = new IARRestOctets_template;
    precondition->set_param(*param.get_elem(0));
    IARRestOctets_template* implied_template = new IARRestOctets_template;
    implied_template->set_param(*param.get_elem(1));
    *this = IARRestOctets_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.IARRestOctets");
  }
  is_ifpresent = param.get_ifpresent();
}

void IARRestOctets_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_ext__ra__list.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IARRestOctets");
single_value->field_rel13__ind.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IARRestOctets");
single_value->field_rcc.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.IARRestOctets");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.IARRestOctets");
}

boolean IARRestOctets_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean IARRestOctets_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

MeasParamsDescOpt::MeasParamsDescOpt()
{
}

MeasParamsDescOpt::MeasParamsDescOpt(const BITSTRING& par_presence,
    const OPTIONAL< MeasParamsDesc >& par_desc)
  :   field_presence(par_presence),
  field_desc(par_desc)
{
}

MeasParamsDescOpt::MeasParamsDescOpt(const MeasParamsDescOpt& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.MeasParamsDescOpt.");
if (other_value.presence().is_bound()) field_presence = other_value.presence();
else field_presence.clean_up();
if (other_value.desc().is_bound()) field_desc = other_value.desc();
else field_desc.clean_up();
}

void MeasParamsDescOpt::clean_up()
{
field_presence.clean_up();
field_desc.clean_up();
}

const TTCN_Typedescriptor_t* MeasParamsDescOpt::get_descriptor() const { return &MeasParamsDescOpt_descr_; }
MeasParamsDescOpt& MeasParamsDescOpt::operator=(const MeasParamsDescOpt& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.MeasParamsDescOpt.");
  if (other_value.presence().is_bound()) field_presence = other_value.presence();
  else field_presence.clean_up();
  if (other_value.desc().is_bound()) field_desc = other_value.desc();
  else field_desc.clean_up();
}
return *this;
}

boolean MeasParamsDescOpt::operator==(const MeasParamsDescOpt& other_value) const
{
return field_presence==other_value.field_presence
  && field_desc==other_value.field_desc;
}

boolean MeasParamsDescOpt::is_bound() const
{
return (field_presence.is_bound())
  || (OPTIONAL_OMIT == field_desc.get_selection() || field_desc.is_bound());
}
boolean MeasParamsDescOpt::is_value() const
{
return field_presence.is_value()
  && (OPTIONAL_OMIT == field_desc.get_selection() || field_desc.is_value());
}
int MeasParamsDescOpt::size_of() const
{
  int ret_val = 1;
  if (field_desc.ispresent()) ret_val++;
  return ret_val;
}

void MeasParamsDescOpt::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ presence := ");
field_presence.log();
TTCN_Logger::log_event_str(", desc := ");
field_desc.log();
TTCN_Logger::log_event_str(" }");
}

void MeasParamsDescOpt::set_implicit_omit()
{
if (presence().is_bound()) presence().set_implicit_omit();
if (!desc().is_bound()) desc() = OMIT_VALUE;
else desc().set_implicit_omit();
}

void MeasParamsDescOpt::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.MeasParamsDescOpt has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) desc().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "desc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          desc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.MeasParamsDescOpt: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.MeasParamsDescOpt");
  }
}

void MeasParamsDescOpt::encode_text(Text_Buf& text_buf) const
{
field_presence.encode_text(text_buf);
field_desc.encode_text(text_buf);
}

void MeasParamsDescOpt::decode_text(Text_Buf& text_buf)
{
field_presence.decode_text(text_buf);
field_desc.decode_text(text_buf);
}

void MeasParamsDescOpt::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void MeasParamsDescOpt::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int MeasParamsDescOpt::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, MeasParamsDescOpt_presence_descr_.raw->forceomit);
  decoded_field_length = field_presence.RAW_decode(MeasParamsDescOpt_presence_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_presence ==  bs_0){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_desc = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, MeasParamsDescOpt_desc_descr_.raw->forceomit);
  decoded_field_length = field_desc().RAW_decode(MeasParamsDescOpt_desc_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_desc = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_desc=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int MeasParamsDescOpt::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 2;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(2);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, MeasParamsDescOpt_presence_descr_.raw);
  if (field_desc.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, MeasParamsDescOpt_desc_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  encoded_length += field_presence.RAW_encode(MeasParamsDescOpt_presence_descr_, *myleaf.body.node.nodes[0]);
  if (field_desc.ispresent()) {
  encoded_length += field_desc().RAW_encode(MeasParamsDescOpt_desc_descr_, *myleaf.body.node.nodes[1]);
  }
  if (field_desc.ispresent() && (field_presence !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(MeasParamsDescOpt_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct MeasParamsDescOpt_template::single_value_struct {
BITSTRING_template field_presence;
MeasParamsDesc_template field_desc;
};

void MeasParamsDescOpt_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_presence = ANY_VALUE;
single_value->field_desc = ANY_OR_OMIT;
}
}
}

void MeasParamsDescOpt_template::copy_value(const MeasParamsDescOpt& other_value)
{
single_value = new single_value_struct;
if (other_value.presence().is_bound()) {
  single_value->field_presence = other_value.presence();
} else {
  single_value->field_presence.clean_up();
}
if (other_value.desc().is_bound()) {
  if (other_value.desc().ispresent()) single_value->field_desc = other_value.desc()();
  else single_value->field_desc = OMIT_VALUE;
} else {
  single_value->field_desc.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void MeasParamsDescOpt_template::copy_template(const MeasParamsDescOpt_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.presence().get_selection()) {
single_value->field_presence = other_value.presence();
} else {
single_value->field_presence.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.desc().get_selection()) {
single_value->field_desc = other_value.desc();
} else {
single_value->field_desc.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new MeasParamsDescOpt_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new MeasParamsDescOpt_template(*other_value.implication_.precondition);
implication_.implied_template = new MeasParamsDescOpt_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.MeasParamsDescOpt.");
break;
}
set_selection(other_value);
}

MeasParamsDescOpt_template::MeasParamsDescOpt_template()
{
}

MeasParamsDescOpt_template::MeasParamsDescOpt_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

MeasParamsDescOpt_template::MeasParamsDescOpt_template(const MeasParamsDescOpt& other_value)
{
copy_value(other_value);
}

MeasParamsDescOpt_template::MeasParamsDescOpt_template(const OPTIONAL<MeasParamsDescOpt>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const MeasParamsDescOpt&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.MeasParamsDescOpt from an unbound optional field.");
}
}

MeasParamsDescOpt_template::MeasParamsDescOpt_template(MeasParamsDescOpt_template* p_precondition, MeasParamsDescOpt_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

MeasParamsDescOpt_template::MeasParamsDescOpt_template(Dynamic_Match_Interface<MeasParamsDescOpt>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<MeasParamsDescOpt>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

MeasParamsDescOpt_template::MeasParamsDescOpt_template(const MeasParamsDescOpt_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

MeasParamsDescOpt_template::~MeasParamsDescOpt_template()
{
clean_up();
}

MeasParamsDescOpt_template& MeasParamsDescOpt_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

MeasParamsDescOpt_template& MeasParamsDescOpt_template::operator=(const MeasParamsDescOpt& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

MeasParamsDescOpt_template& MeasParamsDescOpt_template::operator=(const OPTIONAL<MeasParamsDescOpt>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const MeasParamsDescOpt&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.MeasParamsDescOpt.");
}
return *this;
}

MeasParamsDescOpt_template& MeasParamsDescOpt_template::operator=(const MeasParamsDescOpt_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean MeasParamsDescOpt_template::match(const MeasParamsDescOpt& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.presence().is_bound()) return FALSE;
if(!single_value->field_presence.match(other_value.presence(), legacy))return FALSE;
if(!other_value.desc().is_bound()) return FALSE;
if((other_value.desc().ispresent() ? !single_value->field_desc.match((const MeasParamsDesc&)other_value.desc(), legacy) : !single_value->field_desc.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.MeasParamsDescOpt.");
}
return FALSE;
}

boolean MeasParamsDescOpt_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_presence.is_bound()
 || (single_value->field_desc.is_omit() || single_value->field_desc.is_bound());
}

boolean MeasParamsDescOpt_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_presence.is_value()
 && (single_value->field_desc.is_omit() || single_value->field_desc.is_value());
}

void MeasParamsDescOpt_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

MeasParamsDescOpt MeasParamsDescOpt_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.MeasParamsDescOpt.");
MeasParamsDescOpt ret_val;
if (single_value->field_presence.is_bound()) {
ret_val.presence() = single_value->field_presence.valueof();
}
if (single_value->field_desc.is_omit()) ret_val.desc() = OMIT_VALUE;
else if (single_value->field_desc.is_bound()) {
ret_val.desc() = single_value->field_desc.valueof();
}
return ret_val;
}

void MeasParamsDescOpt_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.MeasParamsDescOpt.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new MeasParamsDescOpt_template[list_length];
}

MeasParamsDescOpt_template& MeasParamsDescOpt_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.MeasParamsDescOpt.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.MeasParamsDescOpt.");
return value_list.list_value[list_index];
}

BITSTRING_template& MeasParamsDescOpt_template::presence()
{
set_specific();
return single_value->field_presence;
}

const BITSTRING_template& MeasParamsDescOpt_template::presence() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field presence of a non-specific template of type @GSM_RestOctets.MeasParamsDescOpt.");
return single_value->field_presence;
}

MeasParamsDesc_template& MeasParamsDescOpt_template::desc()
{
set_specific();
return single_value->field_desc;
}

const MeasParamsDesc_template& MeasParamsDescOpt_template::desc() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field desc of a non-specific template of type @GSM_RestOctets.MeasParamsDescOpt.");
return single_value->field_desc;
}

int MeasParamsDescOpt_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDescOpt which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 1;
      if (single_value->field_desc.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDescOpt containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDescOpt containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDescOpt containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDescOpt containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDescOpt containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDescOpt containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDescOpt containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDescOpt containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.MeasParamsDescOpt.");
  }
  return 0;
}

void MeasParamsDescOpt_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log();
TTCN_Logger::log_event_str(", desc := ");
single_value->field_desc.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void MeasParamsDescOpt_template::log_match(const MeasParamsDescOpt& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_presence.match(match_value.presence(), legacy)){
TTCN_Logger::log_logmatch_info(".presence");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.desc().ispresent()){
if(!single_value->field_desc.match(match_value.desc(), legacy)){
TTCN_Logger::log_logmatch_info(".desc");
single_value->field_desc.log_match(match_value.desc(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_desc.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".desc := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_desc.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::log_event_str(", desc := ");
if (match_value.desc().ispresent()) {
single_value->field_desc.log_match(match_value.desc(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_desc.log();
if (single_value->field_desc.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void MeasParamsDescOpt_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (presence().is_bound()) presence().set_implicit_omit();
if (!desc().is_bound()) desc() = OMIT_VALUE;
else desc().set_implicit_omit();
}

void MeasParamsDescOpt_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_presence.encode_text(text_buf);
single_value->field_desc.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.MeasParamsDescOpt.");
}
}

void MeasParamsDescOpt_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_presence.decode_text(text_buf);
single_value->field_desc.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new MeasParamsDescOpt_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.MeasParamsDescOpt.");
}
}

void MeasParamsDescOpt_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    MeasParamsDescOpt_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.MeasParamsDescOpt has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) desc().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "desc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          desc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.MeasParamsDescOpt: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    MeasParamsDescOpt_template* precondition = new MeasParamsDescOpt_template;
    precondition->set_param(*param.get_elem(0));
    MeasParamsDescOpt_template* implied_template = new MeasParamsDescOpt_template;
    implied_template->set_param(*param.get_elem(1));
    *this = MeasParamsDescOpt_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.MeasParamsDescOpt");
  }
  is_ifpresent = param.get_ifpresent();
}

void MeasParamsDescOpt_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_presence.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.MeasParamsDescOpt");
single_value->field_desc.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.MeasParamsDescOpt");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.MeasParamsDescOpt");
}

boolean MeasParamsDescOpt_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean MeasParamsDescOpt_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

MeasParamsDesc::MeasParamsDesc()
{
}

MeasParamsDesc::MeasParamsDesc(const BITSTRING& par_report__type,
    const BITSTRING& par_serving__band__reporting)
  :   field_report__type(par_report__type),
  field_serving__band__reporting(par_serving__band__reporting)
{
}

MeasParamsDesc::MeasParamsDesc(const MeasParamsDesc& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.MeasParamsDesc.");
if (other_value.report__type().is_bound()) field_report__type = other_value.report__type();
else field_report__type.clean_up();
if (other_value.serving__band__reporting().is_bound()) field_serving__band__reporting = other_value.serving__band__reporting();
else field_serving__band__reporting.clean_up();
}

void MeasParamsDesc::clean_up()
{
field_report__type.clean_up();
field_serving__band__reporting.clean_up();
}

const TTCN_Typedescriptor_t* MeasParamsDesc::get_descriptor() const { return &MeasParamsDesc_descr_; }
MeasParamsDesc& MeasParamsDesc::operator=(const MeasParamsDesc& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.MeasParamsDesc.");
  if (other_value.report__type().is_bound()) field_report__type = other_value.report__type();
  else field_report__type.clean_up();
  if (other_value.serving__band__reporting().is_bound()) field_serving__band__reporting = other_value.serving__band__reporting();
  else field_serving__band__reporting.clean_up();
}
return *this;
}

boolean MeasParamsDesc::operator==(const MeasParamsDesc& other_value) const
{
return field_report__type==other_value.field_report__type
  && field_serving__band__reporting==other_value.field_serving__band__reporting;
}

boolean MeasParamsDesc::is_bound() const
{
return (field_report__type.is_bound())
  || (field_serving__band__reporting.is_bound());
}
boolean MeasParamsDesc::is_value() const
{
return field_report__type.is_value()
  && field_serving__band__reporting.is_value();
}
void MeasParamsDesc::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ report_type := ");
field_report__type.log();
TTCN_Logger::log_event_str(", serving_band_reporting := ");
field_serving__band__reporting.log();
TTCN_Logger::log_event_str(" }");
}

void MeasParamsDesc::set_implicit_omit()
{
if (report__type().is_bound()) report__type().set_implicit_omit();
if (serving__band__reporting().is_bound()) serving__band__reporting().set_implicit_omit();
}

void MeasParamsDesc::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.MeasParamsDesc has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) report__type().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) serving__band__reporting().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "report_type")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          report__type().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "serving_band_reporting")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          serving__band__reporting().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.MeasParamsDesc: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.MeasParamsDesc");
  }
}

void MeasParamsDesc::encode_text(Text_Buf& text_buf) const
{
field_report__type.encode_text(text_buf);
field_serving__band__reporting.encode_text(text_buf);
}

void MeasParamsDesc::decode_text(Text_Buf& text_buf)
{
field_report__type.decode_text(text_buf);
field_serving__band__reporting.decode_text(text_buf);
}

void MeasParamsDesc::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void MeasParamsDesc::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int MeasParamsDesc::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, MeasParamsDesc_report__type_descr_.raw->forceomit);
  decoded_field_length = field_report__type.RAW_decode(MeasParamsDesc_report__type_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  RAW_Force_Omit field_1_force_omit(1, force_omit, MeasParamsDesc_serving__band__reporting_descr_.raw->forceomit);
  decoded_field_length = field_serving__band__reporting.RAW_decode(MeasParamsDesc_serving__band__reporting_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int MeasParamsDesc::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 2;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(2);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, MeasParamsDesc_report__type_descr_.raw);
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, MeasParamsDesc_serving__band__reporting_descr_.raw);
  encoded_length += field_report__type.RAW_encode(MeasParamsDesc_report__type_descr_, *myleaf.body.node.nodes[0]);
  encoded_length += field_serving__band__reporting.RAW_encode(MeasParamsDesc_serving__band__reporting_descr_, *myleaf.body.node.nodes[1]);
  return myleaf.length = encoded_length;
}

struct MeasParamsDesc_template::single_value_struct {
BITSTRING_template field_report__type;
BITSTRING_template field_serving__band__reporting;
};

void MeasParamsDesc_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_report__type = ANY_VALUE;
single_value->field_serving__band__reporting = ANY_VALUE;
}
}
}

void MeasParamsDesc_template::copy_value(const MeasParamsDesc& other_value)
{
single_value = new single_value_struct;
if (other_value.report__type().is_bound()) {
  single_value->field_report__type = other_value.report__type();
} else {
  single_value->field_report__type.clean_up();
}
if (other_value.serving__band__reporting().is_bound()) {
  single_value->field_serving__band__reporting = other_value.serving__band__reporting();
} else {
  single_value->field_serving__band__reporting.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void MeasParamsDesc_template::copy_template(const MeasParamsDesc_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.report__type().get_selection()) {
single_value->field_report__type = other_value.report__type();
} else {
single_value->field_report__type.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.serving__band__reporting().get_selection()) {
single_value->field_serving__band__reporting = other_value.serving__band__reporting();
} else {
single_value->field_serving__band__reporting.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new MeasParamsDesc_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new MeasParamsDesc_template(*other_value.implication_.precondition);
implication_.implied_template = new MeasParamsDesc_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.MeasParamsDesc.");
break;
}
set_selection(other_value);
}

MeasParamsDesc_template::MeasParamsDesc_template()
{
}

MeasParamsDesc_template::MeasParamsDesc_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

MeasParamsDesc_template::MeasParamsDesc_template(const MeasParamsDesc& other_value)
{
copy_value(other_value);
}

MeasParamsDesc_template::MeasParamsDesc_template(const OPTIONAL<MeasParamsDesc>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const MeasParamsDesc&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.MeasParamsDesc from an unbound optional field.");
}
}

MeasParamsDesc_template::MeasParamsDesc_template(MeasParamsDesc_template* p_precondition, MeasParamsDesc_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

MeasParamsDesc_template::MeasParamsDesc_template(Dynamic_Match_Interface<MeasParamsDesc>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<MeasParamsDesc>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

MeasParamsDesc_template::MeasParamsDesc_template(const MeasParamsDesc_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

MeasParamsDesc_template::~MeasParamsDesc_template()
{
clean_up();
}

MeasParamsDesc_template& MeasParamsDesc_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

MeasParamsDesc_template& MeasParamsDesc_template::operator=(const MeasParamsDesc& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

MeasParamsDesc_template& MeasParamsDesc_template::operator=(const OPTIONAL<MeasParamsDesc>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const MeasParamsDesc&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.MeasParamsDesc.");
}
return *this;
}

MeasParamsDesc_template& MeasParamsDesc_template::operator=(const MeasParamsDesc_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean MeasParamsDesc_template::match(const MeasParamsDesc& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.report__type().is_bound()) return FALSE;
if(!single_value->field_report__type.match(other_value.report__type(), legacy))return FALSE;
if(!other_value.serving__band__reporting().is_bound()) return FALSE;
if(!single_value->field_serving__band__reporting.match(other_value.serving__band__reporting(), legacy))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.MeasParamsDesc.");
}
return FALSE;
}

boolean MeasParamsDesc_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_report__type.is_bound()
 || single_value->field_serving__band__reporting.is_bound();
}

boolean MeasParamsDesc_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_report__type.is_value()
 && single_value->field_serving__band__reporting.is_value();
}

void MeasParamsDesc_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

MeasParamsDesc MeasParamsDesc_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.MeasParamsDesc.");
MeasParamsDesc ret_val;
if (single_value->field_report__type.is_bound()) {
ret_val.report__type() = single_value->field_report__type.valueof();
}
if (single_value->field_serving__band__reporting.is_bound()) {
ret_val.serving__band__reporting() = single_value->field_serving__band__reporting.valueof();
}
return ret_val;
}

void MeasParamsDesc_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.MeasParamsDesc.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new MeasParamsDesc_template[list_length];
}

MeasParamsDesc_template& MeasParamsDesc_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.MeasParamsDesc.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.MeasParamsDesc.");
return value_list.list_value[list_index];
}

BITSTRING_template& MeasParamsDesc_template::report__type()
{
set_specific();
return single_value->field_report__type;
}

const BITSTRING_template& MeasParamsDesc_template::report__type() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field report_type of a non-specific template of type @GSM_RestOctets.MeasParamsDesc.");
return single_value->field_report__type;
}

BITSTRING_template& MeasParamsDesc_template::serving__band__reporting()
{
set_specific();
return single_value->field_serving__band__reporting;
}

const BITSTRING_template& MeasParamsDesc_template::serving__band__reporting() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field serving_band_reporting of a non-specific template of type @GSM_RestOctets.MeasParamsDesc.");
return single_value->field_serving__band__reporting;
}

int MeasParamsDesc_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDesc which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
    return 2;
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDesc containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDesc containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDesc containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDesc containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDesc containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDesc containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDesc containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.MeasParamsDesc containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.MeasParamsDesc.");
  }
  return 0;
}

void MeasParamsDesc_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ report_type := ");
single_value->field_report__type.log();
TTCN_Logger::log_event_str(", serving_band_reporting := ");
single_value->field_serving__band__reporting.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void MeasParamsDesc_template::log_match(const MeasParamsDesc& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_report__type.match(match_value.report__type(), legacy)){
TTCN_Logger::log_logmatch_info(".report_type");
single_value->field_report__type.log_match(match_value.report__type(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if(!single_value->field_serving__band__reporting.match(match_value.serving__band__reporting(), legacy)){
TTCN_Logger::log_logmatch_info(".serving_band_reporting");
single_value->field_serving__band__reporting.log_match(match_value.serving__band__reporting(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ report_type := ");
single_value->field_report__type.log_match(match_value.report__type(), legacy);
TTCN_Logger::log_event_str(", serving_band_reporting := ");
single_value->field_serving__band__reporting.log_match(match_value.serving__band__reporting(), legacy);
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void MeasParamsDesc_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (report__type().is_bound()) report__type().set_implicit_omit();
if (serving__band__reporting().is_bound()) serving__band__reporting().set_implicit_omit();
}

void MeasParamsDesc_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_report__type.encode_text(text_buf);
single_value->field_serving__band__reporting.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.MeasParamsDesc.");
}
}

void MeasParamsDesc_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_report__type.decode_text(text_buf);
single_value->field_serving__band__reporting.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new MeasParamsDesc_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.MeasParamsDesc.");
}
}

void MeasParamsDesc_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    MeasParamsDesc_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.MeasParamsDesc has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) report__type().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) serving__band__reporting().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "report_type")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          report__type().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "serving_band_reporting")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          serving__band__reporting().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.MeasParamsDesc: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    MeasParamsDesc_template* precondition = new MeasParamsDesc_template;
    precondition->set_param(*param.get_elem(0));
    MeasParamsDesc_template* implied_template = new MeasParamsDesc_template;
    implied_template->set_param(*param.get_elem(1));
    *this = MeasParamsDesc_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.MeasParamsDesc");
  }
  is_ifpresent = param.get_ifpresent();
}

void MeasParamsDesc_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_report__type.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.MeasParamsDesc");
single_value->field_serving__band__reporting.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.MeasParamsDesc");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.MeasParamsDesc");
}

boolean MeasParamsDesc_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean MeasParamsDesc_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

GPRS__RealTimeDiffDescOpt::GPRS__RealTimeDiffDescOpt()
{
}

GPRS__RealTimeDiffDescOpt::GPRS__RealTimeDiffDescOpt(const BITSTRING& par_presence,
    const OPTIONAL< BITSTRING >& par_desc)
  :   field_presence(par_presence),
  field_desc(par_desc)
{
}

GPRS__RealTimeDiffDescOpt::GPRS__RealTimeDiffDescOpt(const GPRS__RealTimeDiffDescOpt& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
if (other_value.presence().is_bound()) field_presence = other_value.presence();
else field_presence.clean_up();
if (other_value.desc().is_bound()) field_desc = other_value.desc();
else field_desc.clean_up();
}

void GPRS__RealTimeDiffDescOpt::clean_up()
{
field_presence.clean_up();
field_desc.clean_up();
}

const TTCN_Typedescriptor_t* GPRS__RealTimeDiffDescOpt::get_descriptor() const { return &GPRS__RealTimeDiffDescOpt_descr_; }
GPRS__RealTimeDiffDescOpt& GPRS__RealTimeDiffDescOpt::operator=(const GPRS__RealTimeDiffDescOpt& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
  if (other_value.presence().is_bound()) field_presence = other_value.presence();
  else field_presence.clean_up();
  if (other_value.desc().is_bound()) field_desc = other_value.desc();
  else field_desc.clean_up();
}
return *this;
}

boolean GPRS__RealTimeDiffDescOpt::operator==(const GPRS__RealTimeDiffDescOpt& other_value) const
{
return field_presence==other_value.field_presence
  && field_desc==other_value.field_desc;
}

boolean GPRS__RealTimeDiffDescOpt::is_bound() const
{
return (field_presence.is_bound())
  || (OPTIONAL_OMIT == field_desc.get_selection() || field_desc.is_bound());
}
boolean GPRS__RealTimeDiffDescOpt::is_value() const
{
return field_presence.is_value()
  && (OPTIONAL_OMIT == field_desc.get_selection() || field_desc.is_value());
}
int GPRS__RealTimeDiffDescOpt::size_of() const
{
  int ret_val = 1;
  if (field_desc.ispresent()) ret_val++;
  return ret_val;
}

void GPRS__RealTimeDiffDescOpt::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ presence := ");
field_presence.log();
TTCN_Logger::log_event_str(", desc := ");
field_desc.log();
TTCN_Logger::log_event_str(" }");
}

void GPRS__RealTimeDiffDescOpt::set_implicit_omit()
{
if (presence().is_bound()) presence().set_implicit_omit();
if (!desc().is_bound()) desc() = OMIT_VALUE;
else desc().set_implicit_omit();
}

void GPRS__RealTimeDiffDescOpt::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) desc().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "desc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          desc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.GPRS_RealTimeDiffDescOpt");
  }
}

void GPRS__RealTimeDiffDescOpt::encode_text(Text_Buf& text_buf) const
{
field_presence.encode_text(text_buf);
field_desc.encode_text(text_buf);
}

void GPRS__RealTimeDiffDescOpt::decode_text(Text_Buf& text_buf)
{
field_presence.decode_text(text_buf);
field_desc.decode_text(text_buf);
}

void GPRS__RealTimeDiffDescOpt::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void GPRS__RealTimeDiffDescOpt::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int GPRS__RealTimeDiffDescOpt::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, GPRS__RealTimeDiffDescOpt_presence_descr_.raw->forceomit);
  decoded_field_length = field_presence.RAW_decode(GPRS__RealTimeDiffDescOpt_presence_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_presence ==  bs_0){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_desc = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, GPRS__RealTimeDiffDescOpt_desc_descr_.raw->forceomit);
  decoded_field_length = field_desc().RAW_decode(GPRS__RealTimeDiffDescOpt_desc_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_desc = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_desc=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int GPRS__RealTimeDiffDescOpt::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 2;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(2);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, GPRS__RealTimeDiffDescOpt_presence_descr_.raw);
  if (field_desc.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, GPRS__RealTimeDiffDescOpt_desc_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  encoded_length += field_presence.RAW_encode(GPRS__RealTimeDiffDescOpt_presence_descr_, *myleaf.body.node.nodes[0]);
  if (field_desc.ispresent()) {
  encoded_length += field_desc().RAW_encode(GPRS__RealTimeDiffDescOpt_desc_descr_, *myleaf.body.node.nodes[1]);
  }
  if (field_desc.ispresent() && (field_presence !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(GPRS__RealTimeDiffDescOpt_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct GPRS__RealTimeDiffDescOpt_template::single_value_struct {
BITSTRING_template field_presence;
BITSTRING_template field_desc;
};

void GPRS__RealTimeDiffDescOpt_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_presence = ANY_VALUE;
single_value->field_desc = ANY_OR_OMIT;
}
}
}

void GPRS__RealTimeDiffDescOpt_template::copy_value(const GPRS__RealTimeDiffDescOpt& other_value)
{
single_value = new single_value_struct;
if (other_value.presence().is_bound()) {
  single_value->field_presence = other_value.presence();
} else {
  single_value->field_presence.clean_up();
}
if (other_value.desc().is_bound()) {
  if (other_value.desc().ispresent()) single_value->field_desc = other_value.desc()();
  else single_value->field_desc = OMIT_VALUE;
} else {
  single_value->field_desc.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void GPRS__RealTimeDiffDescOpt_template::copy_template(const GPRS__RealTimeDiffDescOpt_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.presence().get_selection()) {
single_value->field_presence = other_value.presence();
} else {
single_value->field_presence.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.desc().get_selection()) {
single_value->field_desc = other_value.desc();
} else {
single_value->field_desc.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new GPRS__RealTimeDiffDescOpt_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new GPRS__RealTimeDiffDescOpt_template(*other_value.implication_.precondition);
implication_.implied_template = new GPRS__RealTimeDiffDescOpt_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
break;
}
set_selection(other_value);
}

GPRS__RealTimeDiffDescOpt_template::GPRS__RealTimeDiffDescOpt_template()
{
}

GPRS__RealTimeDiffDescOpt_template::GPRS__RealTimeDiffDescOpt_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

GPRS__RealTimeDiffDescOpt_template::GPRS__RealTimeDiffDescOpt_template(const GPRS__RealTimeDiffDescOpt& other_value)
{
copy_value(other_value);
}

GPRS__RealTimeDiffDescOpt_template::GPRS__RealTimeDiffDescOpt_template(const OPTIONAL<GPRS__RealTimeDiffDescOpt>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const GPRS__RealTimeDiffDescOpt&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt from an unbound optional field.");
}
}

GPRS__RealTimeDiffDescOpt_template::GPRS__RealTimeDiffDescOpt_template(GPRS__RealTimeDiffDescOpt_template* p_precondition, GPRS__RealTimeDiffDescOpt_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

GPRS__RealTimeDiffDescOpt_template::GPRS__RealTimeDiffDescOpt_template(Dynamic_Match_Interface<GPRS__RealTimeDiffDescOpt>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<GPRS__RealTimeDiffDescOpt>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

GPRS__RealTimeDiffDescOpt_template::GPRS__RealTimeDiffDescOpt_template(const GPRS__RealTimeDiffDescOpt_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

GPRS__RealTimeDiffDescOpt_template::~GPRS__RealTimeDiffDescOpt_template()
{
clean_up();
}

GPRS__RealTimeDiffDescOpt_template& GPRS__RealTimeDiffDescOpt_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

GPRS__RealTimeDiffDescOpt_template& GPRS__RealTimeDiffDescOpt_template::operator=(const GPRS__RealTimeDiffDescOpt& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

GPRS__RealTimeDiffDescOpt_template& GPRS__RealTimeDiffDescOpt_template::operator=(const OPTIONAL<GPRS__RealTimeDiffDescOpt>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const GPRS__RealTimeDiffDescOpt&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
}
return *this;
}

GPRS__RealTimeDiffDescOpt_template& GPRS__RealTimeDiffDescOpt_template::operator=(const GPRS__RealTimeDiffDescOpt_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean GPRS__RealTimeDiffDescOpt_template::match(const GPRS__RealTimeDiffDescOpt& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.presence().is_bound()) return FALSE;
if(!single_value->field_presence.match(other_value.presence(), legacy))return FALSE;
if(!other_value.desc().is_bound()) return FALSE;
if((other_value.desc().ispresent() ? !single_value->field_desc.match((const BITSTRING&)other_value.desc(), legacy) : !single_value->field_desc.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
}
return FALSE;
}

boolean GPRS__RealTimeDiffDescOpt_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_presence.is_bound()
 || (single_value->field_desc.is_omit() || single_value->field_desc.is_bound());
}

boolean GPRS__RealTimeDiffDescOpt_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_presence.is_value()
 && (single_value->field_desc.is_omit() || single_value->field_desc.is_value());
}

void GPRS__RealTimeDiffDescOpt_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

GPRS__RealTimeDiffDescOpt GPRS__RealTimeDiffDescOpt_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
GPRS__RealTimeDiffDescOpt ret_val;
if (single_value->field_presence.is_bound()) {
ret_val.presence() = single_value->field_presence.valueof();
}
if (single_value->field_desc.is_omit()) ret_val.desc() = OMIT_VALUE;
else if (single_value->field_desc.is_bound()) {
ret_val.desc() = single_value->field_desc.valueof();
}
return ret_val;
}

void GPRS__RealTimeDiffDescOpt_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new GPRS__RealTimeDiffDescOpt_template[list_length];
}

GPRS__RealTimeDiffDescOpt_template& GPRS__RealTimeDiffDescOpt_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
return value_list.list_value[list_index];
}

BITSTRING_template& GPRS__RealTimeDiffDescOpt_template::presence()
{
set_specific();
return single_value->field_presence;
}

const BITSTRING_template& GPRS__RealTimeDiffDescOpt_template::presence() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field presence of a non-specific template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
return single_value->field_presence;
}

BITSTRING_template& GPRS__RealTimeDiffDescOpt_template::desc()
{
set_specific();
return single_value->field_desc;
}

const BITSTRING_template& GPRS__RealTimeDiffDescOpt_template::desc() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field desc of a non-specific template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
return single_value->field_desc;
}

int GPRS__RealTimeDiffDescOpt_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 1;
      if (single_value->field_desc.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
  }
  return 0;
}

void GPRS__RealTimeDiffDescOpt_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log();
TTCN_Logger::log_event_str(", desc := ");
single_value->field_desc.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void GPRS__RealTimeDiffDescOpt_template::log_match(const GPRS__RealTimeDiffDescOpt& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_presence.match(match_value.presence(), legacy)){
TTCN_Logger::log_logmatch_info(".presence");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.desc().ispresent()){
if(!single_value->field_desc.match(match_value.desc(), legacy)){
TTCN_Logger::log_logmatch_info(".desc");
single_value->field_desc.log_match(match_value.desc(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_desc.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".desc := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_desc.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::log_event_str(", desc := ");
if (match_value.desc().ispresent()) {
single_value->field_desc.log_match(match_value.desc(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_desc.log();
if (single_value->field_desc.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void GPRS__RealTimeDiffDescOpt_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (presence().is_bound()) presence().set_implicit_omit();
if (!desc().is_bound()) desc() = OMIT_VALUE;
else desc().set_implicit_omit();
}

void GPRS__RealTimeDiffDescOpt_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_presence.encode_text(text_buf);
single_value->field_desc.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
}
}

void GPRS__RealTimeDiffDescOpt_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_presence.decode_text(text_buf);
single_value->field_desc.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new GPRS__RealTimeDiffDescOpt_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt.");
}
}

void GPRS__RealTimeDiffDescOpt_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    GPRS__RealTimeDiffDescOpt_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) desc().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "desc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          desc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.GPRS_RealTimeDiffDescOpt: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    GPRS__RealTimeDiffDescOpt_template* precondition = new GPRS__RealTimeDiffDescOpt_template;
    precondition->set_param(*param.get_elem(0));
    GPRS__RealTimeDiffDescOpt_template* implied_template = new GPRS__RealTimeDiffDescOpt_template;
    implied_template->set_param(*param.get_elem(1));
    *this = GPRS__RealTimeDiffDescOpt_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.GPRS_RealTimeDiffDescOpt");
  }
  is_ifpresent = param.get_ifpresent();
}

void GPRS__RealTimeDiffDescOpt_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_presence.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.GPRS_RealTimeDiffDescOpt");
single_value->field_desc.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.GPRS_RealTimeDiffDescOpt");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.GPRS_RealTimeDiffDescOpt");
}

boolean GPRS__RealTimeDiffDescOpt_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean GPRS__RealTimeDiffDescOpt_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}

GPRS__BSICDescOpt::GPRS__BSICDescOpt()
{
}

GPRS__BSICDescOpt::GPRS__BSICDescOpt(const BITSTRING& par_presence,
    const OPTIONAL< BITSTRING >& par_desc)
  :   field_presence(par_presence),
  field_desc(par_desc)
{
}

GPRS__BSICDescOpt::GPRS__BSICDescOpt(const GPRS__BSICDescOpt& other_value)
{
if(!other_value.is_bound()) TTCN_error("Copying an unbound value of type @GSM_RestOctets.GPRS_BSICDescOpt.");
if (other_value.presence().is_bound()) field_presence = other_value.presence();
else field_presence.clean_up();
if (other_value.desc().is_bound()) field_desc = other_value.desc();
else field_desc.clean_up();
}

void GPRS__BSICDescOpt::clean_up()
{
field_presence.clean_up();
field_desc.clean_up();
}

const TTCN_Typedescriptor_t* GPRS__BSICDescOpt::get_descriptor() const { return &GPRS__BSICDescOpt_descr_; }
GPRS__BSICDescOpt& GPRS__BSICDescOpt::operator=(const GPRS__BSICDescOpt& other_value)
{
if (this != &other_value) {
  if(!other_value.is_bound()) TTCN_error("Assignment of an unbound value of type @GSM_RestOctets.GPRS_BSICDescOpt.");
  if (other_value.presence().is_bound()) field_presence = other_value.presence();
  else field_presence.clean_up();
  if (other_value.desc().is_bound()) field_desc = other_value.desc();
  else field_desc.clean_up();
}
return *this;
}

boolean GPRS__BSICDescOpt::operator==(const GPRS__BSICDescOpt& other_value) const
{
return field_presence==other_value.field_presence
  && field_desc==other_value.field_desc;
}

boolean GPRS__BSICDescOpt::is_bound() const
{
return (field_presence.is_bound())
  || (OPTIONAL_OMIT == field_desc.get_selection() || field_desc.is_bound());
}
boolean GPRS__BSICDescOpt::is_value() const
{
return field_presence.is_value()
  && (OPTIONAL_OMIT == field_desc.get_selection() || field_desc.is_value());
}
int GPRS__BSICDescOpt::size_of() const
{
  int ret_val = 1;
  if (field_desc.ispresent()) ret_val++;
  return ret_val;
}

void GPRS__BSICDescOpt::log() const
{
if (!is_bound()) {
TTCN_Logger::log_event_unbound();
return;
}
TTCN_Logger::log_event_str("{ presence := ");
field_presence.log();
TTCN_Logger::log_event_str(", desc := ");
field_desc.log();
TTCN_Logger::log_event_str(" }");
}

void GPRS__BSICDescOpt::set_implicit_omit()
{
if (presence().is_bound()) presence().set_implicit_omit();
if (!desc().is_bound()) desc() = OMIT_VALUE;
else desc().set_implicit_omit();
}

void GPRS__BSICDescOpt::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "record value");
  switch (param.get_type()) {
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record value of type @GSM_RestOctets.GPRS_BSICDescOpt has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) desc().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "desc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          desc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.GPRS_BSICDescOpt: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  default:
    param.type_error("record value", "@GSM_RestOctets.GPRS_BSICDescOpt");
  }
}

void GPRS__BSICDescOpt::encode_text(Text_Buf& text_buf) const
{
field_presence.encode_text(text_buf);
field_desc.encode_text(text_buf);
}

void GPRS__BSICDescOpt::decode_text(Text_Buf& text_buf)
{
field_presence.decode_text(text_buf);
field_desc.decode_text(text_buf);
}

void GPRS__BSICDescOpt::encode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...) const
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-encoding type '%s': ", p_td.name);
    unsigned BER_coding=va_arg(pvar, unsigned);
    BER_encode_chk_coding(BER_coding);
    ASN_BER_TLV_t *tlv=BER_encode_TLV(p_td, BER_coding);
    tlv->put_in_buffer(p_buf);
    ASN_BER_TLV_t::destruct(tlv);
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-encoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    RAW_enc_tr_pos rp;
    rp.level=0;
    rp.pos=NULL;
    RAW_enc_tree root(FALSE, NULL, &rp, 1, p_td.raw);
    RAW_encode(p_td, root);
    root.put_to_buf(p_buf);
    break;}
  case TTCN_EncDec::CT_TEXT: {
    TTCN_EncDec_ErrorContext ec("While TEXT-encoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
      ("No TEXT descriptor available for type '%s'.", p_td.name);
    TEXT_encode(p_td,p_buf);
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-encoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XER_encode(*(p_td.xer),p_buf, XER_coding, 0, 0, 0);
    p_buf.put_c('\n');
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-encoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok(va_arg(pvar, int) != 0);
    JSON_encode(p_td, tok, FALSE);
    p_buf.put_s(tok.get_buffer_length(), (const unsigned char*)tok.get_buffer());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-encoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
    OER_encode(p_td, p_buf);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-encoding type '%s': ", p_td.name);
    if (!p_td.per) TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    PER_encode(p_td, p_buf, opt);
    break; }
  default:
    TTCN_error("Unknown coding method requested to encode type '%s'", p_td.name);
  }
  va_end(pvar);
}

void GPRS__BSICDescOpt::decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int p_coding, ...)
{
  va_list pvar;
  va_start(pvar, p_coding);
  switch(p_coding) {
  case TTCN_EncDec::CT_BER: {
    TTCN_EncDec_ErrorContext ec("While BER-decoding type '%s': ", p_td.name);
    unsigned L_form=va_arg(pvar, unsigned);
    ASN_BER_TLV_t tlv;
    BER_decode_str2TLV(p_buf, tlv, L_form);
    BER_decode_TLV(p_td, tlv, L_form);
    if(tlv.isComplete) p_buf.increase_pos(tlv.get_len());
    break;}
  case TTCN_EncDec::CT_RAW: {
    TTCN_EncDec_ErrorContext ec("While RAW-decoding type '%s': ", p_td.name);
    if(!p_td.raw)
      TTCN_EncDec_ErrorContext::error_internal
        ("No RAW descriptor available for type '%s'.", p_td.name);
    raw_order_t r_order;
    switch(p_td.raw->top_bit_order) {
    case TOP_BIT_LEFT:
      r_order=ORDER_LSB;
      break;
    case TOP_BIT_RIGHT:
    default:
      r_order=ORDER_MSB;
    }
    int rawr = RAW_decode(p_td, p_buf, p_buf.get_len()*8, r_order);
    if(rawr<0) switch (-rawr) {
    case TTCN_EncDec::ET_INCOMPL_MSG:
    case TTCN_EncDec::ET_LEN_ERR:
      ec.error((TTCN_EncDec::error_type_t)-rawr, "Can not decode type '%s', because incomplete message was received", p_td.name);
      break;
    case 1:
    default:
      ec.error(TTCN_EncDec::ET_INVAL_MSG, "Can not decode type '%s', because invalid message was received", p_td.name);
      break;
    }
    break;}
  case TTCN_EncDec::CT_TEXT: {
    Limit_Token_List limit;
    TTCN_EncDec_ErrorContext ec("While TEXT-decoding type '%s': ", p_td.name);
    if(!p_td.text)
      TTCN_EncDec_ErrorContext::error_internal
        ("No TEXT descriptor available for type '%s'.", p_td.name);
    const unsigned char *b_data=p_buf.get_data();
    int null_added=0;
    if(b_data[p_buf.get_len()-1]!='\0'){
      null_added=1;
      p_buf.set_pos(p_buf.get_len());
      p_buf.put_zero(8,ORDER_LSB);
      p_buf.rewind();
    }
    if(TEXT_decode(p_td,p_buf,limit)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    if(null_added){
      size_t actpos=p_buf.get_pos();
      p_buf.set_pos(p_buf.get_len()-1);
      p_buf.cut_end();
      p_buf.set_pos(actpos);
    }
    break;}
  case TTCN_EncDec::CT_XER: {
    TTCN_EncDec_ErrorContext ec("While XER-decoding type '%s': ", p_td.name);
    unsigned XER_coding=va_arg(pvar, unsigned);
    XER_encode_chk_coding(XER_coding, p_td);
    XmlReaderWrap reader(p_buf);
    for (int rd_ok=reader.Read(); rd_ok==1; rd_ok=reader.Read()) {
      if (reader.NodeType() == XML_READER_TYPE_ELEMENT) break;
    }
    XER_decode(*(p_td.xer), reader, XER_coding | XER_TOPLEVEL, XER_NONE, 0);
    size_t bytes = reader.ByteConsumed();
    p_buf.set_pos(bytes);
    break;}
  case TTCN_EncDec::CT_JSON: {
    TTCN_EncDec_ErrorContext ec("While JSON-decoding type '%s': ", p_td.name);
    if(!p_td.json)
      TTCN_EncDec_ErrorContext::error_internal
        ("No JSON descriptor available for type '%s'.", p_td.name);
    JSON_Tokenizer tok((const char*)p_buf.get_data(), p_buf.get_len());
    if(JSON_decode(p_td, tok, FALSE, FALSE)<0)
      ec.error(TTCN_EncDec::ET_INCOMPL_MSG,"Can not decode type '%s', because invalid or incomplete message was received", p_td.name);
    p_buf.set_pos(tok.get_buf_pos());
    break;}
  case TTCN_EncDec::CT_OER: {
    TTCN_EncDec_ErrorContext ec("While OER-decoding type '%s': ", p_td.name);
    if(!p_td.oer)
      TTCN_EncDec_ErrorContext::error_internal
        ("No OER descriptor available for type '%s'.", p_td.name);
     OER_struct p_oer;
    OER_decode(p_td, p_buf, p_oer);
    break;}
  case TTCN_EncDec::CT_PER: {
    TTCN_EncDec_ErrorContext ec("While PER-decoding type '%s': ", p_td.name);
    if(!p_td.per)  TTCN_EncDec_ErrorContext::error_internal(
      "No PER descriptor available for type '%s'.", p_td.name);
    int opt = va_arg(pvar, int);
    try {
      PER_decode(p_td, p_buf, opt);
      p_buf.PER_octet_align(FALSE);
    }
    catch (PER_Buffer_Exception) { }
    break; }
  default:
    TTCN_error("Unknown coding method requested to decode type '%s'", p_td.name);
  }
  va_end(pvar);
}

int GPRS__BSICDescOpt::RAW_decode(const TTCN_Typedescriptor_t& p_td, TTCN_Buffer& p_buf, int limit, raw_order_t top_bit_ord, boolean no_err, int, boolean, const RAW_Force_Omit* force_omit)
{ (void)no_err;
  int prepaddlength=p_buf.increase_pos_padd(p_td.raw->prepadding);
  limit-=prepaddlength;
  size_t last_decoded_pos = p_buf.get_pos_bit();
  int decoded_length = 0;
  int decoded_field_length = 0;
  raw_order_t local_top_order;
  if(p_td.raw->top_bit_order==TOP_BIT_INHERITED)local_top_order=top_bit_ord;
  else if(p_td.raw->top_bit_order==TOP_BIT_RIGHT)local_top_order=ORDER_MSB;
  else local_top_order=ORDER_LSB;
  RAW_Force_Omit field_0_force_omit(0, force_omit, GPRS__BSICDescOpt_presence_descr_.raw->forceomit);
  decoded_field_length = field_presence.RAW_decode(GPRS__BSICDescOpt_presence_descr_, p_buf, limit, local_top_order, no_err, -1, TRUE, &field_0_force_omit);
  if (decoded_field_length < 0) return decoded_field_length;
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  if (limit > 0 && field_presence ==  bs_0){
  if (force_omit != NULL && (*force_omit)(1)) {
    field_desc = OMIT_VALUE;
  }
  else {
  size_t fl_start_pos = p_buf.get_pos_bit();
  RAW_Force_Omit field_1_force_omit(1, force_omit, GPRS__BSICDescOpt_desc_descr_.raw->forceomit);
  decoded_field_length = field_desc().RAW_decode(GPRS__BSICDescOpt_desc_descr_, p_buf, limit, local_top_order, TRUE, -1, TRUE, &field_1_force_omit);
  if (decoded_field_length < 1) {
  field_desc = OMIT_VALUE;
  p_buf.set_pos_bit(fl_start_pos);
  } else {
  decoded_length+=decoded_field_length;
  limit-=decoded_field_length;
  last_decoded_pos=bigger(last_decoded_pos, p_buf.get_pos_bit());
  }
  }
  }
  else field_desc=OMIT_VALUE;
  p_buf.set_pos_bit(last_decoded_pos);
  return decoded_length+prepaddlength+p_buf.increase_pos_padd(p_td.raw->padding);
}

int GPRS__BSICDescOpt::RAW_encode(const TTCN_Typedescriptor_t&, RAW_enc_tree& myleaf) const {
  if (!is_bound()) TTCN_EncDec_ErrorContext::error(TTCN_EncDec::ET_UNBOUND, "Encoding an unbound value.");
  int encoded_length = 0;
  myleaf.isleaf = FALSE;
  myleaf.body.node.num_of_nodes = 2;
  myleaf.body.node.nodes = init_nodes_of_enc_tree(2);
  myleaf.body.node.nodes[0] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 0, GPRS__BSICDescOpt_presence_descr_.raw);
  if (field_desc.ispresent()) {
  myleaf.body.node.nodes[1] = new RAW_enc_tree(TRUE, &myleaf, &(myleaf.curr_pos), 1, GPRS__BSICDescOpt_desc_descr_.raw);
  }
  else myleaf.body.node.nodes[1] = NULL;
  encoded_length += field_presence.RAW_encode(GPRS__BSICDescOpt_presence_descr_, *myleaf.body.node.nodes[0]);
  if (field_desc.ispresent()) {
  encoded_length += field_desc().RAW_encode(GPRS__BSICDescOpt_desc_descr_, *myleaf.body.node.nodes[1]);
  }
  if (field_desc.ispresent() && (field_presence !=  bs_0)) {
  RAW_enc_tree* temp_leaf;
  {
  RAW_enc_tr_pos pr_pos0;
  pr_pos0.level=myleaf.curr_pos.level+1;
  int new_pos0[]={0};
  pr_pos0.pos=init_new_tree_pos(myleaf.curr_pos,1,new_pos0);
  temp_leaf = myleaf.get_node(pr_pos0);
  if(temp_leaf != NULL){
   bs_0.RAW_encode(GPRS__BSICDescOpt_presence_descr_,*temp_leaf);
  } else {
    TTCN_EncDec_ErrorContext::error
      (TTCN_EncDec::ET_OMITTED_TAG, "Encoding a tagged, but omitted value.");
  }
  free_tree_pos(pr_pos0.pos);
  }
  }
  return myleaf.length = encoded_length;
}

struct GPRS__BSICDescOpt_template::single_value_struct {
BITSTRING_template field_presence;
BITSTRING_template field_desc;
};

void GPRS__BSICDescOpt_template::set_specific()
{
if (template_selection != SPECIFIC_VALUE) {
template_sel old_selection = template_selection;
clean_up();
single_value = new single_value_struct;
set_selection(SPECIFIC_VALUE);
if (old_selection == ANY_VALUE || old_selection == ANY_OR_OMIT) {
single_value->field_presence = ANY_VALUE;
single_value->field_desc = ANY_OR_OMIT;
}
}
}

void GPRS__BSICDescOpt_template::copy_value(const GPRS__BSICDescOpt& other_value)
{
single_value = new single_value_struct;
if (other_value.presence().is_bound()) {
  single_value->field_presence = other_value.presence();
} else {
  single_value->field_presence.clean_up();
}
if (other_value.desc().is_bound()) {
  if (other_value.desc().ispresent()) single_value->field_desc = other_value.desc()();
  else single_value->field_desc = OMIT_VALUE;
} else {
  single_value->field_desc.clean_up();
}
set_selection(SPECIFIC_VALUE);
}

void GPRS__BSICDescOpt_template::copy_template(const GPRS__BSICDescOpt_template& other_value)
{
switch (other_value.template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
if (UNINITIALIZED_TEMPLATE != other_value.presence().get_selection()) {
single_value->field_presence = other_value.presence();
} else {
single_value->field_presence.clean_up();
}
if (UNINITIALIZED_TEMPLATE != other_value.desc().get_selection()) {
single_value->field_desc = other_value.desc();
} else {
single_value->field_desc.clean_up();
}
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
value_list.n_values = other_value.value_list.n_values;
value_list.list_value = new GPRS__BSICDescOpt_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].copy_template(other_value.value_list.list_value[list_count]);
break;
case IMPLICATION_MATCH:
implication_.precondition = new GPRS__BSICDescOpt_template(*other_value.implication_.precondition);
implication_.implied_template = new GPRS__BSICDescOpt_template(*other_value.implication_.implied_template);
break;
case DYNAMIC_MATCH:
dyn_match = other_value.dyn_match;
dyn_match->ref_count++;
break;
default:
TTCN_error("Copying an uninitialized/unsupported template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
break;
}
set_selection(other_value);
}

GPRS__BSICDescOpt_template::GPRS__BSICDescOpt_template()
{
}

GPRS__BSICDescOpt_template::GPRS__BSICDescOpt_template(template_sel other_value)
 : Base_Template(other_value)
{
check_single_selection(other_value);
}

GPRS__BSICDescOpt_template::GPRS__BSICDescOpt_template(const GPRS__BSICDescOpt& other_value)
{
copy_value(other_value);
}

GPRS__BSICDescOpt_template::GPRS__BSICDescOpt_template(const OPTIONAL<GPRS__BSICDescOpt>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const GPRS__BSICDescOpt&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of type @GSM_RestOctets.GPRS_BSICDescOpt from an unbound optional field.");
}
}

GPRS__BSICDescOpt_template::GPRS__BSICDescOpt_template(GPRS__BSICDescOpt_template* p_precondition, GPRS__BSICDescOpt_template* p_implied_template)
 : Base_Template(IMPLICATION_MATCH)
{
implication_.precondition = p_precondition;
implication_.implied_template = p_implied_template;
}

GPRS__BSICDescOpt_template::GPRS__BSICDescOpt_template(Dynamic_Match_Interface<GPRS__BSICDescOpt>* p_dyn_match)
 : Base_Template(DYNAMIC_MATCH)
{
dyn_match = new dynmatch_struct<GPRS__BSICDescOpt>;
dyn_match->ptr = p_dyn_match;
dyn_match->ref_count = 1;
}

GPRS__BSICDescOpt_template::GPRS__BSICDescOpt_template(const GPRS__BSICDescOpt_template& other_value)
: Base_Template()
{
copy_template(other_value);
}

GPRS__BSICDescOpt_template::~GPRS__BSICDescOpt_template()
{
clean_up();
}

GPRS__BSICDescOpt_template& GPRS__BSICDescOpt_template::operator=(template_sel other_value)
{
check_single_selection(other_value);
clean_up();
set_selection(other_value);
return *this;
}

GPRS__BSICDescOpt_template& GPRS__BSICDescOpt_template::operator=(const GPRS__BSICDescOpt& other_value)
{
clean_up();
copy_value(other_value);
return *this;
}

GPRS__BSICDescOpt_template& GPRS__BSICDescOpt_template::operator=(const OPTIONAL<GPRS__BSICDescOpt>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
copy_value((const GPRS__BSICDescOpt&)other_value);
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
}
return *this;
}

GPRS__BSICDescOpt_template& GPRS__BSICDescOpt_template::operator=(const GPRS__BSICDescOpt_template& other_value)
{
if (&other_value != this) {
clean_up();
copy_template(other_value);
}
return *this;
}

boolean GPRS__BSICDescOpt_template::match(const GPRS__BSICDescOpt& other_value, boolean legacy) const
{
if (!other_value.is_bound()) return FALSE;
switch (template_selection) {
case ANY_VALUE:
case ANY_OR_OMIT:
return TRUE;
case OMIT_VALUE:
return FALSE;
case SPECIFIC_VALUE:
if(!other_value.presence().is_bound()) return FALSE;
if(!single_value->field_presence.match(other_value.presence(), legacy))return FALSE;
if(!other_value.desc().is_bound()) return FALSE;
if((other_value.desc().ispresent() ? !single_value->field_desc.match((const BITSTRING&)other_value.desc(), legacy) : !single_value->field_desc.match_omit(legacy)))return FALSE;
return TRUE;
case VALUE_LIST:
case COMPLEMENTED_LIST:
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
if (value_list.list_value[list_count].match(other_value, legacy)) return template_selection == VALUE_LIST;
return template_selection == COMPLEMENTED_LIST;
case CONJUNCTION_MATCH:
for (unsigned int i = 0; i < value_list.n_values; i++) {
if (!value_list.list_value[i].match(other_value)) {
return FALSE;
}
}
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match(other_value) || implication_.implied_template->match(other_value);
case DYNAMIC_MATCH:
return dyn_match->ptr->match(other_value);
default:
TTCN_error("Matching an uninitialized/unsupported template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
}
return FALSE;
}

boolean GPRS__BSICDescOpt_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
if (template_selection != SPECIFIC_VALUE) return TRUE;
return single_value->field_presence.is_bound()
 || (single_value->field_desc.is_omit() || single_value->field_desc.is_bound());
}

boolean GPRS__BSICDescOpt_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value->field_presence.is_value()
 && (single_value->field_desc.is_omit() || single_value->field_desc.is_value());
}

void GPRS__BSICDescOpt_template::clean_up()
{
switch (template_selection) {
case SPECIFIC_VALUE:
delete single_value;
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
case CONJUNCTION_MATCH:
delete [] value_list.list_value;
break;
case IMPLICATION_MATCH:
delete implication_.precondition;
delete implication_.implied_template;
break;
case DYNAMIC_MATCH:
dyn_match->ref_count--;
if (dyn_match->ref_count == 0) {
delete dyn_match->ptr;
delete dyn_match;
}
break;
default:
break;
}
template_selection = UNINITIALIZED_TEMPLATE;
}

GPRS__BSICDescOpt GPRS__BSICDescOpt_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent)
TTCN_error("Performing a valueof or send operation on a non-specific template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
GPRS__BSICDescOpt ret_val;
if (single_value->field_presence.is_bound()) {
ret_val.presence() = single_value->field_presence.valueof();
}
if (single_value->field_desc.is_omit()) ret_val.desc() = OMIT_VALUE;
else if (single_value->field_desc.is_bound()) {
ret_val.desc() = single_value->field_desc.valueof();
}
return ret_val;
}

void GPRS__BSICDescOpt_template::set_type(template_sel template_type, unsigned int list_length)
{
if (template_type != VALUE_LIST && template_type != COMPLEMENTED_LIST&& template_type != CONJUNCTION_MATCH)
TTCN_error("Setting an invalid list for a template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
clean_up();
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new GPRS__BSICDescOpt_template[list_length];
}

GPRS__BSICDescOpt_template& GPRS__BSICDescOpt_template::list_item(unsigned int list_index) const
{
if (template_selection != VALUE_LIST && template_selection != COMPLEMENTED_LIST&& template_selection != CONJUNCTION_MATCH)
TTCN_error("Accessing a list element of a non-list template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
if (list_index >= value_list.n_values)
TTCN_error("Index overflow in a value list template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
return value_list.list_value[list_index];
}

BITSTRING_template& GPRS__BSICDescOpt_template::presence()
{
set_specific();
return single_value->field_presence;
}

const BITSTRING_template& GPRS__BSICDescOpt_template::presence() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field presence of a non-specific template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
return single_value->field_presence;
}

BITSTRING_template& GPRS__BSICDescOpt_template::desc()
{
set_specific();
return single_value->field_desc;
}

const BITSTRING_template& GPRS__BSICDescOpt_template::desc() const
{
if (template_selection != SPECIFIC_VALUE)
TTCN_error("Accessing field desc of a non-specific template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
return single_value->field_desc;
}

int GPRS__BSICDescOpt_template::size_of() const
{
  if (is_ifpresent) TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_BSICDescOpt which has an ifpresent attribute.");
  switch (template_selection)
  {
  case SPECIFIC_VALUE:
  {    int ret_val = 1;
      if (single_value->field_desc.is_present()) ret_val++;
      return ret_val;
    }
  case VALUE_LIST:
   {
     if (value_list.n_values<1)
       TTCN_error("Internal error: Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_BSICDescOpt containing an empty list.");
      int item_size = value_list.list_value[0].size_of();
      for (unsigned int l_idx = 1; l_idx < value_list.n_values; l_idx++)
      {
        if (value_list.list_value[l_idx].size_of()!=item_size)
          TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_BSICDescOpt containing a value list with different sizes.");
      }
      return item_size;
    }
  case OMIT_VALUE:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_BSICDescOpt containing omit value.");
  case ANY_VALUE:
  case ANY_OR_OMIT:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_BSICDescOpt containing */? value.");
  case COMPLEMENTED_LIST:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_BSICDescOpt containing complemented list.");
  case CONJUNCTION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_BSICDescOpt containing a conjunction list match.");
  case IMPLICATION_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_BSICDescOpt containing an implication match.");
  case DYNAMIC_MATCH:
    TTCN_error("Performing sizeof() operation on a template of type @GSM_RestOctets.GPRS_BSICDescOpt containing a dynamic match.");
  default:
    TTCN_error("Performing sizeof() operation on an uninitialized/unsupported template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
  }
  return 0;
}

void GPRS__BSICDescOpt_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log();
TTCN_Logger::log_event_str(", desc := ");
single_value->field_desc.log();
TTCN_Logger::log_event_str(" }");
break;
case COMPLEMENTED_LIST:
TTCN_Logger::log_event_str("complement");
case CONJUNCTION_MATCH:
if (template_selection == CONJUNCTION_MATCH) {
TTCN_Logger::log_event_str("conjunct");
}
case VALUE_LIST:
TTCN_Logger::log_char('(');
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++) {
if (list_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[list_count].log();
}
TTCN_Logger::log_char(')');
break;
case IMPLICATION_MATCH:
implication_.precondition->log();
TTCN_Logger::log_event_str(" implies ");
implication_.implied_template->log();
break;
case DYNAMIC_MATCH:
TTCN_Logger::log_event_str("@dynamic template");
break;
default:
log_generic();
}
log_ifpresent();
}

void GPRS__BSICDescOpt_template::log_match(const GPRS__BSICDescOpt& match_value, boolean legacy) const
{
if(TTCN_Logger::VERBOSITY_COMPACT == TTCN_Logger::get_matching_verbosity()){
if(match(match_value, legacy)){
TTCN_Logger::print_logmatch_buffer();
TTCN_Logger::log_event_str(" matched");
} else{
if (template_selection == SPECIFIC_VALUE) {
size_t previous_size = TTCN_Logger::get_logmatch_buffer_len();
if(!single_value->field_presence.match(match_value.presence(), legacy)){
TTCN_Logger::log_logmatch_info(".presence");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
if (match_value.desc().ispresent()){
if(!single_value->field_desc.match(match_value.desc(), legacy)){
TTCN_Logger::log_logmatch_info(".desc");
single_value->field_desc.log_match(match_value.desc(), legacy);
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
} else {
if (!single_value->field_desc.match_omit(legacy)){
 TTCN_Logger::log_logmatch_info(".desc := omit with ");
TTCN_Logger::print_logmatch_buffer();
single_value->field_desc.log();
TTCN_Logger::log_event_str(" unmatched");
TTCN_Logger::set_logmatch_buffer_len(previous_size);
}
}
}else {
TTCN_Logger::print_logmatch_buffer();
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
TTCN_Logger::log_event_str(" unmatched");
}
}
return;
}
if (template_selection == SPECIFIC_VALUE) {
TTCN_Logger::log_event_str("{ presence := ");
single_value->field_presence.log_match(match_value.presence(), legacy);
TTCN_Logger::log_event_str(", desc := ");
if (match_value.desc().ispresent()) {
single_value->field_desc.log_match(match_value.desc(), legacy);
} else {
TTCN_Logger::log_event_str("omit with ");
single_value->field_desc.log();
if (single_value->field_desc.match_omit(legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
TTCN_Logger::log_event_str(" }");
} else {
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value, legacy)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}
}

void GPRS__BSICDescOpt_template::set_implicit_omit()
{
if (template_selection != SPECIFIC_VALUE) return;
if (presence().is_bound()) presence().set_implicit_omit();
if (!desc().is_bound()) desc() = OMIT_VALUE;
else desc().set_implicit_omit();
}

void GPRS__BSICDescOpt_template::encode_text(Text_Buf& text_buf) const
{
encode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value->field_presence.encode_text(text_buf);
single_value->field_desc.encode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
text_buf.push_int(value_list.n_values);
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
}
}

void GPRS__BSICDescOpt_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = new single_value_struct;
single_value->field_presence.decode_text(text_buf);
single_value->field_desc.decode_text(text_buf);
case OMIT_VALUE:
case ANY_VALUE:
case ANY_OR_OMIT:
break;
case VALUE_LIST:
case COMPLEMENTED_LIST:
value_list.n_values = text_buf.pull_int().get_val();
value_list.list_value = new GPRS__BSICDescOpt_template[value_list.n_values];
for (unsigned int list_count = 0; list_count < value_list.n_values; list_count++)
value_list.list_value[list_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received in a template of type @GSM_RestOctets.GPRS_BSICDescOpt.");
}
}

void GPRS__BSICDescOpt_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "record template");
  switch (param.get_type()) {
  case Module_Param::MP_Omit:
    *this = OMIT_VALUE;
    break;
  case Module_Param::MP_Any:
    *this = ANY_VALUE;
    break;
  case Module_Param::MP_AnyOrNone:
    *this = ANY_OR_OMIT;
    break;
  case Module_Param::MP_List_Template:
  case Module_Param::MP_ComplementList_Template:
  case Module_Param::MP_ConjunctList_Template: {
    GPRS__BSICDescOpt_template new_temp;
    new_temp.set_type(param.get_type()==Module_Param::MP_List_Template ? VALUE_LIST : (param.get_type() == Module_Param::MP_ConjunctList_Template ? CONJUNCTION_MATCH : COMPLEMENTED_LIST), param.get_size());
    for (size_t p_i=0; p_i<param.get_size(); p_i++) {
      new_temp.list_item(p_i).set_param(*param.get_elem(p_i));
    }
    *this = new_temp;
    break; }
  case Module_Param::MP_Value_List:
    if (2<param.get_size()) {
      param.error("record template of type @GSM_RestOctets.GPRS_BSICDescOpt has 2 fields but list value has %d fields", (int)param.get_size());
    }
    if (param.get_size()>0 && param.get_elem(0)->get_type()!=Module_Param::MP_NotUsed) presence().set_param(*param.get_elem(0));
    if (param.get_size()>1 && param.get_elem(1)->get_type()!=Module_Param::MP_NotUsed) desc().set_param(*param.get_elem(1));
    break;
  case Module_Param::MP_Assignment_List: {
    Vector<bool> value_used(param.get_size());
    value_used.resize(param.get_size(), FALSE);
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "presence")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          presence().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      if (!strcmp(curr_param->get_id()->get_name(), "desc")) {
        if (curr_param->get_type()!=Module_Param::MP_NotUsed) {
          desc().set_param(*curr_param);
        }
        value_used[val_idx]=TRUE;
      }
    }
    for (size_t val_idx=0; val_idx<param.get_size(); val_idx++) if (!value_used[val_idx]) {
      Module_Param* const curr_param = param.get_elem(val_idx);
      curr_param->error("Non existent field name in type @GSM_RestOctets.GPRS_BSICDescOpt: %s", curr_param->get_id()->get_name());
      break;
    }
  } break;
  case Module_Param::MP_Implication_Template: {
    GPRS__BSICDescOpt_template* precondition = new GPRS__BSICDescOpt_template;
    precondition->set_param(*param.get_elem(0));
    GPRS__BSICDescOpt_template* implied_template = new GPRS__BSICDescOpt_template;
    implied_template->set_param(*param.get_elem(1));
    *this = GPRS__BSICDescOpt_template(precondition, implied_template);
  } break;
  default:
    param.type_error("record template", "@GSM_RestOctets.GPRS_BSICDescOpt");
  }
  is_ifpresent = param.get_ifpresent();
}

void GPRS__BSICDescOpt_template::check_restriction(template_res t_res, const char* t_name, boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return;
switch ((t_name&&(t_res==TR_VALUE))?TR_OMIT:t_res) {
case TR_OMIT:
if (template_selection==OMIT_VALUE) return;
case TR_VALUE:
if (template_selection!=SPECIFIC_VALUE || is_ifpresent) break;
single_value->field_presence.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.GPRS_BSICDescOpt");
single_value->field_desc.check_restriction(t_res, t_name ? t_name : "@GSM_RestOctets.GPRS_BSICDescOpt");
return;
case TR_PRESENT:
if (!match_omit(legacy)) return;
break;
default:
return;
}
TTCN_error("Restriction `%s' on template of type %s violated.", get_res_name(t_res), t_name ? t_name : "@GSM_RestOctets.GPRS_BSICDescOpt");
}

boolean GPRS__BSICDescOpt_template::is_present(boolean legacy) const
{
if (template_selection==UNINITIALIZED_TEMPLATE) return FALSE;
return !match_omit(legacy);
}

boolean GPRS__BSICDescOpt_template::match_omit(boolean legacy) const
{
if (is_ifpresent) return TRUE;
switch (template_selection) {
case OMIT_VALUE:
case ANY_OR_OMIT:
return TRUE;
case IMPLICATION_MATCH:
return !implication_.precondition->match_omit() || implication_.implied_template->match_omit();
case VALUE_LIST:
case COMPLEMENTED_LIST:
if (legacy) {
for (unsigned int l_idx=0; l_idx<value_list.n_values; l_idx++)
if (value_list.list_value[l_idx].match_omit())
return template_selection==VALUE_LIST;
return template_selection==COMPLEMENTED_LIST;
} // else fall through
default:
return FALSE;
}
return FALSE;
}


} /* end of namespace */
