// 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 "DIAMETER_Templates.hh"

namespace DIAMETER__Templates {

/* Literal string constants */

const unsigned char bs_2_bits[] = { 0 },
bs_0_bits[] = { 2 },
bs_3_bits[] = { 1 },
bs_1_bits[] = { 3 };
extern const BITSTRING bs_2(8, bs_2_bits),
bs_0(8, bs_0_bits),
bs_3(8, bs_3_bits),
bs_1(8, bs_1_bits);
const unsigned char bp_0_elements[] = { 0, 2, 2, 2, 2, 2, 2, 2 },
bp_1_elements[] = { 1, 2, 2, 2, 2, 2, 2, 2 };
const BITSTRING_template bp_0(8, bp_0_elements),
bp_1(8, bp_1_elements);
const unsigned char os_1_octets[] = { 0, 0, 0, 0 },
os_4_octets[] = { 0, 0, 0, 1 },
os_2_octets[] = { 0, 0, 0, 4 },
os_0_octets[] = { 116, 116, 99, 110, 51, 46, 115, 101, 115, 115, 105, 111, 110 },
os_3_octets[] = { 255, 255, 255, 255 };
extern const OCTETSTRING os_1(4, os_1_octets),
os_4(4, os_4_octets),
os_2(4, os_2_octets),
os_0(13, os_0_octets),
os_3(4, os_3_octets);
extern const CHARSTRING cs_2('*'),
cs_0('?'),
cs_6(23, "DIAMETER_Templates.ttcn"),
cs_3(16, "TTCN-3 Testsuite"),
cs_5(11, "localdomain"),
cs_1(4, "omit"),
cs_4(17, "ttcn3.localdomain");
const unsigned char module_checksum[] = { 0x57, 0xc3, 0x73, 0xcf, 0x83, 0xfa, 0x6b, 0xf5, 0x47, 0x04, 0xee, 0x73, 0x05, 0xa1, 0xe6, 0x4c };

/* Global variable definitions */

// No XER for DIAMETER__Resultcode
const TTCN_Typedescriptor_t DIAMETER__Resultcode_descr_ = { "@DIAMETER_Templates.DIAMETER_Resultcode", NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, TTCN_Typedescriptor_t::DONTCARE };
INTEGER const_c__DIAMETER__CREDIT__CONTROL__AID;
const INTEGER& c__DIAMETER__CREDIT__CONTROL__AID = const_c__DIAMETER__CREDIT__CONTROL__AID;
INTEGER const_c__DIAMETER__3GPP__S7__AID;
const INTEGER& c__DIAMETER__3GPP__S7__AID = const_c__DIAMETER__3GPP__S7__AID;
OCTETSTRING const_c__def__sess__id;
const OCTETSTRING& c__def__sess__id = const_c__def__sess__id;
OCTETSTRING_template template_ts__DIAMETER_app__id_defval;
const OCTETSTRING_template& ts__DIAMETER_app__id_defval = template_ts__DIAMETER_app__id_defval;
OCTETSTRING_template template_ts__DIAMETER_hbh__id_defval;
const OCTETSTRING_template& ts__DIAMETER_hbh__id_defval = template_ts__DIAMETER_hbh__id_defval;
OCTETSTRING_template template_ts__DIAMETER_ete__id_defval;
const OCTETSTRING_template& ts__DIAMETER_ete__id_defval = template_ts__DIAMETER_ete__id_defval;
DIAMETER__Types::AVP__list_template template_ts__DIAMETER_avps_defval;
const DIAMETER__Types::AVP__list_template& ts__DIAMETER_avps_defval = template_ts__DIAMETER_avps_defval;
BITSTRING_template template_tr__DIAMETER_flags_defval;
const BITSTRING_template& tr__DIAMETER_flags_defval = template_tr__DIAMETER_flags_defval;
DIAMETER__Types::Command__Code_template template_tr__DIAMETER_cmd__code_defval;
const DIAMETER__Types::Command__Code_template& tr__DIAMETER_cmd__code_defval = template_tr__DIAMETER_cmd__code_defval;
OCTETSTRING_template template_tr__DIAMETER_app__id_defval;
const OCTETSTRING_template& tr__DIAMETER_app__id_defval = template_tr__DIAMETER_app__id_defval;
OCTETSTRING_template template_tr__DIAMETER_hbh__id_defval;
const OCTETSTRING_template& tr__DIAMETER_hbh__id_defval = template_tr__DIAMETER_hbh__id_defval;
OCTETSTRING_template template_tr__DIAMETER_ete__id_defval;
const OCTETSTRING_template& tr__DIAMETER_ete__id_defval = template_tr__DIAMETER_ete__id_defval;
DIAMETER__Types::AVP__list_template template_tr__DIAMETER_avps_defval;
const DIAMETER__Types::AVP__list_template& tr__DIAMETER_avps_defval = template_tr__DIAMETER_avps_defval;
DIAMETER__Types::Command__Code_template template_tr__DIAMETER__A_cmd__code_defval;
const DIAMETER__Types::Command__Code_template& tr__DIAMETER__A_cmd__code_defval = template_tr__DIAMETER__A_cmd__code_defval;
OCTETSTRING_template template_tr__DIAMETER__A_app__id_defval;
const OCTETSTRING_template& tr__DIAMETER__A_app__id_defval = template_tr__DIAMETER__A_app__id_defval;
OCTETSTRING_template template_tr__DIAMETER__A_hbh__id_defval;
const OCTETSTRING_template& tr__DIAMETER__A_hbh__id_defval = template_tr__DIAMETER__A_hbh__id_defval;
OCTETSTRING_template template_tr__DIAMETER__A_ete__id_defval;
const OCTETSTRING_template& tr__DIAMETER__A_ete__id_defval = template_tr__DIAMETER__A_ete__id_defval;
DIAMETER__Types::AVP__list_template template_tr__DIAMETER__A_avps_defval;
const DIAMETER__Types::AVP__list_template& tr__DIAMETER__A_avps_defval = template_tr__DIAMETER__A_avps_defval;
DIAMETER__Types::Command__Code_template template_tr__DIAMETER__R_cmd__code_defval;
const DIAMETER__Types::Command__Code_template& tr__DIAMETER__R_cmd__code_defval = template_tr__DIAMETER__R_cmd__code_defval;
OCTETSTRING_template template_tr__DIAMETER__R_app__id_defval;
const OCTETSTRING_template& tr__DIAMETER__R_app__id_defval = template_tr__DIAMETER__R_app__id_defval;
OCTETSTRING_template template_tr__DIAMETER__R_hbh__id_defval;
const OCTETSTRING_template& tr__DIAMETER__R_hbh__id_defval = template_tr__DIAMETER__R_hbh__id_defval;
OCTETSTRING_template template_tr__DIAMETER__R_ete__id_defval;
const OCTETSTRING_template& tr__DIAMETER__R_ete__id_defval = template_tr__DIAMETER__R_ete__id_defval;
DIAMETER__Types::AVP__list_template template_tr__DIAMETER__R_avps_defval;
const DIAMETER__Types::AVP__list_template& tr__DIAMETER__R_avps_defval = template_tr__DIAMETER__R_avps_defval;
BITSTRING_template template_ts__DIA__Hdr_flags_defval;
const BITSTRING_template& ts__DIA__Hdr_flags_defval = template_ts__DIA__Hdr_flags_defval;
BITSTRING_template template_tr__DIA__Hdr_flags_defval;
const BITSTRING_template& tr__DIA__Hdr_flags_defval = template_tr__DIA__Hdr_flags_defval;
BITSTRING_template template_ts__DIA__Hdr__3GPP_flags_defval;
const BITSTRING_template& ts__DIA__Hdr__3GPP_flags_defval = template_ts__DIA__Hdr__3GPP_flags_defval;
BITSTRING_template template_tr__DIA__Hdr__3GPP_flags_defval;
const BITSTRING_template& tr__DIA__Hdr__3GPP_flags_defval = template_tr__DIA__Hdr__3GPP_flags_defval;
DIAMETER__Types::AddressType_template template_tr__AVP__Address_addr__type_defval;
const DIAMETER__Types::AddressType_template& tr__AVP__Address_addr__type_defval = template_tr__AVP__Address_addr__type_defval;
OCTETSTRING_template template_tr__AVP__Address_addr__data_defval;
const OCTETSTRING_template& tr__AVP__Address_addr__data_defval = template_tr__AVP__Address_addr__data_defval;
DIAMETER__Types::DCC__NONE__Requested__Action_template template_tr__AVP__RequestedAction_t_defval;
const DIAMETER__Types::DCC__NONE__Requested__Action_template& tr__AVP__RequestedAction_t_defval = template_tr__AVP__RequestedAction_t_defval;
DIAMETER__Types::DCC__NONE__Multiple__Services__Indicator_template template_tr__AVP__MultipleServicesIndicator_t_defval;
const DIAMETER__Types::DCC__NONE__Multiple__Services__Indicator_template& tr__AVP__MultipleServicesIndicator_t_defval = template_tr__AVP__MultipleServicesIndicator_t_defval;
OCTETSTRING_template template_tr__AVP__ServiceContextId_id_defval;
const OCTETSTRING_template& tr__AVP__ServiceContextId_id_defval = template_tr__AVP__ServiceContextId_id_defval;
CHARSTRING_template template_tr__AVP__OriginHost_host_defval;
const CHARSTRING_template& tr__AVP__OriginHost_host_defval = template_tr__AVP__OriginHost_host_defval;
CHARSTRING_template template_tr__AVP__OriginRealm_realm_defval;
const CHARSTRING_template& tr__AVP__OriginRealm_realm_defval = template_tr__AVP__OriginRealm_realm_defval;
OCTETSTRING_template template_tr__AVP__OriginStateId_state__id_defval;
const OCTETSTRING_template& tr__AVP__OriginStateId_state__id_defval = template_tr__AVP__OriginStateId_state__id_defval;
DIAMETER__Types::Vendor__Id_template template_tr__AVP__VendorSpecAppId_vendor__id_defval;
const DIAMETER__Types::Vendor__Id_template& tr__AVP__VendorSpecAppId_vendor__id_defval = template_tr__AVP__VendorSpecAppId_vendor__id_defval;
INTEGER_template template_tr__AVP__VendorSpecAppId_auth__app__id_defval;
const INTEGER_template& tr__AVP__VendorSpecAppId_auth__app__id_defval = template_tr__AVP__VendorSpecAppId_auth__app__id_defval;
OCTETSTRING_template template_tr__AVP__AuthAppId_auth__app__id_defval;
const OCTETSTRING_template& tr__AVP__AuthAppId_auth__app__id_defval = template_tr__AVP__AuthAppId_auth__app__id_defval;
DIAMETER__Types::DCC__NONE__CC__Request__Type_template template_tr__AVP__CcReqType_r_defval;
const DIAMETER__Types::DCC__NONE__CC__Request__Type_template& tr__AVP__CcReqType_r_defval = template_tr__AVP__CcReqType_r_defval;
OCTETSTRING_template template_tr__AVP__CcReqNum_n_defval;
const OCTETSTRING_template& tr__AVP__CcReqNum_n_defval = template_tr__AVP__CcReqNum_n_defval;
OCTETSTRING_template template_tr__AVP__EventTimestamp_n_defval;
const OCTETSTRING_template& tr__AVP__EventTimestamp_n_defval = template_tr__AVP__EventTimestamp_n_defval;
OCTETSTRING_template template_tr__AVP__ExperimentalResultCode_n_defval;
const OCTETSTRING_template& tr__AVP__ExperimentalResultCode_n_defval = template_tr__AVP__ExperimentalResultCode_n_defval;
DIAMETER__Types::Vendor__Id_template template_tr__AVP__ExperimentalResult_vendor__id_defval;
const DIAMETER__Types::Vendor__Id_template& tr__AVP__ExperimentalResult_vendor__id_defval = template_tr__AVP__ExperimentalResult_vendor__id_defval;
OCTETSTRING_template template_tr__AVP__ExperimentalResult_err__code_defval;
const OCTETSTRING_template& tr__AVP__ExperimentalResult_err__code_defval = template_tr__AVP__ExperimentalResult_err__code_defval;
DIAMETER__Types::Vendor__Id_template template_ts__AVP__ExperimentalResult_vendor__id_defval;
const DIAMETER__Types::Vendor__Id_template& ts__AVP__ExperimentalResult_vendor__id_defval = template_ts__AVP__ExperimentalResult_vendor__id_defval;
DIAMETER__Types::BASE__NONE__Auth__Session__State_template template_ts__AVP__AuthSessionState_ass_defval;
const DIAMETER__Types::BASE__NONE__Auth__Session__State_template& ts__AVP__AuthSessionState_ass_defval = template_ts__AVP__AuthSessionState_ass_defval;
DIAMETER__Types::BASE__NONE__Auth__Session__State_template template_tr__AVP__AuthSessionState_ass_defval;
const DIAMETER__Types::BASE__NONE__Auth__Session__State_template& tr__AVP__AuthSessionState_ass_defval = template_tr__AVP__AuthSessionState_ass_defval;
OCTETSTRING_template template_tr__AVP__SessionId_session__id_defval;
const OCTETSTRING_template& tr__AVP__SessionId_session__id_defval = template_tr__AVP__SessionId_session__id_defval;
CHARSTRING_template template_tr__AVP__DestinationHost_host_defval;
const CHARSTRING_template& tr__AVP__DestinationHost_host_defval = template_tr__AVP__DestinationHost_host_defval;
CHARSTRING_template template_tr__AVP__DestinationRealm_dest__realm_defval;
const CHARSTRING_template& tr__AVP__DestinationRealm_dest__realm_defval = template_tr__AVP__DestinationRealm_dest__realm_defval;
OCTETSTRING_template template_tr__AVP__UserName_uid_defval;
const OCTETSTRING_template& tr__AVP__UserName_uid_defval = template_tr__AVP__UserName_uid_defval;
HEXSTRING_template template_tr__AVP__UserNameImsi_imsi_defval;
const HEXSTRING_template& tr__AVP__UserNameImsi_imsi_defval = template_tr__AVP__UserNameImsi_imsi_defval;
OCTETSTRING_template template_ts__AVP__NumOfReqVectors_num__req_defval;
const OCTETSTRING_template& ts__AVP__NumOfReqVectors_num__req_defval = template_ts__AVP__NumOfReqVectors_num__req_defval;
OCTETSTRING_template template_ts__AVP__ImmReqPref_par_defval;
const OCTETSTRING_template& ts__AVP__ImmReqPref_par_defval = template_ts__AVP__ImmReqPref_par_defval;
OCTETSTRING_template template_ts__AVP__RequestedEutranAuthInfo_num__vec_defval;
const OCTETSTRING_template& ts__AVP__RequestedEutranAuthInfo_num__vec_defval = template_ts__AVP__RequestedEutranAuthInfo_num__vec_defval;
INTEGER_template template_tr__AVP__3GPP__SubscrRauTauTmr_tmr_defval;
const INTEGER_template& tr__AVP__3GPP__SubscrRauTauTmr_tmr_defval = template_tr__AVP__3GPP__SubscrRauTauTmr_tmr_defval;
DIAMETER__Types::AVP__list_template template_tr__AVP__PCC__3GPP__QoS__Information_list_defval;
const DIAMETER__Types::AVP__list_template& tr__AVP__PCC__3GPP__QoS__Information_list_defval = template_tr__AVP__PCC__3GPP__QoS__Information_list_defval;
INTEGER_template template_tr__AVP__PCC__3GPP__QoS__Class__Identifier_val_defval;
const INTEGER_template& tr__AVP__PCC__3GPP__QoS__Class__Identifier_val_defval = template_tr__AVP__PCC__3GPP__QoS__Class__Identifier_val_defval;
INTEGER_template template_tr__AVP__3GPP__PriorityLevel_prio_defval;
const INTEGER_template& tr__AVP__3GPP__PriorityLevel_prio_defval = template_tr__AVP__3GPP__PriorityLevel_prio_defval;
INTEGER_template template_tr__AVP__PCC__3GPP__AllocRetenPrio_prio_defval;
const INTEGER_template& tr__AVP__PCC__3GPP__AllocRetenPrio_prio_defval = template_tr__AVP__PCC__3GPP__AllocRetenPrio_prio_defval;
INTEGER_template template_tr__AVP__3GPP__EpsSubscrQosProfile_qos__class_defval;
const INTEGER_template& tr__AVP__3GPP__EpsSubscrQosProfile_qos__class_defval = template_tr__AVP__3GPP__EpsSubscrQosProfile_qos__class_defval;
INTEGER_template template_tr__AVP__3GPP__EpsSubscrQosProfile_prio_defval;
const INTEGER_template& tr__AVP__3GPP__EpsSubscrQosProfile_prio_defval = template_tr__AVP__3GPP__EpsSubscrQosProfile_prio_defval;
DIAMETER__Types::DCA__3GPP__Reporting__Reason_template template_tr__AVP__3GPP__Reporting__Reason_r_defval;
const DIAMETER__Types::DCA__3GPP__Reporting__Reason_template& tr__AVP__3GPP__Reporting__Reason_r_defval = template_tr__AVP__3GPP__Reporting__Reason_r_defval;
DIAMETER__Types::DCA__3GPP__AoC__Request__Type_template template_tr__AVP__3GPP__AoCRequestType_t_defval;
const DIAMETER__Types::DCA__3GPP__AoC__Request__Type_template& tr__AVP__3GPP__AoCRequestType_t_defval = template_tr__AVP__3GPP__AoCRequestType_t_defval;
DIAMETER__Types::AVP__list_template template_tr__AVP__3GPP__ServiceInformation_content_defval;
const DIAMETER__Types::AVP__list_template& tr__AVP__3GPP__ServiceInformation_content_defval = template_tr__AVP__3GPP__ServiceInformation_content_defval;
DIAMETER__Types::AVP__list_template template_tr__AVP__3GPP__PSInformation_content_defval;
const DIAMETER__Types::AVP__list_template& tr__AVP__3GPP__PSInformation_content_defval = template_tr__AVP__3GPP__PSInformation_content_defval;
OCTETSTRING_template template_tr__AVP__3GPP__ChargingId_id_defval;
const OCTETSTRING_template& tr__AVP__3GPP__ChargingId_id_defval = template_tr__AVP__3GPP__ChargingId_id_defval;
DIAMETER__Types::GI__3GPP__3GPP__PDP__Type_template template_tr__AVP__3GPP__PDPType_t_defval;
const DIAMETER__Types::GI__3GPP__3GPP__PDP__Type_template& tr__AVP__3GPP__PDPType_t_defval = template_tr__AVP__3GPP__PDPType_t_defval;
DIAMETER__Types::AVP__Address_template template_tr__AVP__3GPP__PDPAddress_addr_defval;
const DIAMETER__Types::AVP__Address_template& tr__AVP__3GPP__PDPAddress_addr_defval = template_tr__AVP__3GPP__PDPAddress_addr_defval;
DIAMETER__Types::AVP__Address_template template_tr__AVP__3GPP__SGSNAddress_addr_defval;
const DIAMETER__Types::AVP__Address_template& tr__AVP__3GPP__SGSNAddress_addr_defval = template_tr__AVP__3GPP__SGSNAddress_addr_defval;
DIAMETER__Types::AVP__Address_template template_tr__AVP__3GPP__GGSNAddress_addr_defval;
const DIAMETER__Types::AVP__Address_template& tr__AVP__3GPP__GGSNAddress_addr_defval = template_tr__AVP__3GPP__GGSNAddress_addr_defval;
OCTETSTRING_template template_tr__AVP__3GPP__SelectionMode_sm_defval;
const OCTETSTRING_template& tr__AVP__3GPP__SelectionMode_sm_defval = template_tr__AVP__3GPP__SelectionMode_sm_defval;
OCTETSTRING_template template_tr__AVP__3GPP__ChargingCharacteristics_cc_defval;
const OCTETSTRING_template& tr__AVP__3GPP__ChargingCharacteristics_cc_defval = template_tr__AVP__3GPP__ChargingCharacteristics_cc_defval;
OCTETSTRING_template template_tr__AVP__3GPP__SGSNMCCMNC_smn_defval;
const OCTETSTRING_template& tr__AVP__3GPP__SGSNMCCMNC_smn_defval = template_tr__AVP__3GPP__SGSNMCCMNC_smn_defval;
OCTETSTRING_template template_tr__AVP__3GPP__NSAPI_nsapi_defval;
const OCTETSTRING_template& tr__AVP__3GPP__NSAPI_nsapi_defval = template_tr__AVP__3GPP__NSAPI_nsapi_defval;
OCTETSTRING_template template_tr__AVP__3GPP__MS__TimeZone_ms__tz_defval;
const OCTETSTRING_template& tr__AVP__3GPP__MS__TimeZone_ms__tz_defval = template_tr__AVP__3GPP__MS__TimeZone_ms__tz_defval;
OCTETSTRING_template template_tr__AVP__3GPP__ULI_uli_defval;
const OCTETSTRING_template& tr__AVP__3GPP__ULI_uli_defval = template_tr__AVP__3GPP__ULI_uli_defval;
DIAMETER__Types::AVP__list_template template_tr__AVP__UserEquipmentInfo_uei_defval;
const DIAMETER__Types::AVP__list_template& tr__AVP__UserEquipmentInfo_uei_defval = template_tr__AVP__UserEquipmentInfo_uei_defval;
DIAMETER__Types::DCC__NONE__User__Equipment__Info__Type_template template_tr__AVP__UserEquipmentInfoType_ueit_defval;
const DIAMETER__Types::DCC__NONE__User__Equipment__Info__Type_template& tr__AVP__UserEquipmentInfoType_ueit_defval = template_tr__AVP__UserEquipmentInfoType_ueit_defval;
OCTETSTRING_template template_tr__AVP__UserEquipmentInfoValue_ueiv_defval;
const OCTETSTRING_template& tr__AVP__UserEquipmentInfoValue_ueiv_defval = template_tr__AVP__UserEquipmentInfoValue_ueiv_defval;
DIAMETER__Types::AVP__list_template template_tr__AVP__Multiple__Services__Credit__Control_content_defval;
const DIAMETER__Types::AVP__list_template& tr__AVP__Multiple__Services__Credit__Control_content_defval = template_tr__AVP__Multiple__Services__Credit__Control_content_defval;
DIAMETER__Types::AVP__list_template template_tr__AVP__Requested__Service__Unit_content_defval;
const DIAMETER__Types::AVP__list_template& tr__AVP__Requested__Service__Unit_content_defval = template_tr__AVP__Requested__Service__Unit_content_defval;
DIAMETER__Types::AVP__list_template template_tr__AVP__Used__Service__Unit_content_defval;
const DIAMETER__Types::AVP__list_template& tr__AVP__Used__Service__Unit_content_defval = template_tr__AVP__Used__Service__Unit_content_defval;
OCTETSTRING_template template_tr__AVP__3GPP__CalledStationId_id_defval;
const OCTETSTRING_template& tr__AVP__3GPP__CalledStationId_id_defval = template_tr__AVP__3GPP__CalledStationId_id_defval;
CHARSTRING_template template_ts__DIA__CER_orig__host_defval;
const CHARSTRING_template& ts__DIA__CER_orig__host_defval = template_ts__DIA__CER_orig__host_defval;
CHARSTRING_template template_ts__DIA__CER_orig__realm_defval;
const CHARSTRING_template& ts__DIA__CER_orig__realm_defval = template_ts__DIA__CER_orig__realm_defval;
OCTETSTRING_template template_ts__DIA__CER_hbh__id_defval;
const OCTETSTRING_template& ts__DIA__CER_hbh__id_defval = template_ts__DIA__CER_hbh__id_defval;
OCTETSTRING_template template_ts__DIA__CER_ete__id_defval;
const OCTETSTRING_template& ts__DIA__CER_ete__id_defval = template_ts__DIA__CER_ete__id_defval;
OCTETSTRING_template template_ts__DIA__DWR_state__id_defval;
const OCTETSTRING_template& ts__DIA__DWR_state__id_defval = template_ts__DIA__DWR_state__id_defval;
CHARSTRING_template template_ts__DIA__DWR_orig__host_defval;
const CHARSTRING_template& ts__DIA__DWR_orig__host_defval = template_ts__DIA__DWR_orig__host_defval;
CHARSTRING_template template_ts__DIA__DWR_orig__realm_defval;
const CHARSTRING_template& ts__DIA__DWR_orig__realm_defval = template_ts__DIA__DWR_orig__realm_defval;
OCTETSTRING_template template_ts__DIA__DWR_hbh__id_defval;
const OCTETSTRING_template& ts__DIA__DWR_hbh__id_defval = template_ts__DIA__DWR_hbh__id_defval;
OCTETSTRING_template template_ts__DIA__DWR_ete__id_defval;
const OCTETSTRING_template& ts__DIA__DWR_ete__id_defval = template_ts__DIA__DWR_ete__id_defval;
OCTETSTRING_template template_tr__DIA__DWR_state__id_defval;
const OCTETSTRING_template& tr__DIA__DWR_state__id_defval = template_tr__DIA__DWR_state__id_defval;
CHARSTRING_template template_tr__DIA__DWR_orig__host_defval;
const CHARSTRING_template& tr__DIA__DWR_orig__host_defval = template_tr__DIA__DWR_orig__host_defval;
CHARSTRING_template template_tr__DIA__DWR_orig__realm_defval;
const CHARSTRING_template& tr__DIA__DWR_orig__realm_defval = template_tr__DIA__DWR_orig__realm_defval;
OCTETSTRING_template template_tr__DIA__DWR_hbh__id_defval;
const OCTETSTRING_template& tr__DIA__DWR_hbh__id_defval = template_tr__DIA__DWR_hbh__id_defval;
OCTETSTRING_template template_tr__DIA__DWR_ete__id_defval;
const OCTETSTRING_template& tr__DIA__DWR_ete__id_defval = template_tr__DIA__DWR_ete__id_defval;
OCTETSTRING_template template_ts__DIA__DWA_state__id_defval;
const OCTETSTRING_template& ts__DIA__DWA_state__id_defval = template_ts__DIA__DWA_state__id_defval;
CHARSTRING_template template_ts__DIA__DWA_orig__host_defval;
const CHARSTRING_template& ts__DIA__DWA_orig__host_defval = template_ts__DIA__DWA_orig__host_defval;
CHARSTRING_template template_ts__DIA__DWA_orig__realm_defval;
const CHARSTRING_template& ts__DIA__DWA_orig__realm_defval = template_ts__DIA__DWA_orig__realm_defval;
OCTETSTRING_template template_ts__DIA__DWA_hbh__id_defval;
const OCTETSTRING_template& ts__DIA__DWA_hbh__id_defval = template_ts__DIA__DWA_hbh__id_defval;
OCTETSTRING_template template_ts__DIA__DWA_ete__id_defval;
const OCTETSTRING_template& ts__DIA__DWA_ete__id_defval = template_ts__DIA__DWA_ete__id_defval;
OCTETSTRING_template template_tr__DIA__DWA_state__id_defval;
const OCTETSTRING_template& tr__DIA__DWA_state__id_defval = template_tr__DIA__DWA_state__id_defval;
CHARSTRING_template template_tr__DIA__DWA_orig__host_defval;
const CHARSTRING_template& tr__DIA__DWA_orig__host_defval = template_tr__DIA__DWA_orig__host_defval;
CHARSTRING_template template_tr__DIA__DWA_orig__realm_defval;
const CHARSTRING_template& tr__DIA__DWA_orig__realm_defval = template_tr__DIA__DWA_orig__realm_defval;
OCTETSTRING_template template_tr__DIA__DWA_hbh__id_defval;
const OCTETSTRING_template& tr__DIA__DWA_hbh__id_defval = template_tr__DIA__DWA_hbh__id_defval;
OCTETSTRING_template template_tr__DIA__DWA_ete__id_defval;
const OCTETSTRING_template& tr__DIA__DWA_ete__id_defval = template_tr__DIA__DWA_ete__id_defval;
INTEGER_template template_tr__AVP__3GPP__SIPNumAuthDataItems_num_defval;
const INTEGER_template& tr__AVP__3GPP__SIPNumAuthDataItems_num_defval = template_tr__AVP__3GPP__SIPNumAuthDataItems_num_defval;
OCTETSTRING_template template_tr__AVP__3GPP__SIPAuthScheme_scheme_defval;
const OCTETSTRING_template& tr__AVP__3GPP__SIPAuthScheme_scheme_defval = template_tr__AVP__3GPP__SIPAuthScheme_scheme_defval;
OCTETSTRING_template template_tr__AVP__3GPP__SIPAuthenticate_rand__autn__concatenated_defval;
const OCTETSTRING_template& tr__AVP__3GPP__SIPAuthenticate_rand__autn__concatenated_defval = template_tr__AVP__3GPP__SIPAuthenticate_rand__autn__concatenated_defval;
OCTETSTRING_template template_tr__AVP__3GPP__SIPAuthorization_rand__autn__concatenated_defval;
const OCTETSTRING_template& tr__AVP__3GPP__SIPAuthorization_rand__autn__concatenated_defval = template_tr__AVP__3GPP__SIPAuthorization_rand__autn__concatenated_defval;
OCTETSTRING_template template_tr__AVP__3GPP__SIPAuthContext_val_defval;
const OCTETSTRING_template& tr__AVP__3GPP__SIPAuthContext_val_defval = template_tr__AVP__3GPP__SIPAuthContext_val_defval;
INTEGER_template template_tr__AVP__3GPP__SIPItemNumber_num_defval;
const INTEGER_template& tr__AVP__3GPP__SIPItemNumber_num_defval = template_tr__AVP__3GPP__SIPItemNumber_num_defval;
OCTETSTRING_template template_tr__AVP__3GPP__ConfidentialityKey_ckey_defval;
const OCTETSTRING_template& tr__AVP__3GPP__ConfidentialityKey_ckey_defval = template_tr__AVP__3GPP__ConfidentialityKey_ckey_defval;
OCTETSTRING_template template_tr__AVP__3GPP__IntegrityKey_ckey_defval;
const OCTETSTRING_template& tr__AVP__3GPP__IntegrityKey_ckey_defval = template_tr__AVP__3GPP__IntegrityKey_ckey_defval;
DIAMETER__Types::CxDx__3GPP__Server__Assignment__Type_template template_tr__AVP__3GPP__ServerAssignmentType_t_defval;
const DIAMETER__Types::CxDx__3GPP__Server__Assignment__Type_template& tr__AVP__3GPP__ServerAssignmentType_t_defval = template_tr__AVP__3GPP__ServerAssignmentType_t_defval;
TTCN_Module module_object("DIAMETER_Templates", __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 */

DIAMETER__Resultcode::DIAMETER__Resultcode()
{
enum_value = UNBOUND_VALUE;
}

DIAMETER__Resultcode::DIAMETER__Resultcode(int other_value)
{
if (!is_valid_enum(other_value)) TTCN_error("Initializing a variable of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode with invalid numeric value %d.", other_value);
enum_value = (enum_type)other_value;
}

DIAMETER__Resultcode::DIAMETER__Resultcode(enum_type other_value)
{
enum_value = other_value;
}

DIAMETER__Resultcode::DIAMETER__Resultcode(const DIAMETER__Resultcode& other_value)
: Base_Type()
{
if (other_value.enum_value == UNBOUND_VALUE) TTCN_error("Copying an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
enum_value = other_value.enum_value;
}

DIAMETER__Resultcode& DIAMETER__Resultcode::operator=(int other_value)
{
if (!is_valid_enum(other_value)) TTCN_error("Assigning unknown numeric value %d to a variable of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.", other_value);
enum_value = (enum_type)other_value;
return *this;
}

DIAMETER__Resultcode& DIAMETER__Resultcode::operator=(enum_type other_value)
{
enum_value = other_value;
return *this;
}

DIAMETER__Resultcode& DIAMETER__Resultcode::operator=(const DIAMETER__Resultcode& other_value)
{
if (other_value.enum_value == UNBOUND_VALUE) TTCN_error("Assignment of an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
enum_value = other_value.enum_value;
return *this;
}

boolean DIAMETER__Resultcode::operator==(int other_value) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
if (!is_valid_enum(other_value)) TTCN_error("The right operand of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode comparison is an unknown numeric value %d", other_value);
return enum_value == other_value;
}

boolean DIAMETER__Resultcode::operator==(enum_type other_value) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
return enum_value == other_value;
}

boolean DIAMETER__Resultcode::operator==(const DIAMETER__Resultcode& other_value) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
if (other_value.enum_value == UNBOUND_VALUE) TTCN_error("The right operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
return enum_value == other_value.enum_value;
}

boolean DIAMETER__Resultcode::operator<(int other_value) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
if (!is_valid_enum(other_value)) TTCN_error("The right operand of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode comparison is an unknown numeric value %d", other_value);
return enum_value < other_value;
}

boolean DIAMETER__Resultcode::operator<(enum_type other_value) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
return enum_value < other_value;
}

boolean DIAMETER__Resultcode::operator<(const DIAMETER__Resultcode& other_value) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
if (other_value.enum_value == UNBOUND_VALUE) TTCN_error("The right operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
return enum_value < other_value.enum_value;
}

boolean DIAMETER__Resultcode::operator>(int other_value) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
if (!is_valid_enum(other_value)) TTCN_error("The right operand of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode comparison is an unknown numeric value %d", other_value);
return enum_value > other_value;
}

boolean DIAMETER__Resultcode::operator>(enum_type other_value) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
return enum_value > other_value;
}

boolean DIAMETER__Resultcode::operator>(const DIAMETER__Resultcode& other_value) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("The left operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
if (other_value.enum_value == UNBOUND_VALUE) TTCN_error("The right operand of comparison is an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
return enum_value > other_value.enum_value;
}

const char *DIAMETER__Resultcode::enum_to_str(enum_type enum_par)
{
switch (enum_par) {
case DIAMETER__MULTI__ROUND__AUTH: return "DIAMETER_MULTI_ROUND_AUTH";
case DIAMETER__SUCCESS: return "DIAMETER_SUCCESS";
case DIAMETER__LIMITED__SUCCESS: return "DIAMETER_LIMITED_SUCCESS";
case DIAMETER__FIRST__REGISTRATION: return "DIAMETER_FIRST_REGISTRATION";
case DIAMETER__SUBSEQUENT__REGISTRATION: return "DIAMETER_SUBSEQUENT_REGISTRATION";
case DIAMETER__UNREGISTERED__SERVICE: return "DIAMETER_UNREGISTERED_SERVICE";
case DIAMETER__SUCCESS__SERVER__NAME__NOT__STORED: return "DIAMETER_SUCCESS_SERVER_NAME_NOT_STORED";
case DIAMETER__SERVER__SELECTION: return "DIAMETER_SERVER_SELECTION";
case DIAMETER__SUCCESS__AUTH__SENT__SERVER__NOT__STORED: return "DIAMETER_SUCCESS_AUTH_SENT_SERVER_NOT_STORED";
case DIAMETER__SUCCESS__RELOCATE__HA: return "DIAMETER_SUCCESS_RELOCATE_HA";
case DIAMETER__COMMAND__UNSUPPORTED: return "DIAMETER_COMMAND_UNSUPPORTED";
case DIAMETER__UNABLE__TO__DELIVER: return "DIAMETER_UNABLE_TO_DELIVER";
case DIAMETER__REALM__NOT__SERVED: return "DIAMETER_REALM_NOT_SERVED";
case DIAMETER__TOO__BUSY: return "DIAMETER_TOO_BUSY";
case DIAMETER__LOOP__DETECTED: return "DIAMETER_LOOP_DETECTED";
case DIAMETER__REDIRECT__INDICATION: return "DIAMETER_REDIRECT_INDICATION";
case DIAMETER__APPLICATION__UNSUPPORTED: return "DIAMETER_APPLICATION_UNSUPPORTED";
case DIAMETER__INVALID__HDR__BITS: return "DIAMETER_INVALID_HDR_BITS";
case DIAMETER__INVALID__AVP__BITS: return "DIAMETER_INVALID_AVP_BITS";
case DIAMETER__UNKNOWN__PEER: return "DIAMETER_UNKNOWN_PEER";
case DIAMETER__REALM__REDIRECT__INDICATION: return "DIAMETER_REALM_REDIRECT_INDICATION";
case DIAMETER__AUTHENTICATION__REJECTED: return "DIAMETER_AUTHENTICATION_REJECTED";
case DIAMETER__OUT__OF__SPACE: return "DIAMETER_OUT_OF_SPACE";
case ELECTION__LOST: return "ELECTION_LOST";
case DIAMETER__ERROR__MIP__REPLY__FAILURE: return "DIAMETER_ERROR_MIP_REPLY_FAILURE";
case DIAMETER__ERROR__HA__NOT__AVAILABLE: return "DIAMETER_ERROR_HA_NOT_AVAILABLE";
case DIAMETER__ERROR__BAD__KEY: return "DIAMETER_ERROR_BAD_KEY";
case DIAMETER__ERROR__MIP__FILTER__NOT__SUPPORTED: return "DIAMETER_ERROR_MIP_FILTER_NOT_SUPPORTED";
case DIAMETER__END__USER__SERVICE__DENIED: return "DIAMETER_END_USER_SERVICE_DENIED";
case DIAMETER__CREDIT__CONTROL__NOT__APPLICABLE: return "DIAMETER_CREDIT_CONTROL_NOT_APPLICABLE";
case DIAMETER__CREDIT__LIMIT__REACHED: return "DIAMETER_CREDIT_LIMIT_REACHED";
case DIAMETER__USER__NAME__REQUIRED: return "DIAMETER_USER_NAME_REQUIRED";
case RESOURCE__FAILURE: return "RESOURCE_FAILURE";
case DIAMETER__AUTHENTICATION__DATA__UNAVAILABLE: return "DIAMETER_AUTHENTICATION_DATA_UNAVAILABLE";
case DIAMETER__ERROR__CAMEL__SUBSCRIPTION__PRESENT: return "DIAMETER_ERROR_CAMEL_SUBSCRIPTION_PRESENT";
case DIAMETER__AVP__UNSUPPORTED: return "DIAMETER_AVP_UNSUPPORTED";
case DIAMETER__UNKNOWN__SESSION__ID: return "DIAMETER_UNKNOWN_SESSION_ID";
case DIAMETER__AUTHORIZATION__REJECTED: return "DIAMETER_AUTHORIZATION_REJECTED";
case DIAMETER__INVALID__AVP__VALUE: return "DIAMETER_INVALID_AVP_VALUE";
case DIAMETER__MISSING__AVP: return "DIAMETER_MISSING_AVP";
case DIAMETER__RESOURCES__EXCEEDED: return "DIAMETER_RESOURCES_EXCEEDED";
case DIAMETER__CONTRADICTING__AVPS: return "DIAMETER_CONTRADICTING_AVPS";
case DIAMETER__AVP__NOT__ALLOWED: return "DIAMETER_AVP_NOT_ALLOWED";
case DIAMETER__AVP__OCCURS__TOO__MANY__TIMES: return "DIAMETER_AVP_OCCURS_TOO_MANY_TIMES";
case DIAMETER__NO__COMMON__APPLICATION: return "DIAMETER_NO_COMMON_APPLICATION";
case DIAMETER__UNSUPPORTED__VERSION: return "DIAMETER_UNSUPPORTED_VERSION";
case DIAMETER__UNABLE__TO__COMPLY: return "DIAMETER_UNABLE_TO_COMPLY";
case DIAMETER__INVALID__BIT__IN__HEADER: return "DIAMETER_INVALID_BIT_IN_HEADER";
case DIAMETER__INVALID__AVP__LENGTH: return "DIAMETER_INVALID_AVP_LENGTH";
case DIAMETER__INVALID__MESSAGE__LENGTH: return "DIAMETER_INVALID_MESSAGE_LENGTH";
case DIAMETER__INVALID__AVP__BIT__COMBO: return "DIAMETER_INVALID_AVP_BIT_COMBO";
case DIAMETER__NO__COMMON__SECURITY: return "DIAMETER_NO_COMMON_SECURITY";
case DIAMETER__RADIUS__AVP__UNTRANSLATABLE: return "DIAMETER_RADIUS_AVP_UNTRANSLATABLE";
case DIAMETER__ERROR__NO__FOREIGN__HA__SERVICE: return "DIAMETER_ERROR_NO_FOREIGN_HA_SERVICE";
case DIAMETER__ERROR__END__TO__END__MIP__KEY__ENCRYPTION: return "DIAMETER_ERROR_END_TO_END_MIP_KEY_ENCRYPTION";
case DIAMETER__USER__UNKNOWN: return "DIAMETER_USER_UNKNOWN";
case DIAMETER__RATING__FAILED: return "DIAMETER_RATING_FAILED";
case DIAMETER__ERROR__USER__UNKNOWN: return "DIAMETER_ERROR_USER_UNKNOWN";
case DIAMETER__ERROR__IDENTITIES__DONT__MATCH: return "DIAMETER_ERROR_IDENTITIES_DONT_MATCH";
case DIAMETER__ERROR__IDENTITY__NOT__REGISTERED: return "DIAMETER_ERROR_IDENTITY_NOT_REGISTERED";
case DIAMETER__ERROR__ROAMING__NOT__ALLOWED: return "DIAMETER_ERROR_ROAMING_NOT_ALLOWED";
case DIAMETER__ERROR__IDENTITY__ALREADY__REGISTERED: return "DIAMETER_ERROR_IDENTITY_ALREADY_REGISTERED";
case DIAMETER__ERROR__AUTH__SCHEME__NOT__SUPPORTED: return "DIAMETER_ERROR_AUTH_SCHEME_NOT_SUPPORTED";
case DIAMETER__ERROR__IN__ASSIGNMENT__TYPE: return "DIAMETER_ERROR_IN_ASSIGNMENT_TYPE";
case DIAMETER__ERROR__TOO__MUCH__DATA: return "DIAMETER_ERROR_TOO_MUCH_DATA";
case DIAMETER__ERROR__NOT__SUPPORTED__USER__DATA: return "DIAMETER_ERROR_NOT_SUPPORTED_USER_DATA";
case DIAMETER__ERROR__MIP6__AUTH__MODE: return "DIAMETER_ERROR_MIP6_AUTH_MODE";
case UNKNOWN__BINDING__TEMPLATE__NAME: return "UNKNOWN_BINDING_TEMPLATE_NAME";
case BINDING__FAILURE: return "BINDING_FAILURE";
case MAX__BINDINGS__SET__FAILURE: return "MAX_BINDINGS_SET_FAILURE";
case MAXIMUM__BINDINGS__REACHED__FOR__ENDPOINT: return "MAXIMUM_BINDINGS_REACHED_FOR_ENDPOINT";
case SESSION__EXISTS: return "SESSION_EXISTS";
case INSUFFICIENT__CLASSIFIERS: return "INSUFFICIENT_CLASSIFIERS";
case DIAMETER__ERROR__EAP__CODE__UNKNOWN: return "DIAMETER_ERROR_EAP_CODE_UNKNOWN";
default:
return "<unknown>";
}
}

DIAMETER__Resultcode::enum_type DIAMETER__Resultcode::str_to_enum(const char *str_par, const int* int_par, const int* int_par2)
{
if (int_par == NULL && int_par2 == NULL) {
if (!strcmp(str_par, "DIAMETER_MULTI_ROUND_AUTH")) return DIAMETER__MULTI__ROUND__AUTH;
if (!strcmp(str_par, "DIAMETER_SUCCESS")) return DIAMETER__SUCCESS;
if (!strcmp(str_par, "DIAMETER_LIMITED_SUCCESS")) return DIAMETER__LIMITED__SUCCESS;
if (!strcmp(str_par, "DIAMETER_FIRST_REGISTRATION")) return DIAMETER__FIRST__REGISTRATION;
if (!strcmp(str_par, "DIAMETER_SUBSEQUENT_REGISTRATION")) return DIAMETER__SUBSEQUENT__REGISTRATION;
if (!strcmp(str_par, "DIAMETER_UNREGISTERED_SERVICE")) return DIAMETER__UNREGISTERED__SERVICE;
if (!strcmp(str_par, "DIAMETER_SUCCESS_SERVER_NAME_NOT_STORED")) return DIAMETER__SUCCESS__SERVER__NAME__NOT__STORED;
if (!strcmp(str_par, "DIAMETER_SERVER_SELECTION")) return DIAMETER__SERVER__SELECTION;
if (!strcmp(str_par, "DIAMETER_SUCCESS_AUTH_SENT_SERVER_NOT_STORED")) return DIAMETER__SUCCESS__AUTH__SENT__SERVER__NOT__STORED;
if (!strcmp(str_par, "DIAMETER_SUCCESS_RELOCATE_HA")) return DIAMETER__SUCCESS__RELOCATE__HA;
if (!strcmp(str_par, "DIAMETER_COMMAND_UNSUPPORTED")) return DIAMETER__COMMAND__UNSUPPORTED;
if (!strcmp(str_par, "DIAMETER_UNABLE_TO_DELIVER")) return DIAMETER__UNABLE__TO__DELIVER;
if (!strcmp(str_par, "DIAMETER_REALM_NOT_SERVED")) return DIAMETER__REALM__NOT__SERVED;
if (!strcmp(str_par, "DIAMETER_TOO_BUSY")) return DIAMETER__TOO__BUSY;
if (!strcmp(str_par, "DIAMETER_LOOP_DETECTED")) return DIAMETER__LOOP__DETECTED;
if (!strcmp(str_par, "DIAMETER_REDIRECT_INDICATION")) return DIAMETER__REDIRECT__INDICATION;
if (!strcmp(str_par, "DIAMETER_APPLICATION_UNSUPPORTED")) return DIAMETER__APPLICATION__UNSUPPORTED;
if (!strcmp(str_par, "DIAMETER_INVALID_HDR_BITS")) return DIAMETER__INVALID__HDR__BITS;
if (!strcmp(str_par, "DIAMETER_INVALID_AVP_BITS")) return DIAMETER__INVALID__AVP__BITS;
if (!strcmp(str_par, "DIAMETER_UNKNOWN_PEER")) return DIAMETER__UNKNOWN__PEER;
if (!strcmp(str_par, "DIAMETER_REALM_REDIRECT_INDICATION")) return DIAMETER__REALM__REDIRECT__INDICATION;
if (!strcmp(str_par, "DIAMETER_AUTHENTICATION_REJECTED")) return DIAMETER__AUTHENTICATION__REJECTED;
if (!strcmp(str_par, "DIAMETER_OUT_OF_SPACE")) return DIAMETER__OUT__OF__SPACE;
if (!strcmp(str_par, "ELECTION_LOST")) return ELECTION__LOST;
if (!strcmp(str_par, "DIAMETER_ERROR_MIP_REPLY_FAILURE")) return DIAMETER__ERROR__MIP__REPLY__FAILURE;
if (!strcmp(str_par, "DIAMETER_ERROR_HA_NOT_AVAILABLE")) return DIAMETER__ERROR__HA__NOT__AVAILABLE;
if (!strcmp(str_par, "DIAMETER_ERROR_BAD_KEY")) return DIAMETER__ERROR__BAD__KEY;
if (!strcmp(str_par, "DIAMETER_ERROR_MIP_FILTER_NOT_SUPPORTED")) return DIAMETER__ERROR__MIP__FILTER__NOT__SUPPORTED;
if (!strcmp(str_par, "DIAMETER_END_USER_SERVICE_DENIED")) return DIAMETER__END__USER__SERVICE__DENIED;
if (!strcmp(str_par, "DIAMETER_CREDIT_CONTROL_NOT_APPLICABLE")) return DIAMETER__CREDIT__CONTROL__NOT__APPLICABLE;
if (!strcmp(str_par, "DIAMETER_CREDIT_LIMIT_REACHED")) return DIAMETER__CREDIT__LIMIT__REACHED;
if (!strcmp(str_par, "DIAMETER_USER_NAME_REQUIRED")) return DIAMETER__USER__NAME__REQUIRED;
if (!strcmp(str_par, "RESOURCE_FAILURE")) return RESOURCE__FAILURE;
if (!strcmp(str_par, "DIAMETER_AUTHENTICATION_DATA_UNAVAILABLE")) return DIAMETER__AUTHENTICATION__DATA__UNAVAILABLE;
if (!strcmp(str_par, "DIAMETER_ERROR_CAMEL_SUBSCRIPTION_PRESENT")) return DIAMETER__ERROR__CAMEL__SUBSCRIPTION__PRESENT;
if (!strcmp(str_par, "DIAMETER_AVP_UNSUPPORTED")) return DIAMETER__AVP__UNSUPPORTED;
if (!strcmp(str_par, "DIAMETER_UNKNOWN_SESSION_ID")) return DIAMETER__UNKNOWN__SESSION__ID;
if (!strcmp(str_par, "DIAMETER_AUTHORIZATION_REJECTED")) return DIAMETER__AUTHORIZATION__REJECTED;
if (!strcmp(str_par, "DIAMETER_INVALID_AVP_VALUE")) return DIAMETER__INVALID__AVP__VALUE;
if (!strcmp(str_par, "DIAMETER_MISSING_AVP")) return DIAMETER__MISSING__AVP;
if (!strcmp(str_par, "DIAMETER_RESOURCES_EXCEEDED")) return DIAMETER__RESOURCES__EXCEEDED;
if (!strcmp(str_par, "DIAMETER_CONTRADICTING_AVPS")) return DIAMETER__CONTRADICTING__AVPS;
if (!strcmp(str_par, "DIAMETER_AVP_NOT_ALLOWED")) return DIAMETER__AVP__NOT__ALLOWED;
if (!strcmp(str_par, "DIAMETER_AVP_OCCURS_TOO_MANY_TIMES")) return DIAMETER__AVP__OCCURS__TOO__MANY__TIMES;
if (!strcmp(str_par, "DIAMETER_NO_COMMON_APPLICATION")) return DIAMETER__NO__COMMON__APPLICATION;
if (!strcmp(str_par, "DIAMETER_UNSUPPORTED_VERSION")) return DIAMETER__UNSUPPORTED__VERSION;
if (!strcmp(str_par, "DIAMETER_UNABLE_TO_COMPLY")) return DIAMETER__UNABLE__TO__COMPLY;
if (!strcmp(str_par, "DIAMETER_INVALID_BIT_IN_HEADER")) return DIAMETER__INVALID__BIT__IN__HEADER;
if (!strcmp(str_par, "DIAMETER_INVALID_AVP_LENGTH")) return DIAMETER__INVALID__AVP__LENGTH;
if (!strcmp(str_par, "DIAMETER_INVALID_MESSAGE_LENGTH")) return DIAMETER__INVALID__MESSAGE__LENGTH;
if (!strcmp(str_par, "DIAMETER_INVALID_AVP_BIT_COMBO")) return DIAMETER__INVALID__AVP__BIT__COMBO;
if (!strcmp(str_par, "DIAMETER_NO_COMMON_SECURITY")) return DIAMETER__NO__COMMON__SECURITY;
if (!strcmp(str_par, "DIAMETER_RADIUS_AVP_UNTRANSLATABLE")) return DIAMETER__RADIUS__AVP__UNTRANSLATABLE;
if (!strcmp(str_par, "DIAMETER_ERROR_NO_FOREIGN_HA_SERVICE")) return DIAMETER__ERROR__NO__FOREIGN__HA__SERVICE;
if (!strcmp(str_par, "DIAMETER_ERROR_END_TO_END_MIP_KEY_ENCRYPTION")) return DIAMETER__ERROR__END__TO__END__MIP__KEY__ENCRYPTION;
if (!strcmp(str_par, "DIAMETER_USER_UNKNOWN")) return DIAMETER__USER__UNKNOWN;
if (!strcmp(str_par, "DIAMETER_RATING_FAILED")) return DIAMETER__RATING__FAILED;
if (!strcmp(str_par, "DIAMETER_ERROR_USER_UNKNOWN")) return DIAMETER__ERROR__USER__UNKNOWN;
if (!strcmp(str_par, "DIAMETER_ERROR_IDENTITIES_DONT_MATCH")) return DIAMETER__ERROR__IDENTITIES__DONT__MATCH;
if (!strcmp(str_par, "DIAMETER_ERROR_IDENTITY_NOT_REGISTERED")) return DIAMETER__ERROR__IDENTITY__NOT__REGISTERED;
if (!strcmp(str_par, "DIAMETER_ERROR_ROAMING_NOT_ALLOWED")) return DIAMETER__ERROR__ROAMING__NOT__ALLOWED;
if (!strcmp(str_par, "DIAMETER_ERROR_IDENTITY_ALREADY_REGISTERED")) return DIAMETER__ERROR__IDENTITY__ALREADY__REGISTERED;
if (!strcmp(str_par, "DIAMETER_ERROR_AUTH_SCHEME_NOT_SUPPORTED")) return DIAMETER__ERROR__AUTH__SCHEME__NOT__SUPPORTED;
if (!strcmp(str_par, "DIAMETER_ERROR_IN_ASSIGNMENT_TYPE")) return DIAMETER__ERROR__IN__ASSIGNMENT__TYPE;
if (!strcmp(str_par, "DIAMETER_ERROR_TOO_MUCH_DATA")) return DIAMETER__ERROR__TOO__MUCH__DATA;
if (!strcmp(str_par, "DIAMETER_ERROR_NOT_SUPPORTED_USER_DATA")) return DIAMETER__ERROR__NOT__SUPPORTED__USER__DATA;
if (!strcmp(str_par, "DIAMETER_ERROR_MIP6_AUTH_MODE")) return DIAMETER__ERROR__MIP6__AUTH__MODE;
if (!strcmp(str_par, "UNKNOWN_BINDING_TEMPLATE_NAME")) return UNKNOWN__BINDING__TEMPLATE__NAME;
if (!strcmp(str_par, "BINDING_FAILURE")) return BINDING__FAILURE;
if (!strcmp(str_par, "MAX_BINDINGS_SET_FAILURE")) return MAX__BINDINGS__SET__FAILURE;
if (!strcmp(str_par, "MAXIMUM_BINDINGS_REACHED_FOR_ENDPOINT")) return MAXIMUM__BINDINGS__REACHED__FOR__ENDPOINT;
if (!strcmp(str_par, "SESSION_EXISTS")) return SESSION__EXISTS;
if (!strcmp(str_par, "INSUFFICIENT_CLASSIFIERS")) return INSUFFICIENT__CLASSIFIERS;
if (!strcmp(str_par, "DIAMETER_ERROR_EAP_CODE_UNKNOWN")) return DIAMETER__ERROR__EAP__CODE__UNKNOWN;
}
return UNKNOWN_VALUE;
}

boolean DIAMETER__Resultcode::is_valid_enum(int int_par)
{
switch (int_par) {
case 1001:
case 2001:
case 2002:
case 2003:
case 2004:
case 2005:
case 2006:
case 2007:
case 2008:
case 2009:
case 3001:
case 3002:
case 3003:
case 3004:
case 3005:
case 3006:
case 3007:
case 3008:
case 3009:
case 3010:
case 3011:
case 4001:
case 4002:
case 4003:
case 4005:
case 4006:
case 4007:
case 4008:
case 4010:
case 4011:
case 4012:
case 4013:
case 4014:
case 4181:
case 4882:
case 5001:
case 5002:
case 5003:
case 5004:
case 5005:
case 5006:
case 5007:
case 5008:
case 5009:
case 5010:
case 5011:
case 5012:
case 5013:
case 5014:
case 5015:
case 5016:
case 5017:
case 5018:
case 5024:
case 5025:
case 5030:
case 5031:
case 5032:
case 5033:
case 5034:
case 5035:
case 5036:
case 5037:
case 5038:
case 5039:
case 5040:
case 5041:
case 5042:
case 5043:
case 5044:
case 5045:
case 5046:
case 5047:
case 5048:
return TRUE;
default:
return FALSE;
}
}

int DIAMETER__Resultcode::enum2int(enum_type enum_par)
{
if (enum_par==UNBOUND_VALUE || enum_par==UNKNOWN_VALUE) TTCN_error("The argument of function enum2int() is an %s value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.", enum_par==UNBOUND_VALUE?"unbound":"invalid");
return enum_par;
}

int DIAMETER__Resultcode::enum2int(const DIAMETER__Resultcode& enum_par)
{
if (enum_par.enum_value==UNBOUND_VALUE || enum_par.enum_value==UNKNOWN_VALUE) TTCN_error("The argument of function enum2int() is an %s value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.", enum_par==UNBOUND_VALUE?"unbound":"invalid");
return enum_par.enum_value;
}

void DIAMETER__Resultcode::int2enum(int int_val)
{
if (!is_valid_enum(int_val)) TTCN_error("Assigning invalid numeric value %d to a variable of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.", int_val);
enum_value = (enum_type)int_val;
}

DIAMETER__Resultcode::operator DIAMETER__Resultcode::enum_type() const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("Using the value of an unbound variable of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
return enum_value;
}

void DIAMETER__Resultcode::log() const
{
if (enum_value != UNBOUND_VALUE) TTCN_Logger::log_event_enum(enum_to_str(enum_value), enum_value);
else TTCN_Logger::log_event_unbound();
}

void DIAMETER__Resultcode::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_VALUE, "enumerated value");
  if (param.get_type()!=Module_Param::MP_Enumerated) param.type_error("enumerated value", "@DIAMETER_Templates.DIAMETER_Resultcode");
  enum_value = str_to_enum(param.get_enumerated(), param.get_enumerated_value());
  if (!is_valid_enum(enum_value)) {
    param.error("Invalid enumerated value for type @DIAMETER_Templates.DIAMETER_Resultcode.");
  }
}

void DIAMETER__Resultcode::encode_text(Text_Buf& text_buf) const
{
if (enum_value == UNBOUND_VALUE) TTCN_error("Text encoder: Encoding an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
text_buf.push_int(enum_value);
}

void DIAMETER__Resultcode::decode_text(Text_Buf& text_buf)
{
enum_value = (enum_type)text_buf.pull_int().get_val();
if (!is_valid_enum(enum_value)) TTCN_error("Text decoder: Unknown numeric value %d was received for enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.", enum_value);
}

void DIAMETER__Resultcode_template::copy_template(const DIAMETER__Resultcode_template& other_value)
{
set_selection(other_value);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = other_value.single_value;
break;
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 DIAMETER__Resultcode_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 DIAMETER__Resultcode_template(*other_value.implication_.precondition);
implication_.implied_template = new DIAMETER__Resultcode_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 enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
}
}

DIAMETER__Resultcode_template::DIAMETER__Resultcode_template()
{
}

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

DIAMETER__Resultcode_template::DIAMETER__Resultcode_template(int other_value)
 : Base_Template(SPECIFIC_VALUE)
{
if (!DIAMETER__Resultcode::is_valid_enum(other_value)) TTCN_error("Initializing a template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode with unknown numeric value %d.", other_value);
single_value = (DIAMETER__Resultcode::enum_type)other_value;
}

DIAMETER__Resultcode_template::DIAMETER__Resultcode_template(DIAMETER__Resultcode::enum_type other_value)
 : Base_Template(SPECIFIC_VALUE)
{
single_value = other_value;
}

DIAMETER__Resultcode_template::DIAMETER__Resultcode_template(const DIAMETER__Resultcode& other_value)
 : Base_Template(SPECIFIC_VALUE)
{
if (other_value.enum_value == DIAMETER__Resultcode::UNBOUND_VALUE) TTCN_error("Creating a template from an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
single_value = other_value.enum_value;
}

DIAMETER__Resultcode_template::DIAMETER__Resultcode_template(const OPTIONAL<DIAMETER__Resultcode>& other_value)
{
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
set_selection(SPECIFIC_VALUE);
single_value = (DIAMETER__Resultcode::enum_type)(const DIAMETER__Resultcode&)other_value;
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Creating a template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode from an unbound optional field.");
}
}

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

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

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

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

boolean DIAMETER__Resultcode_template::is_bound() const
{
if (template_selection == UNINITIALIZED_TEMPLATE && !is_ifpresent) return FALSE;
return TRUE;
}

boolean DIAMETER__Resultcode_template::is_value() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) return FALSE;
return single_value != DIAMETER__Resultcode::UNBOUND_VALUE;
}

void DIAMETER__Resultcode_template::clean_up()
{
switch (template_selection) {
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;
}

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

DIAMETER__Resultcode_template& DIAMETER__Resultcode_template::operator=(int other_value)
{
if (!DIAMETER__Resultcode::is_valid_enum(other_value)) TTCN_warning("Assigning unknown numeric value %d to a template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.", other_value);
clean_up();
set_selection(SPECIFIC_VALUE);
single_value = (DIAMETER__Resultcode::enum_type)other_value;
return *this;
}

DIAMETER__Resultcode_template& DIAMETER__Resultcode_template::operator=(DIAMETER__Resultcode::enum_type other_value)
{
clean_up();
set_selection(SPECIFIC_VALUE);
single_value = other_value;
return *this;
}

DIAMETER__Resultcode_template& DIAMETER__Resultcode_template::operator=(const DIAMETER__Resultcode& other_value)
{
if (other_value.enum_value == DIAMETER__Resultcode::UNBOUND_VALUE) TTCN_error("Assignment of an unbound value of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode to a template.");
clean_up();
set_selection(SPECIFIC_VALUE);
single_value = other_value.enum_value;
return *this;
}

DIAMETER__Resultcode_template& DIAMETER__Resultcode_template::operator=(const OPTIONAL<DIAMETER__Resultcode>& other_value)
{
clean_up();
switch (other_value.get_selection()) {
case OPTIONAL_PRESENT:
set_selection(SPECIFIC_VALUE);
single_value = (DIAMETER__Resultcode::enum_type)(const DIAMETER__Resultcode&)other_value;
break;
case OPTIONAL_OMIT:
set_selection(OMIT_VALUE);
break;
default:
TTCN_error("Assignment of an unbound optional field to a template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
}
return *this;
}

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

boolean DIAMETER__Resultcode_template::match(DIAMETER__Resultcode::enum_type other_value, boolean) const
{
switch (template_selection) {
case SPECIFIC_VALUE:
return single_value == other_value;
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)) 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 enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
}
return FALSE;
}

boolean DIAMETER__Resultcode_template::match(const DIAMETER__Resultcode& other_value, boolean) const
{
if (other_value.enum_value == DIAMETER__Resultcode::UNBOUND_VALUE) TTCN_error("Matching a template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode with an unbound value.");
return match(other_value.enum_value);
}

DIAMETER__Resultcode::enum_type DIAMETER__Resultcode_template::valueof() const
{
if (template_selection != SPECIFIC_VALUE || is_ifpresent) TTCN_error("Performing a valueof or send operation on a non-specific template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
return single_value;
}

void DIAMETER__Resultcode_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:
set_selection(template_type);
value_list.n_values = list_length;
value_list.list_value = new DIAMETER__Resultcode_template[list_length];
break;
default:
TTCN_error("Setting an invalid type for a template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
}
}

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

void DIAMETER__Resultcode_template::log() const
{
switch (template_selection) {
case SPECIFIC_VALUE:
TTCN_Logger::log_event_enum(DIAMETER__Resultcode::enum_to_str(single_value), single_value);
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 elem_count = 0; elem_count < value_list.n_values; elem_count++) {
if (elem_count > 0) TTCN_Logger::log_event_str(", ");
value_list.list_value[elem_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 DIAMETER__Resultcode_template::log_match(const DIAMETER__Resultcode& match_value, boolean) const
{
match_value.log();
TTCN_Logger::log_event_str(" with ");
log();
if (match(match_value)) TTCN_Logger::log_event_str(" matched");
else TTCN_Logger::log_event_str(" unmatched");
}

void DIAMETER__Resultcode_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);
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 elem_count = 0; elem_count < value_list.n_values; elem_count++)
value_list.list_value[elem_count].encode_text(text_buf);
break;
default:
TTCN_error("Text encoder: Encoding an uninitialized/unsupported template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
}
}

void DIAMETER__Resultcode_template::decode_text(Text_Buf& text_buf)
{
clean_up();
decode_text_base(text_buf);
switch (template_selection) {
case SPECIFIC_VALUE:
single_value = (DIAMETER__Resultcode::enum_type)text_buf.pull_int().get_val();
if (!DIAMETER__Resultcode::is_valid_enum(single_value)) TTCN_error("Text decoder: Unknown numeric value %d was received for a template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.", single_value);
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 DIAMETER__Resultcode_template[value_list.n_values];
for (unsigned int elem_count = 0; elem_count < value_list.n_values; elem_count++)
value_list.list_value[elem_count].decode_text(text_buf);
break;
default:
TTCN_error("Text decoder: An unknown/unsupported selection was received for a template of enumerated type @DIAMETER_Templates.DIAMETER_Resultcode.");
}
}

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

boolean DIAMETER__Resultcode_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 DIAMETER__Resultcode_template::set_param(Module_Param& param)
{
  param.basic_check(Module_Param::BC_TEMPLATE, "enumerated 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: {
    DIAMETER__Resultcode_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_Enumerated: {
    DIAMETER__Resultcode::enum_type enum_val = DIAMETER__Resultcode::str_to_enum(m_p->get_enumerated(), m_p->get_enumerated_value());
    if (!DIAMETER__Resultcode::is_valid_enum(enum_val)) {
      param.error("Invalid enumerated value for type @DIAMETER_Templates.DIAMETER_Resultcode.");
    }
    *this = enum_val;
  } break;
  case Module_Param::MP_Implication_Template: {
    DIAMETER__Resultcode_template* precondition = new DIAMETER__Resultcode_template;
    precondition->set_param(*m_p->get_elem(0));
    DIAMETER__Resultcode_template* implied_template = new DIAMETER__Resultcode_template;
    implied_template->set_param(*m_p->get_elem(1));
    *this = DIAMETER__Resultcode_template(precondition, implied_template);
  } break;
  default:
    param.type_error("enumerated template", "@DIAMETER_Templates.DIAMETER_Resultcode");
  }
  is_ifpresent = param.get_ifpresent();
}

void DIAMETER__Resultcode_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_VALUE:
if (!is_ifpresent && template_selection==SPECIFIC_VALUE) return;
break;
case TR_OMIT:
if (!is_ifpresent && (template_selection==OMIT_VALUE || template_selection==SPECIFIC_VALUE)) return;
break;
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 : "@DIAMETER_Templates.DIAMETER_Resultcode");
}


/* Bodies of functions, altsteps and testcases */

DIAMETER__Types::PDU__DIAMETER_template ts__DIAMETER(const BITSTRING_template& flags, const DIAMETER__Types::Command__Code_template& cmd__code, const OCTETSTRING_template& app__id, const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id, const DIAMETER__Types::AVP__list_template& avps)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 112, TTCN_Location::LOCATION_TEMPLATE, "ts_DIAMETER");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
ret_val.version() = 1;
ret_val.message__length() = 0;
ret_val.RPETxxxx() = flags;
ret_val.command__code() = cmd__code;
ret_val.application__id() = app__id;
ret_val.hop__by__hop__id() = hbh__id;
ret_val.end__to__end__id() = ete__id;
ret_val.avps() = avps;
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template tr__DIAMETER(const BITSTRING_template& flags, const DIAMETER__Types::Command__Code_template& cmd__code, const OCTETSTRING_template& app__id, const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id, const DIAMETER__Types::AVP__list_template& avps)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 129, TTCN_Location::LOCATION_TEMPLATE, "tr_DIAMETER");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
ret_val.version() = 1;
ret_val.message__length() = ANY_VALUE;
ret_val.RPETxxxx() = flags;
ret_val.command__code() = cmd__code;
ret_val.application__id() = app__id;
ret_val.hop__by__hop__id() = hbh__id;
ret_val.end__to__end__id() = ete__id;
ret_val.avps() = avps;
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template tr__DIAMETER__A(const DIAMETER__Types::Command__Code_template& cmd__code, const OCTETSTRING_template& app__id, const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id, const DIAMETER__Types::AVP__list_template& avps)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 145, TTCN_Location::LOCATION_TEMPLATE, "tr_DIAMETER_A");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
ret_val = tr__DIAMETER(bp_0, cmd__code, app__id, hbh__id, ete__id, avps);
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template tr__DIAMETER__R(const DIAMETER__Types::Command__Code_template& cmd__code, const OCTETSTRING_template& app__id, const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id, const DIAMETER__Types::AVP__list_template& avps)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 153, TTCN_Location::LOCATION_TEMPLATE, "tr_DIAMETER_R");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
ret_val = tr__DIAMETER(bp_1, cmd__code, app__id, hbh__id, ete__id, avps);
return ret_val;
}

DIAMETER__Types::AVP__Header_template ts__DIA__Hdr(const DIAMETER__Types::AVP__Code_template& avp__code, const BITSTRING_template& flags)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 163, TTCN_Location::LOCATION_TEMPLATE, "ts_DIA_Hdr");
DIAMETER__Types::AVP__Header_template ret_val;
ret_val.avp__code() = avp__code;
ret_val.VMPxxxxx() = flags;
ret_val.avp__length() = 0;
ret_val.vendor__id() = OMIT_VALUE;
return ret_val;
}

DIAMETER__Types::AVP__Header_template tr__DIA__Hdr(const DIAMETER__Types::AVP__Code_template& avp__code, const BITSTRING_template& flags)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 171, TTCN_Location::LOCATION_TEMPLATE, "tr_DIA_Hdr");
DIAMETER__Types::AVP__Header_template ret_val;
ret_val.avp__code() = avp__code;
ret_val.VMPxxxxx() = flags;
ret_val.avp__length() = ANY_VALUE;
ret_val.vendor__id() = OMIT_VALUE;
return ret_val;
}

DIAMETER__Types::AVP__Header_template ts__DIA__Hdr__3GPP(const DIAMETER__Types::AVP__Code_template& avp__code, const BITSTRING_template& flags)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 180, TTCN_Location::LOCATION_TEMPLATE, "ts_DIA_Hdr_3GPP");
DIAMETER__Types::AVP__Header_template ret_val;
ret_val.avp__code() = avp__code;
ret_val.VMPxxxxx() = flags;
ret_val.avp__length() = 0;
ret_val.vendor__id() = DIAMETER__Types::Vendor__Id::vendor__id__3GPP;
return ret_val;
}

DIAMETER__Types::AVP__Header_template tr__DIA__Hdr__3GPP(const DIAMETER__Types::AVP__Code_template& avp__code, const BITSTRING_template& flags)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 188, TTCN_Location::LOCATION_TEMPLATE, "tr_DIA_Hdr_3GPP");
DIAMETER__Types::AVP__Header_template ret_val;
ret_val.avp__code() = avp__code;
ret_val.VMPxxxxx() = flags;
ret_val.avp__length() = ANY_VALUE;
ret_val.vendor__id() = DIAMETER__Types::Vendor__Id::vendor__id__3GPP;
return ret_val;
}

DIAMETER__Types::AVP__Address_template tr__AVP__Address(const DIAMETER__Types::AddressType_template& addr__type, const OCTETSTRING_template& addr__data)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 197, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_Address");
DIAMETER__Types::AVP__Address_template ret_val;
ret_val.address__type() = addr__type;
ret_val.address__data() = addr__data;
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__SubcrId(const DIAMETER__Types::AVP__list_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 204, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_SubcrId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_0 = ret_val.avp();
tmp_0.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Subscription__Id), tr__DIA__Hdr_flags_defval);
tmp_0.avp__data().avp__DCC__NONE__Subscription__Id() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__SubcrId(const DIAMETER__Types::AVP__list_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 212, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_SubcrId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_1 = ret_val.avp();
tmp_1.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Subscription__Id), ts__DIA__Hdr_flags_defval);
tmp_1.avp__data().avp__DCC__NONE__Subscription__Id() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__SubcrIdType(const DIAMETER__Types::DCC__NONE__Subscription__Id__Type_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 222, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_SubcrIdType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_2 = ret_val.avp();
tmp_2.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Subscription__Id__Type), tr__DIA__Hdr_flags_defval);
tmp_2.avp__data().avp__DCC__NONE__Subscription__Id__Type() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__SubcrIdType(const DIAMETER__Types::DCC__NONE__Subscription__Id__Type_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 230, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_SubcrIdType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_3 = ret_val.avp();
tmp_3.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Subscription__Id__Type), ts__DIA__Hdr_flags_defval);
tmp_3.avp__data().avp__DCC__NONE__Subscription__Id__Type() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__SubcrIdData(const OCTETSTRING_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 240, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_SubcrIdData");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_4 = ret_val.avp();
tmp_4.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Subscription__Id__Data), tr__DIA__Hdr_flags_defval);
tmp_4.avp__data().avp__DCC__NONE__Subscription__Id__Data() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__SubcrIdData(const OCTETSTRING_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 248, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_SubcrIdData");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_5 = ret_val.avp();
tmp_5.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Subscription__Id__Data), ts__DIA__Hdr_flags_defval);
tmp_5.avp__data().avp__DCC__NONE__Subscription__Id__Data() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__RequestedAction(const DIAMETER__Types::DCC__NONE__Requested__Action_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 257, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_RequestedAction");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_6 = ret_val.avp();
tmp_6.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Requested__Action), tr__DIA__Hdr_flags_defval);
tmp_6.avp__data().avp__DCC__NONE__Requested__Action() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__MultipleServicesIndicator(const DIAMETER__Types::DCC__NONE__Multiple__Services__Indicator_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 266, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_MultipleServicesIndicator");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_7 = ret_val.avp();
tmp_7.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Multiple__Services__Indicator), tr__DIA__Hdr_flags_defval);
tmp_7.avp__data().avp__DCC__NONE__Multiple__Services__Indicator() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__ServiceContextId(const OCTETSTRING_template& id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 275, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_ServiceContextId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_8 = ret_val.avp();
tmp_8.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Service__Context__Id), tr__DIA__Hdr_flags_defval);
tmp_8.avp__data().avp__DCC__NONE__Service__Context__Id() = id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__OriginHost(const CHARSTRING_template& host)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 284, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_OriginHost");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_9 = ret_val.avp();
tmp_9.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Origin__Host), ts__DIA__Hdr_flags_defval);
tmp_9.avp__data().avp__BASE__NONE__Origin__Host() = host;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__OriginHost(const CHARSTRING_template& host)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 292, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_OriginHost");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_10 = ret_val.avp();
tmp_10.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Origin__Host), tr__DIA__Hdr_flags_defval);
tmp_10.avp__data().avp__BASE__NONE__Origin__Host() = host;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__OriginRealm(const CHARSTRING_template& realm)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 302, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_OriginRealm");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_11 = ret_val.avp();
tmp_11.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Origin__Realm), ts__DIA__Hdr_flags_defval);
tmp_11.avp__data().avp__BASE__NONE__Origin__Realm() = realm;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__OriginRealm(const CHARSTRING_template& realm)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 310, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_OriginRealm");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_12 = ret_val.avp();
tmp_12.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Origin__Realm), tr__DIA__Hdr_flags_defval);
tmp_12.avp__data().avp__BASE__NONE__Origin__Realm() = realm;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__OriginStateId(const OCTETSTRING_template& state__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 320, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_OriginStateId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_13 = ret_val.avp();
tmp_13.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Origin__State__Id), ts__DIA__Hdr_flags_defval);
tmp_13.avp__data().avp__BASE__NONE__Origin__State__Id() = state__id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__OriginStateId(const OCTETSTRING_template& state__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 328, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_OriginStateId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_14 = ret_val.avp();
tmp_14.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Origin__State__Id), tr__DIA__Hdr_flags_defval);
tmp_14.avp__data().avp__BASE__NONE__Origin__State__Id() = state__id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__TerminationCause(const DIAMETER__Types::BASE__NONE__Termination__Cause_template& tc)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 337, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_TerminationCause");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_15 = ret_val.avp();
tmp_15.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Termination__Cause), ts__DIA__Hdr_flags_defval);
tmp_15.avp__data().avp__BASE__NONE__Termination__Cause() = tc;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__TerminationCause(const DIAMETER__Types::BASE__NONE__Termination__Cause_template& tc)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 346, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_TerminationCause");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_16 = ret_val.avp();
tmp_16.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Termination__Cause), tr__DIA__Hdr_flags_defval);
tmp_16.avp__data().avp__BASE__NONE__Termination__Cause() = tc;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__HostIpAddr(const OCTETSTRING_template& ipv4__addr)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 355, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_HostIpAddr");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_17 = ret_val.avp();
tmp_17.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Host__IP__Address), ts__DIA__Hdr_flags_defval);
{
DIAMETER__Types::AVP__Address_template& tmp_18 = tmp_17.avp__data().avp__BASE__NONE__Host__IP__Address();
tmp_18.address__type() = DIAMETER__Types::AddressType::IP;
tmp_18.address__data() = ipv4__addr;
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__VendorId(const DIAMETER__Types::Vendor__Id_template& vendor__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 367, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_VendorId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_19 = ret_val.avp();
tmp_19.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Vendor__Id), BITSTRING_template(bs_2));
tmp_19.avp__data().avp__BASE__NONE__Vendor__Id() = int2oct(DIAMETER__Types::Vendor__Id::enum2int(vendor__id.valueof()), 4);
}
return ret_val;
}

OCTETSTRING_template f__tr__AVP__VendorId(const DIAMETER__Types::Vendor__Id_template& vendor__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 375, TTCN_Location::LOCATION_FUNCTION, "f_tr_AVP_VendorId");
current_location.update_lineno(377);
/* DIAMETER_Templates.ttcn, line 377 */
if (vendor__id.get_istemplate_kind((const char*)cs_0)) {
current_location.update_lineno(378);
/* DIAMETER_Templates.ttcn, line 378 */
return OCTETSTRING_template(ANY_VALUE);
}
else {
current_location.update_lineno(380);
/* DIAMETER_Templates.ttcn, line 380 */
OCTETSTRING_template c;
current_location.update_lineno(381);
/* DIAMETER_Templates.ttcn, line 381 */
c = int2oct(DIAMETER__Types::Vendor__Id::enum2int(vendor__id.valueof()), 4);
current_location.update_lineno(382);
/* DIAMETER_Templates.ttcn, line 382 */
return c;
}
}

DIAMETER__Types::GenericAVP_template tr__AVP__VendorId(const DIAMETER__Types::Vendor__Id_template& vendor__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 385, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_VendorId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_21 = ret_val.avp();
tmp_21.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Vendor__Id), tr__DIA__Hdr_flags_defval);
tmp_21.avp__data().avp__BASE__NONE__Vendor__Id() = f__tr__AVP__VendorId(vendor__id);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__ProductName(const CHARSTRING& name)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 394, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_ProductName");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_22 = ret_val.avp();
tmp_22.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Product__Name), BITSTRING_template(bs_2));
tmp_22.avp__data().avp__BASE__NONE__Product__Name() = char2oct(name);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__FwRevision(const OCTETSTRING& fw__version)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 403, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_FwRevision");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_23 = ret_val.avp();
tmp_23.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Firmware__Revision), BITSTRING_template(bs_2));
tmp_23.avp__data().avp__BASE__NONE__Firmware__Revision() = fw__version;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__InbSecId(const OCTETSTRING_template& inb__sec__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 412, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_InbSecId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_24 = ret_val.avp();
tmp_24.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Inband__Security__Id), ts__DIA__Hdr_flags_defval);
tmp_24.avp__data().avp__BASE__NONE__Inband__Security__Id() = inb__sec__id;
}
return ret_val;
}

INTEGER_template enum2int__Vendor__Id__tmpl(const DIAMETER__Types::Vendor__Id_template& inp)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 421, TTCN_Location::LOCATION_FUNCTION, "enum2int_Vendor_Id_tmpl");
current_location.update_lineno(423);
/* DIAMETER_Templates.ttcn, line 423 */
if (inp.get_istemplate_kind((const char*)cs_1)) {
current_location.update_lineno(424);
/* DIAMETER_Templates.ttcn, line 424 */
return INTEGER_template(OMIT_VALUE);
}
else {
current_location.update_lineno(425);
/* DIAMETER_Templates.ttcn, line 425 */
if (inp.get_istemplate_kind((const char*)cs_2)) {
current_location.update_lineno(426);
/* DIAMETER_Templates.ttcn, line 426 */
return INTEGER_template(ANY_OR_OMIT);
}
else {
current_location.update_lineno(427);
/* DIAMETER_Templates.ttcn, line 427 */
if (inp.get_istemplate_kind((const char*)cs_0)) {
current_location.update_lineno(428);
/* DIAMETER_Templates.ttcn, line 428 */
return INTEGER_template(ANY_VALUE);
}
else {
current_location.update_lineno(430);
/* DIAMETER_Templates.ttcn, line 430 */
return INTEGER_template(DIAMETER__Types::Vendor__Id::enum2int(inp.valueof()));
}
}
}
}

DIAMETER__Types::GenericAVP_template tr__AVP__VendorSpecAppId(const DIAMETER__Types::Vendor__Id_template& vendor__id, const INTEGER_template& auth__app__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 434, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_VendorSpecAppId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_25 = ret_val.avp();
tmp_25.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Vendor__Specific__Application__Id), tr__DIA__Hdr_flags_defval);
{
DIAMETER__Types::AVP__list_template& tmp_26 = tmp_25.avp__data().avp__BASE__NONE__Vendor__Specific__Application__Id();
tmp_26.set_size(2);
{
DIAMETER__Types::AVP_template& tmp_27 = tmp_26[0].avp();
tmp_27.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Vendor__Id), tr__DIA__Hdr_flags_defval);
tmp_27.avp__data().avp__BASE__NONE__Vendor__Id() = Osmocom__Types::int2oct__tmpl(enum2int__Vendor__Id__tmpl(vendor__id), 4);
}
{
DIAMETER__Types::AVP_template& tmp_28 = tmp_26[1].avp();
tmp_28.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Auth__Application__Id), tr__DIA__Hdr_flags_defval);
tmp_28.avp__data().avp__BASE__NONE__Auth__Application__Id() = Osmocom__Types::int2oct__tmpl(auth__app__id, 4);
}
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__VendorSpecAppId(const DIAMETER__Types::Vendor__Id& vendor__id, const INTEGER& auth__app__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 459, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_VendorSpecAppId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_29 = ret_val.avp();
tmp_29.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Vendor__Specific__Application__Id), ts__DIA__Hdr_flags_defval);
{
DIAMETER__Types::AVP__list_template& tmp_30 = tmp_29.avp__data().avp__BASE__NONE__Vendor__Specific__Application__Id();
tmp_30.set_size(2);
{
DIAMETER__Types::AVP_template& tmp_31 = tmp_30[0].avp();
tmp_31.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Vendor__Id), ts__DIA__Hdr_flags_defval);
tmp_31.avp__data().avp__BASE__NONE__Vendor__Id() = int2oct(DIAMETER__Types::Vendor__Id::enum2int(vendor__id), 4);
}
{
DIAMETER__Types::AVP_template& tmp_32 = tmp_30[1].avp();
tmp_32.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Auth__Application__Id), ts__DIA__Hdr_flags_defval);
tmp_32.avp__data().avp__BASE__NONE__Auth__Application__Id() = int2oct(auth__app__id, 4);
}
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__AuthAppId(const OCTETSTRING_template& auth__app__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 484, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_AuthAppId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_33 = ret_val.avp();
tmp_33.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Auth__Application__Id), ts__DIA__Hdr_flags_defval);
tmp_33.avp__data().avp__BASE__NONE__Auth__Application__Id() = auth__app__id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__AuthAppId(const OCTETSTRING_template& auth__app__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 492, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_AuthAppId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_34 = ret_val.avp();
tmp_34.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Auth__Application__Id), tr__DIA__Hdr_flags_defval);
tmp_34.avp__data().avp__BASE__NONE__Auth__Application__Id() = auth__app__id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__CcReqType(const DIAMETER__Types::DCC__NONE__CC__Request__Type_template& r)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 501, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_CcReqType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_35 = ret_val.avp();
tmp_35.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__CC__Request__Type), ts__DIA__Hdr_flags_defval);
tmp_35.avp__data().avp__DCC__NONE__CC__Request__Type() = r;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__CcReqType(const DIAMETER__Types::DCC__NONE__CC__Request__Type_template& r)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 509, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_CcReqType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_36 = ret_val.avp();
tmp_36.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__CC__Request__Type), tr__DIA__Hdr_flags_defval);
tmp_36.avp__data().avp__DCC__NONE__CC__Request__Type() = r;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__CcReqNum(const OCTETSTRING_template& n)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 518, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_CcReqNum");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_37 = ret_val.avp();
tmp_37.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__CC__Request__Number), ts__DIA__Hdr_flags_defval);
tmp_37.avp__data().avp__DCC__NONE__CC__Request__Number() = n;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__CcReqNum(const OCTETSTRING_template& n)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 526, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_CcReqNum");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_38 = ret_val.avp();
tmp_38.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__CC__Request__Number), tr__DIA__Hdr_flags_defval);
tmp_38.avp__data().avp__DCC__NONE__CC__Request__Number() = n;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__EventTimestamp(const OCTETSTRING_template& n)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 535, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_EventTimestamp");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_39 = ret_val.avp();
tmp_39.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Event__Timestamp), tr__DIA__Hdr_flags_defval);
tmp_39.avp__data().avp__BASE__NONE__Event__Timestamp() = n;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__ExperimentalResultCode(const OCTETSTRING_template& n)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 544, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_ExperimentalResultCode");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_40 = ret_val.avp();
tmp_40.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Experimental__Result__Code), tr__DIA__Hdr_flags_defval);
tmp_40.avp__data().avp__BASE__NONE__Experimental__Result__Code() = n;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__ExperimentalResultCode(const OCTETSTRING_template& n)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 552, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_ExperimentalResultCode");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_41 = ret_val.avp();
tmp_41.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Experimental__Result__Code), ts__DIA__Hdr_flags_defval);
tmp_41.avp__data().avp__BASE__NONE__Experimental__Result__Code() = n;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__ExperimentalResult(const DIAMETER__Types::Vendor__Id_template& vendor__id, const OCTETSTRING_template& err__code)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 561, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_ExperimentalResult");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_42 = ret_val.avp();
tmp_42.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Experimental__Result), tr__DIA__Hdr_flags_defval);
{
DIAMETER__Types::AVP__list_template& tmp_43 = tmp_42.avp__data().avp__BASE__NONE__Experimental__Result();
tmp_43.set_size(2);
tmp_43[0] = tr__AVP__VendorId(vendor__id);
tmp_43[1] = tr__AVP__ExperimentalResultCode(err__code);
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__ExperimentalResult(const DIAMETER__Types::Vendor__Id_template& vendor__id, const OCTETSTRING_template& err__code)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 574, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_ExperimentalResult");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_44 = ret_val.avp();
tmp_44.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Experimental__Result), ts__DIA__Hdr_flags_defval);
{
DIAMETER__Types::AVP__list_template& tmp_45 = tmp_44.avp__data().avp__BASE__NONE__Experimental__Result();
tmp_45.set_size(2);
tmp_45[0] = ts__AVP__VendorId(vendor__id);
tmp_45[1] = ts__AVP__ExperimentalResultCode(err__code);
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__SuppVendorIdRaw(const INTEGER& vendor__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 588, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_SuppVendorIdRaw");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_46 = ret_val.avp();
tmp_46.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Supported__Vendor__Id), ts__DIA__Hdr_flags_defval);
tmp_46.avp__data().avp__BASE__NONE__Supported__Vendor__Id() = int2oct(vendor__id, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__SuppVendorId(const DIAMETER__Types::Vendor__Id& vendor__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 596, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_SuppVendorId");
DIAMETER__Types::GenericAVP_template ret_val;
ret_val = ts__AVP__SuppVendorIdRaw(DIAMETER__Types::Vendor__Id::enum2int(vendor__id));
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__ResultCode(const DIAMETER__Resultcode_template& res__code)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 599, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_ResultCode");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_47 = ret_val.avp();
tmp_47.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Result__Code), ts__DIA__Hdr_flags_defval);
tmp_47.avp__data().avp__BASE__NONE__Result__Code() = int2oct(DIAMETER__Resultcode::enum2int(res__code.valueof()), 4);
}
return ret_val;
}

OCTETSTRING_template f__tr__DIAMETER__Resultcode(const DIAMETER__Resultcode_template& res__code)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 607, TTCN_Location::LOCATION_FUNCTION, "f_tr_DIAMETER_Resultcode");
current_location.update_lineno(609);
/* DIAMETER_Templates.ttcn, line 609 */
if (res__code.get_istemplate_kind((const char*)cs_0)) {
current_location.update_lineno(610);
/* DIAMETER_Templates.ttcn, line 610 */
return OCTETSTRING_template(ANY_VALUE);
}
else {
current_location.update_lineno(612);
/* DIAMETER_Templates.ttcn, line 612 */
OCTETSTRING_template c;
current_location.update_lineno(613);
/* DIAMETER_Templates.ttcn, line 613 */
c = int2oct(DIAMETER__Resultcode::enum2int(res__code.valueof()), 4);
current_location.update_lineno(614);
/* DIAMETER_Templates.ttcn, line 614 */
return c;
}
}

DIAMETER__Types::GenericAVP_template tr__AVP__ResultCode(const DIAMETER__Resultcode_template& res__code)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 617, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_ResultCode");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_49 = ret_val.avp();
tmp_49.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Result__Code), tr__DIA__Hdr_flags_defval);
tmp_49.avp__data().avp__BASE__NONE__Result__Code() = f__tr__DIAMETER__Resultcode(res__code);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__AuthSessionState(const DIAMETER__Types::BASE__NONE__Auth__Session__State_template& ass)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 626, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_AuthSessionState");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_50 = ret_val.avp();
tmp_50.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Auth__Session__State), ts__DIA__Hdr_flags_defval);
tmp_50.avp__data().avp__BASE__NONE__Auth__Session__State() = ass;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__AuthSessionState(const DIAMETER__Types::BASE__NONE__Auth__Session__State_template& ass)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 634, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_AuthSessionState");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_51 = ret_val.avp();
tmp_51.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Auth__Session__State), tr__DIA__Hdr_flags_defval);
tmp_51.avp__data().avp__BASE__NONE__Auth__Session__State() = ass;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__SessionId(const OCTETSTRING_template& session__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 643, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_SessionId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_52 = ret_val.avp();
tmp_52.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Session__Id), ts__DIA__Hdr_flags_defval);
tmp_52.avp__data().avp__BASE__NONE__Session__Id() = session__id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__SessionId(const OCTETSTRING_template& session__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 651, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_SessionId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_53 = ret_val.avp();
tmp_53.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Session__Id), tr__DIA__Hdr_flags_defval);
tmp_53.avp__data().avp__BASE__NONE__Session__Id() = session__id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__DestinationHost(const CHARSTRING_template& dest__host)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 660, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_DestinationHost");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_54 = ret_val.avp();
tmp_54.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Destination__Host), ts__DIA__Hdr_flags_defval);
tmp_54.avp__data().avp__BASE__NONE__Destination__Host() = dest__host;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__DestinationHost(const CHARSTRING_template& host)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 668, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_DestinationHost");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_55 = ret_val.avp();
tmp_55.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Destination__Host), tr__DIA__Hdr_flags_defval);
tmp_55.avp__data().avp__BASE__NONE__Destination__Host() = host;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__DestinationRealm(const CHARSTRING_template& dest__realm)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 678, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_DestinationRealm");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_56 = ret_val.avp();
tmp_56.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Destination__Realm), ts__DIA__Hdr_flags_defval);
tmp_56.avp__data().avp__BASE__NONE__Destination__Realm() = dest__realm;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__DestinationRealm(const CHARSTRING_template& dest__realm)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 686, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_DestinationRealm");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_57 = ret_val.avp();
tmp_57.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Destination__Realm), tr__DIA__Hdr_flags_defval);
tmp_57.avp__data().avp__BASE__NONE__Destination__Realm() = dest__realm;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__UserName(const OCTETSTRING_template& uid)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 696, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_UserName");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_58 = ret_val.avp();
tmp_58.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__User__Name), ts__DIA__Hdr_flags_defval);
tmp_58.avp__data().avp__BASE__NONE__User__Name() = uid;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__UserName(const OCTETSTRING_template& uid)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 704, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_UserName");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_59 = ret_val.avp();
tmp_59.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__User__Name), tr__DIA__Hdr_flags_defval);
tmp_59.avp__data().avp__BASE__NONE__User__Name() = uid;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__UserNameImsi(const HEXSTRING_template& imsi)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 712, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_UserNameImsi");
DIAMETER__Types::GenericAVP_template ret_val;
ret_val = ts__AVP__UserName(OCTETSTRING_template(char2oct(hex2str(imsi.valueof()))));
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__UserNameImsi(const HEXSTRING_template& imsi)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 713, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_UserNameImsi");
DIAMETER__Types::GenericAVP_template ret_val;
{
OCTETSTRING_template tmp_60;
tmp_60 = Osmocom__Types::char2oct__tmpl(Osmocom__Types::hex2str__tmpl(imsi));
tmp_60.check_restriction(TR_PRESENT);
ret_val = tr__AVP__UserName(tmp_60);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__NumOfReqVectors(const OCTETSTRING_template& num__req)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 716, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_NumOfReqVectors");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_61 = ret_val.avp();
tmp_61.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__AAA__3GPP__Number__Of__Requested__Vectors), ts__DIA__Hdr__3GPP_flags_defval);
tmp_61.avp__data().avp__AAA__3GPP__Number__Of__Requested__Vectors() = num__req;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__ImmReqPref(const OCTETSTRING_template& par)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 725, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_ImmReqPref");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_62 = ret_val.avp();
tmp_62.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__AAA__3GPP__Immediate__Response__Preferred), ts__DIA__Hdr__3GPP_flags_defval);
tmp_62.avp__data().avp__AAA__3GPP__Immediate__Response__Preferred() = par;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__RequestedEutranAuthInfo(const OCTETSTRING_template& num__vec)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 736, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_RequestedEutranAuthInfo");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_63 = ret_val.avp();
tmp_63.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__AAA__3GPP__Requested__EUTRAN__Authentication__Info), ts__DIA__Hdr__3GPP_flags_defval);
{
DIAMETER__Types::AVP__list_template& tmp_64 = tmp_63.avp__data().avp__AAA__3GPP__Requested__EUTRAN__Authentication__Info();
tmp_64.set_size(2);
tmp_64[0] = ts__AVP__NumOfReqVectors(num__vec);
tmp_64[1] = ts__AVP__ImmReqPref(OCTETSTRING_template(os_1));
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SubscrRauTauTmr(const INTEGER_template& tmr)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 748, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SubscrRauTauTmr");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_65 = ret_val.avp();
tmp_65.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__AAA__3GPP__Subscribed__Periodic__RAU__TAU__Timer), tr__DIA__Hdr__3GPP_flags_defval);
tmp_65.avp__data().avp__AAA__3GPP__Subscribed__Periodic__RAU__TAU__Timer() = Osmocom__Types::int2oct__tmpl(tmr, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__SubscrRauTauTmr(const INTEGER& tmr)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 757, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_SubscrRauTauTmr");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_66 = ret_val.avp();
tmp_66.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__AAA__3GPP__Subscribed__Periodic__RAU__TAU__Timer), ts__DIA__Hdr__3GPP_flags_defval);
tmp_66.avp__data().avp__AAA__3GPP__Subscribed__Periodic__RAU__TAU__Timer() = int2oct(tmr, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__PCC__3GPP__QoS__Information(const DIAMETER__Types::AVP__list_template& list)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 766, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_PCC_3GPP_QoS_Information");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_67 = ret_val.avp();
tmp_67.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__QoS__Information), tr__DIA__Hdr__3GPP_flags_defval);
tmp_67.avp__data().avp__PCC__3GPP__QoS__Information() = list;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__PCC__3GPP__QoS__Information(const DIAMETER__Types::AVP__list_template& list)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 775, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_PCC_3GPP_QoS_Information");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_68 = ret_val.avp();
tmp_68.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__QoS__Information), ts__DIA__Hdr__3GPP_flags_defval);
tmp_68.avp__data().avp__PCC__3GPP__QoS__Information() = list;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__PCC__3GPP__APN__Aggregate__Max__Bitrate__DL(const INTEGER& val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 784, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_PCC_3GPP_APN_Aggregate_Max_Bitrate_DL");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_69 = ret_val.avp();
tmp_69.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__APN__Aggregate__Max__Bitrate__DL), ts__DIA__Hdr__3GPP_flags_defval);
tmp_69.avp__data().avp__PCC__3GPP__APN__Aggregate__Max__Bitrate__DL() = int2oct(val, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__PCC__3GPP__APN__Aggregate__Max__Bitrate__UL(const INTEGER& val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 793, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_PCC_3GPP_APN_Aggregate_Max_Bitrate_UL");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_70 = ret_val.avp();
tmp_70.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__APN__Aggregate__Max__Bitrate__UL), ts__DIA__Hdr__3GPP_flags_defval);
tmp_70.avp__data().avp__PCC__3GPP__APN__Aggregate__Max__Bitrate__UL() = int2oct(val, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__PCC__3GPP__Default__EPS__Bearer__QoS(const DIAMETER__Types::AVP__list_template& list)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 802, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_PCC_3GPP_Default_EPS_Bearer_QoS");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_71 = ret_val.avp();
tmp_71.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__Default__EPS__Bearer__QoS), ts__DIA__Hdr__3GPP_flags_defval);
tmp_71.avp__data().avp__PCC__3GPP__Default__EPS__Bearer__QoS() = list;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__PCC__3GPP__QoS__Class__Identifier(const INTEGER_template& val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 811, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_PCC_3GPP_QoS_Class_Identifier");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_72 = ret_val.avp();
tmp_72.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__QoS__Class__Identifier), tr__DIA__Hdr__3GPP_flags_defval);
tmp_72.avp__data().avp__PCC__3GPP__QoS__Class__Identifier() = Osmocom__Types::int2oct__tmpl(val, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__PCC__3GPP__QoS__Class__Identifier(const INTEGER& val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 820, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_PCC_3GPP_QoS_Class_Identifier");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_73 = ret_val.avp();
tmp_73.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__QoS__Class__Identifier), ts__DIA__Hdr__3GPP_flags_defval);
tmp_73.avp__data().avp__PCC__3GPP__QoS__Class__Identifier() = int2oct(val, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__PriorityLevel(const INTEGER_template& prio)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 829, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_PriorityLevel");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_74 = ret_val.avp();
tmp_74.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__Priority__Level), tr__DIA__Hdr__3GPP_flags_defval);
tmp_74.avp__data().avp__PCC__3GPP__Priority__Level() = Osmocom__Types::int2oct__tmpl(prio, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__PriorityLevel(const INTEGER& prio)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 838, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_PriorityLevel");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_75 = ret_val.avp();
tmp_75.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__Priority__Level), ts__DIA__Hdr__3GPP_flags_defval);
tmp_75.avp__data().avp__PCC__3GPP__Priority__Level() = int2oct(prio, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__PCC__3GPP__AllocRetenPrio(const INTEGER_template& prio)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 847, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_PCC_3GPP_AllocRetenPrio");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_76 = ret_val.avp();
tmp_76.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__Allocation__Retention__Priority), tr__DIA__Hdr__3GPP_flags_defval);
{
DIAMETER__Types::AVP__list_template& tmp_77 = tmp_76.avp__data().avp__PCC__3GPP__Allocation__Retention__Priority();
tmp_77.set_type(SUPERSET_MATCH, 1);
tmp_77.set_item(0) = tr__AVP__3GPP__PriorityLevel(prio);
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__PCC__3GPP__AllocRetenPrio(const INTEGER& prio)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 859, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_PCC_3GPP_AllocRetenPrio");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_78 = ret_val.avp();
tmp_78.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__PCC__3GPP__Allocation__Retention__Priority), ts__DIA__Hdr__3GPP_flags_defval);
{
DIAMETER__Types::AVP__list_template& tmp_79 = tmp_78.avp__data().avp__PCC__3GPP__Allocation__Retention__Priority();
tmp_79.set_size(1);
tmp_79[0] = ts__AVP__3GPP__PriorityLevel(prio);
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__EpsSubscrQosProfile(const INTEGER_template& qos__class, const INTEGER_template& prio)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 873, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_EpsSubscrQosProfile");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_80 = ret_val.avp();
tmp_80.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__AAA__3GPP__EPS__Subscribed__QoS__Profile), tr__DIA__Hdr__3GPP_flags_defval);
{
DIAMETER__Types::AVP__list_template& tmp_81 = tmp_80.avp__data().avp__AAA__3GPP__EPS__Subscribed__QoS__Profile();
tmp_81.set_type(SUPERSET_MATCH, 2);
tmp_81.set_item(0) = tr__AVP__PCC__3GPP__QoS__Class__Identifier(qos__class);
tmp_81.set_item(1) = tr__AVP__PCC__3GPP__AllocRetenPrio(prio);
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__EpsSubscrQosProfile(const INTEGER& qos__class, const INTEGER& prio)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 886, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_EpsSubscrQosProfile");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_82 = ret_val.avp();
tmp_82.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__AAA__3GPP__EPS__Subscribed__QoS__Profile), ts__DIA__Hdr__3GPP_flags_defval);
{
DIAMETER__Types::AVP__list_template& tmp_83 = tmp_82.avp__data().avp__AAA__3GPP__EPS__Subscribed__QoS__Profile();
tmp_83.set_size(2);
tmp_83[0] = ts__AVP__PCC__3GPP__QoS__Class__Identifier(qos__class);
tmp_83[1] = ts__AVP__PCC__3GPP__AllocRetenPrio(prio);
}
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__Reporting__Reason(const DIAMETER__Types::DCA__3GPP__Reporting__Reason_template& r)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 898, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_Reporting_Reason");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_84 = ret_val.avp();
tmp_84.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCA__3GPP__Reporting__Reason), tr__DIA__Hdr__3GPP_flags_defval);
tmp_84.avp__data().avp__DCA__3GPP__Reporting__Reason() = r;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__AoCRequestType(const DIAMETER__Types::DCA__3GPP__AoC__Request__Type_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 907, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_AoCRequestType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_85 = ret_val.avp();
tmp_85.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCA__3GPP__AoC__Request__Type), tr__DIA__Hdr__3GPP_flags_defval);
tmp_85.avp__data().avp__DCA__3GPP__AoC__Request__Type() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__ServiceInformation(const DIAMETER__Types::AVP__list_template& content)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 916, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_ServiceInformation");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_86 = ret_val.avp();
tmp_86.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCA__3GPP__Service__Information), tr__DIA__Hdr__3GPP_flags_defval);
tmp_86.avp__data().avp__DCA__3GPP__Service__Information() = content;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__PSInformation(const DIAMETER__Types::AVP__list_template& content)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 925, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_PSInformation");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_87 = ret_val.avp();
tmp_87.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCA__3GPP__PS__Information), tr__DIA__Hdr__3GPP_flags_defval);
tmp_87.avp__data().avp__DCA__3GPP__PS__Information() = content;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__ChargingId(const OCTETSTRING_template& id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 934, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_ChargingId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_88 = ret_val.avp();
tmp_88.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__GI__3GPP__3GPP__Charging__Id), tr__DIA__Hdr__3GPP_flags_defval);
tmp_88.avp__data().avp__GI__3GPP__3GPP__Charging__Id() = id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__PDPType(const DIAMETER__Types::GI__3GPP__3GPP__PDP__Type_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 943, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_PDPType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_89 = ret_val.avp();
tmp_89.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__GI__3GPP__3GPP__PDP__Type), tr__DIA__Hdr__3GPP_flags_defval);
tmp_89.avp__data().avp__GI__3GPP__3GPP__PDP__Type() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__PDPAddress(const DIAMETER__Types::AVP__Address_template& addr)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 952, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_PDPAddress");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_90 = ret_val.avp();
tmp_90.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCA__3GPP__PDP__Address), tr__DIA__Hdr__3GPP_flags_defval);
tmp_90.avp__data().avp__DCA__3GPP__PDP__Address() = addr;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SGSNAddress(const DIAMETER__Types::AVP__Address_template& addr)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 961, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SGSNAddress");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_91 = ret_val.avp();
tmp_91.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCA__3GPP__SGSN__Address), tr__DIA__Hdr__3GPP_flags_defval);
tmp_91.avp__data().avp__DCA__3GPP__SGSN__Address() = addr;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__GGSNAddress(const DIAMETER__Types::AVP__Address_template& addr)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 970, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_GGSNAddress");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_92 = ret_val.avp();
tmp_92.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCA__3GPP__GGSN__Address), tr__DIA__Hdr__3GPP_flags_defval);
tmp_92.avp__data().avp__DCA__3GPP__GGSN__Address() = addr;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SelectionMode(const OCTETSTRING_template& sm)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 979, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SelectionMode");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_93 = ret_val.avp();
tmp_93.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__GI__3GPP__3GPP__Selection__Mode), tr__DIA__Hdr__3GPP_flags_defval);
tmp_93.avp__data().avp__GI__3GPP__3GPP__Selection__Mode() = sm;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__ChargingCharacteristics(const OCTETSTRING_template& cc)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 988, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_ChargingCharacteristics");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_94 = ret_val.avp();
tmp_94.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__GI__3GPP__3GPP__Charging__Characteristics), tr__DIA__Hdr__3GPP_flags_defval);
tmp_94.avp__data().avp__GI__3GPP__3GPP__Charging__Characteristics() = cc;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SGSNMCCMNC(const OCTETSTRING_template& smn)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 997, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SGSNMCCMNC");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_95 = ret_val.avp();
tmp_95.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__GI__3GPP__3GPP__SGSN__MCC__MNC), tr__DIA__Hdr__3GPP_flags_defval);
tmp_95.avp__data().avp__GI__3GPP__3GPP__SGSN__MCC__MNC() = smn;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__NSAPI(const OCTETSTRING_template& nsapi)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1006, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_NSAPI");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_96 = ret_val.avp();
tmp_96.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__GI__3GPP__3GPP__NSAPI), tr__DIA__Hdr__3GPP_flags_defval);
tmp_96.avp__data().avp__GI__3GPP__3GPP__NSAPI() = nsapi;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__MS__TimeZone(const OCTETSTRING_template& ms__tz)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1015, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_MS_TimeZone");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_97 = ret_val.avp();
tmp_97.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__GI__3GPP__3GPP__MS__TimeZone), tr__DIA__Hdr__3GPP_flags_defval);
tmp_97.avp__data().avp__GI__3GPP__3GPP__MS__TimeZone() = ms__tz;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__ULI(const OCTETSTRING_template& uli)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1024, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_ULI");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_98 = ret_val.avp();
tmp_98.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__GI__3GPP__3GPP__User__Location__Info), tr__DIA__Hdr__3GPP_flags_defval);
tmp_98.avp__data().avp__GI__3GPP__3GPP__User__Location__Info() = uli;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__UserEquipmentInfo(const DIAMETER__Types::AVP__list_template& uei)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1033, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_UserEquipmentInfo");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_99 = ret_val.avp();
tmp_99.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__User__Equipment__Info), tr__DIA__Hdr_flags_defval);
tmp_99.avp__data().avp__DCC__NONE__User__Equipment__Info() = uei;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__UserEquipmentInfoType(const DIAMETER__Types::DCC__NONE__User__Equipment__Info__Type_template& ueit)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1042, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_UserEquipmentInfoType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_100 = ret_val.avp();
tmp_100.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__User__Equipment__Info__Type), tr__DIA__Hdr_flags_defval);
tmp_100.avp__data().avp__DCC__NONE__User__Equipment__Info__Type() = ueit;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__UserEquipmentInfoValue(const OCTETSTRING_template& ueiv)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1051, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_UserEquipmentInfoValue");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_101 = ret_val.avp();
tmp_101.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__User__Equipment__Info__Value), tr__DIA__Hdr_flags_defval);
tmp_101.avp__data().avp__DCC__NONE__User__Equipment__Info__Value() = ueiv;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__Multiple__Services__Credit__Control(const DIAMETER__Types::AVP__list_template& content)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1061, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_Multiple_Services_Credit_Control");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_102 = ret_val.avp();
tmp_102.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Multiple__Services__Credit__Control), ts__DIA__Hdr_flags_defval);
tmp_102.avp__data().avp__DCC__NONE__Multiple__Services__Credit__Control() = content;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__Multiple__Services__Credit__Control(const DIAMETER__Types::AVP__list_template& content)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1069, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_Multiple_Services_Credit_Control");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_103 = ret_val.avp();
tmp_103.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Multiple__Services__Credit__Control), tr__DIA__Hdr_flags_defval);
tmp_103.avp__data().avp__DCC__NONE__Multiple__Services__Credit__Control() = content;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__Requested__Service__Unit(const DIAMETER__Types::AVP__list_template& content)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1079, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_Requested_Service_Unit");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_104 = ret_val.avp();
tmp_104.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Requested__Service__Unit), tr__DIA__Hdr_flags_defval);
tmp_104.avp__data().avp__DCC__NONE__Requested__Service__Unit() = content;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__Used__Service__Unit(const DIAMETER__Types::AVP__list_template& content)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1089, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_Used_Service_Unit");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_105 = ret_val.avp();
tmp_105.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Used__Service__Unit), tr__DIA__Hdr_flags_defval);
tmp_105.avp__data().avp__DCC__NONE__Used__Service__Unit() = content;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__Granted__Service__Unit(const DIAMETER__Types::AVP__list_template& content)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1099, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_Granted_Service_Unit");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_106 = ret_val.avp();
tmp_106.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Granted__Service__Unit), ts__DIA__Hdr_flags_defval);
tmp_106.avp__data().avp__DCC__NONE__Granted__Service__Unit() = content;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__CC__Time(const INTEGER& cc__time__val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1109, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_CC_Time");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_107 = ret_val.avp();
tmp_107.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__CC__Time), ts__DIA__Hdr_flags_defval);
tmp_107.avp__data().avp__DCC__NONE__CC__Time() = int2oct(cc__time__val, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__CC__Total__Octets(const INTEGER& cc__total__octets__val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1119, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_CC_Total_Octets");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_108 = ret_val.avp();
tmp_108.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__CC__Total__Octets), ts__DIA__Hdr_flags_defval);
tmp_108.avp__data().avp__DCC__NONE__CC__Total__Octets() = int2oct(cc__total__octets__val, 8);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__Validity__Time(const INTEGER& validity__time__val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1129, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_Validity_Time");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_109 = ret_val.avp();
tmp_109.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCC__NONE__Validity__Time), ts__DIA__Hdr_flags_defval);
tmp_109.avp__data().avp__DCC__NONE__Validity__Time() = int2oct(validity__time__val, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__VolumeQuotaThreshold(const INTEGER& volume__quota__thresh__val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1138, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_VolumeQuotaThreshold");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_110 = ret_val.avp();
tmp_110.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DCA__3GPP__Volume__Quota__Threshold), ts__DIA__Hdr__3GPP_flags_defval);
tmp_110.avp__data().avp__DCA__3GPP__Volume__Quota__Threshold() = int2oct(volume__quota__thresh__val, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__CalledStationId(const OCTETSTRING_template& id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1147, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_CalledStationId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_111 = ret_val.avp();
tmp_111.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DNAS__NONE__Called__Station__Id), tr__DIA__Hdr_flags_defval);
tmp_111.avp__data().avp__DNAS__NONE__Called__Station__Id() = id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__CalledStationId(const OCTETSTRING_template& id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1155, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_CalledStationId");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_112 = ret_val.avp();
tmp_112.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__DNAS__NONE__Called__Station__Id), ts__DIA__Hdr_flags_defval);
tmp_112.avp__data().avp__DNAS__NONE__Called__Station__Id() = id;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__AuthRequestType(const DIAMETER__Types::BASE__NONE__Auth__Request__Type& auth__req__type)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1165, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_AuthRequestType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_113 = ret_val.avp();
tmp_113.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Auth__Request__Type), BITSTRING_template(bs_2));
tmp_113.avp__data().avp__BASE__NONE__Auth__Request__Type() = auth__req__type;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__AuthRequestType(const DIAMETER__Types::BASE__NONE__Auth__Request__Type_template& auth__req__type)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1173, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_AuthRequestType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_114 = ret_val.avp();
tmp_114.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Auth__Request__Type), tr__DIA__Hdr_flags_defval);
tmp_114.avp__data().avp__BASE__NONE__Auth__Request__Type() = auth__req__type;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__ReAuthRequestType(const DIAMETER__Types::BASE__NONE__Re__Auth__Request__Type& reauth__req__type)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1183, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_ReAuthRequestType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_115 = ret_val.avp();
tmp_115.avp__header() = ts__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Re__Auth__Request__Type), BITSTRING_template(bs_2));
tmp_115.avp__data().avp__BASE__NONE__Re__Auth__Request__Type() = reauth__req__type;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__ReAuthRequestType(const DIAMETER__Types::BASE__NONE__Re__Auth__Request__Type_template& reauth__req__type)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1191, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_ReAuthRequestType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_116 = ret_val.avp();
tmp_116.avp__header() = tr__DIA__Hdr(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__BASE__NONE__Re__Auth__Request__Type), tr__DIA__Hdr_flags_defval);
tmp_116.avp__data().avp__BASE__NONE__Re__Auth__Request__Type() = reauth__req__type;
}
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template ts__DIA__CER(const OCTETSTRING& host__ip, const INTEGER& vendor__app__id, const CHARSTRING_template& orig__host, const CHARSTRING_template& orig__realm, const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1201, TTCN_Location::LOCATION_TEMPLATE, "ts_DIA_CER");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
{
DIAMETER__Types::AVP__list_template tmp_117;
tmp_117.set_size(9);
tmp_117[0] = ts__AVP__OriginHost(orig__host);
tmp_117[1] = ts__AVP__OriginRealm(orig__realm);
tmp_117[2] = ts__AVP__HostIpAddr(OCTETSTRING_template(host__ip));
tmp_117[3] = ts__AVP__VendorId(DIAMETER__Types::Vendor__Id_template(DIAMETER__Types::Vendor__Id::vendor__id__3GPP));
tmp_117[4] = ts__AVP__ProductName(cs_3);
tmp_117[5] = ts__AVP__FwRevision(os_1);
tmp_117[6] = ts__AVP__InbSecId(OCTETSTRING_template(os_1));
tmp_117[7] = ts__AVP__AuthAppId(OCTETSTRING_template(os_3));
tmp_117[8] = ts__AVP__VendorSpecAppId(DIAMETER__Types::Vendor__Id::vendor__id__3GPP, vendor__app__id);
ret_val = ts__DIAMETER(BITSTRING_template(bs_3), DIAMETER__Types::Command__Code_template(DIAMETER__Types::Command__Code::Capabilities__Exchange), ts__DIAMETER_app__id_defval, hbh__id, ete__id, tmp_117);
}
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template ts__DIA__CEA__AUTH__APP__ID(const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id, const CHARSTRING_template& origin__host, const CHARSTRING_template& origin__realm, const OCTETSTRING_template& host__ip, const INTEGER& auth__app__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1225, TTCN_Location::LOCATION_TEMPLATE, "ts_DIA_CEA_AUTH_APP_ID");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
{
DIAMETER__Types::AVP__list_template tmp_118;
tmp_118.set_size(12);
tmp_118[0] = ts__AVP__ResultCode(DIAMETER__Resultcode_template(DIAMETER__Resultcode::DIAMETER__SUCCESS));
tmp_118[1] = ts__AVP__OriginHost(origin__host);
tmp_118[2] = ts__AVP__OriginRealm(origin__realm);
tmp_118[3] = ts__AVP__HostIpAddr(host__ip);
tmp_118[4] = ts__AVP__VendorId(DIAMETER__Types::Vendor__Id_template(DIAMETER__Types::Vendor__Id::vendor__id__3GPP));
tmp_118[5] = ts__AVP__ProductName(cs_3);
tmp_118[6] = ts__AVP__OriginStateId(OCTETSTRING_template(os_4));
tmp_118[7] = ts__AVP__SuppVendorIdRaw(5535);
tmp_118[8] = ts__AVP__SuppVendorId(DIAMETER__Types::Vendor__Id::vendor__id__3GPP);
tmp_118[9] = ts__AVP__SuppVendorIdRaw(13019);
tmp_118[10] = ts__AVP__AuthAppId(OCTETSTRING_template(int2oct(auth__app__id, 4)));
tmp_118[11] = ts__AVP__InbSecId(OCTETSTRING_template(os_1));
ret_val = ts__DIAMETER(BITSTRING_template(bs_2), DIAMETER__Types::Command__Code_template(DIAMETER__Types::Command__Code::Capabilities__Exchange), ts__DIAMETER_app__id_defval, hbh__id, ete__id, tmp_118);
}
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template ts__DIA__CEA__VENDOR__APP__ID(const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id, const CHARSTRING_template& origin__host, const CHARSTRING_template& origin__realm, const OCTETSTRING_template& host__ip, const INTEGER& vendor__app__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1245, TTCN_Location::LOCATION_TEMPLATE, "ts_DIA_CEA_VENDOR_APP_ID");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
{
DIAMETER__Types::AVP__list_template tmp_119;
tmp_119.set_size(12);
tmp_119[0] = ts__AVP__ResultCode(DIAMETER__Resultcode_template(DIAMETER__Resultcode::DIAMETER__SUCCESS));
tmp_119[1] = ts__AVP__OriginHost(origin__host);
tmp_119[2] = ts__AVP__OriginRealm(origin__realm);
tmp_119[3] = ts__AVP__HostIpAddr(host__ip);
tmp_119[4] = ts__AVP__VendorId(DIAMETER__Types::Vendor__Id_template(DIAMETER__Types::Vendor__Id::vendor__id__3GPP));
tmp_119[5] = ts__AVP__ProductName(cs_3);
tmp_119[6] = ts__AVP__OriginStateId(OCTETSTRING_template(os_4));
tmp_119[7] = ts__AVP__SuppVendorIdRaw(5535);
tmp_119[8] = ts__AVP__SuppVendorId(DIAMETER__Types::Vendor__Id::vendor__id__3GPP);
tmp_119[9] = ts__AVP__SuppVendorIdRaw(13019);
tmp_119[10] = ts__AVP__InbSecId(OCTETSTRING_template(os_1));
tmp_119[11] = ts__AVP__VendorSpecAppId(DIAMETER__Types::Vendor__Id::vendor__id__3GPP, vendor__app__id);
ret_val = ts__DIAMETER(BITSTRING_template(bs_2), DIAMETER__Types::Command__Code_template(DIAMETER__Types::Command__Code::Capabilities__Exchange), ts__DIAMETER_app__id_defval, hbh__id, ete__id, tmp_119);
}
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template f__ts__DIA__CEA(const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id, const CHARSTRING_template& origin__host, const CHARSTRING_template& origin__realm, const OCTETSTRING_template& host__ip, const INTEGER_template& auth__app__id, const INTEGER_template& vendor__app__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1265, TTCN_Location::LOCATION_FUNCTION, "f_ts_DIA_CEA");
current_location.update_lineno(1272);
/* DIAMETER_Templates.ttcn, line 1272 */
DIAMETER__Types::PDU__DIAMETER_template diam__pdu;
current_location.update_lineno(1273);
/* DIAMETER_Templates.ttcn, line 1273 */
if (vendor__app__id.get_istemplate_kind((const char*)cs_1)) {
current_location.update_lineno(1274);
/* DIAMETER_Templates.ttcn, line 1274 */
diam__pdu = ts__DIA__CEA__AUTH__APP__ID(hbh__id, ete__id, origin__host, origin__realm, host__ip, auth__app__id.valueof());
}
else {
current_location.update_lineno(1276);
/* DIAMETER_Templates.ttcn, line 1276 */
diam__pdu = ts__DIA__CEA__VENDOR__APP__ID(hbh__id, ete__id, origin__host, origin__realm, host__ip, vendor__app__id.valueof());
}
current_location.update_lineno(1278);
/* DIAMETER_Templates.ttcn, line 1278 */
return diam__pdu;
}

DIAMETER__Types::PDU__DIAMETER_template ts__DIA__DWR(const OCTETSTRING_template& state__id, const CHARSTRING_template& orig__host, const CHARSTRING_template& orig__realm, const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1282, TTCN_Location::LOCATION_TEMPLATE, "ts_DIA_DWR");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
{
DIAMETER__Types::AVP__list_template tmp_122;
tmp_122.set_size(3);
tmp_122[0] = ts__AVP__OriginHost(orig__host);
tmp_122[1] = ts__AVP__OriginRealm(orig__realm);
tmp_122[2] = ts__AVP__OriginStateId(state__id);
ret_val = ts__DIAMETER(BITSTRING_template(bs_3), DIAMETER__Types::Command__Code_template(DIAMETER__Types::Command__Code::Device__Watchdog), OCTETSTRING_template(os_1), hbh__id, ete__id, tmp_122);
}
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template tr__DIA__DWR(const OCTETSTRING_template& , const CHARSTRING_template& orig__host, const CHARSTRING_template& orig__realm, const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1298, TTCN_Location::LOCATION_TEMPLATE, "tr_DIA_DWR");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
{
DIAMETER__Types::AVP__list_template tmp_123;
tmp_123.set_type(SUPERSET_MATCH, 2);
tmp_123.set_item(0) = tr__AVP__OriginHost(orig__host);
tmp_123.set_item(1) = tr__AVP__OriginRealm(orig__realm);
ret_val = tr__DIAMETER(bp_1, DIAMETER__Types::Command__Code_template(DIAMETER__Types::Command__Code::Device__Watchdog), OCTETSTRING_template(os_1), hbh__id, ete__id, tmp_123);
}
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template ts__DIA__DWA(const OCTETSTRING_template& state__id, const CHARSTRING_template& orig__host, const CHARSTRING_template& orig__realm, const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1316, TTCN_Location::LOCATION_TEMPLATE, "ts_DIA_DWA");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
{
DIAMETER__Types::AVP__list_template tmp_124;
tmp_124.set_size(4);
tmp_124[0] = ts__AVP__ResultCode(DIAMETER__Resultcode_template(DIAMETER__Resultcode::DIAMETER__SUCCESS));
tmp_124[1] = ts__AVP__OriginHost(orig__host);
tmp_124[2] = ts__AVP__OriginRealm(orig__realm);
tmp_124[3] = ts__AVP__OriginStateId(state__id);
ret_val = ts__DIAMETER(BITSTRING_template(bs_2), DIAMETER__Types::Command__Code_template(DIAMETER__Types::Command__Code::Device__Watchdog), OCTETSTRING_template(os_1), hbh__id, ete__id, tmp_124);
}
return ret_val;
}

DIAMETER__Types::PDU__DIAMETER_template tr__DIA__DWA(const OCTETSTRING_template& , const CHARSTRING_template& orig__host, const CHARSTRING_template& orig__realm, const OCTETSTRING_template& hbh__id, const OCTETSTRING_template& ete__id)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1333, TTCN_Location::LOCATION_TEMPLATE, "tr_DIA_DWA");
DIAMETER__Types::PDU__DIAMETER_template ret_val;
{
DIAMETER__Types::AVP__list_template tmp_125;
tmp_125.set_type(SUPERSET_MATCH, 3);
tmp_125.set_item(0) = tr__AVP__ResultCode(DIAMETER__Resultcode_template(DIAMETER__Resultcode::DIAMETER__SUCCESS));
tmp_125.set_item(1) = tr__AVP__OriginHost(orig__host);
tmp_125.set_item(2) = tr__AVP__OriginRealm(orig__realm);
ret_val = tr__DIAMETER(bp_0, DIAMETER__Types::Command__Code_template(DIAMETER__Types::Command__Code::Device__Watchdog), OCTETSTRING_template(os_1), hbh__id, ete__id, tmp_125);
}
return ret_val;
}

DIAMETER__Types::AVP_template f__DIAMETER__get__avp(const DIAMETER__Types::PDU__DIAMETER& pdu, const DIAMETER__Types::AVP__Code_template& avp__code)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1351, TTCN_Location::LOCATION_FUNCTION, "f_DIAMETER_get_avp");
current_location.update_lineno(1354);
/* DIAMETER_Templates.ttcn, line 1354 */
INTEGER i;
current_location.update_lineno(1356);
/* DIAMETER_Templates.ttcn, line 1356 */
i = 0;
current_location.update_lineno(1356);
/* DIAMETER_Templates.ttcn, line 1356 */
for ( ; ; ) {
current_location.update_lineno(1356);
/* DIAMETER_Templates.ttcn, line 1356 */
if (!(i < const_cast< const DIAMETER__Types::PDU__DIAMETER&>(pdu).avps().lengthof())) break;
{
current_location.update_lineno(1357);
/* DIAMETER_Templates.ttcn, line 1357 */
{
boolean tmp_135;
{
boolean tmp_128 = pdu.is_bound();
if(tmp_128) {
const DIAMETER__Types::PDU__DIAMETER& tmp_129 = pdu;
const DIAMETER__Types::AVP__list& tmp_130 = tmp_129.avps();
tmp_128 = tmp_130.is_bound();
if(tmp_128) {
const int tmp_131 = i;
tmp_128 = (tmp_131 >= 0) && (tmp_130.size_of() > tmp_131);
if(tmp_128) {
const DIAMETER__Types::GenericAVP& tmp_132 = tmp_130[tmp_131];
tmp_128 = tmp_132.is_bound();
if(tmp_128) {
tmp_128 = tmp_132.ischosen(DIAMETER__Types::GenericAVP::ALT_avp);
}
if(tmp_128) {
const DIAMETER__Types::GenericAVP& tmp_133 = tmp_132;
const DIAMETER__Types::AVP& tmp_134 = tmp_133.avp();
tmp_128 = tmp_134.is_present();
}
}
}
}
tmp_135 = (!(tmp_128));
}
if (tmp_135) {
current_location.update_lineno(1358);
/* DIAMETER_Templates.ttcn, line 1358 */
goto tmp_127;
}
}
current_location.update_lineno(1360);
/* DIAMETER_Templates.ttcn, line 1360 */
DIAMETER__Types::AVP__Header hdr(const_cast< const DIAMETER__Types::PDU__DIAMETER&>(pdu).avps()[i].avp().avp__header());
current_location.update_lineno(1361);
/* DIAMETER_Templates.ttcn, line 1361 */
if (avp__code.match(const_cast< const DIAMETER__Types::AVP__Header&>(hdr).avp__code())) {
current_location.update_lineno(1362);
/* DIAMETER_Templates.ttcn, line 1362 */
return DIAMETER__Types::AVP_template(const_cast< const DIAMETER__Types::PDU__DIAMETER&>(pdu).avps()[i].avp());
}
}
tmp_127:
current_location.update_lineno(1356);
/* DIAMETER_Templates.ttcn, line 1356 */
{
INTEGER tmp_136;
++i;
}
}
current_location.update_lineno(1365);
/* DIAMETER_Templates.ttcn, line 1365 */
return DIAMETER__Types::AVP_template(OMIT_VALUE);
}

DIAMETER__Types::AVP f__DIAMETER__get__avp__or__fail(const DIAMETER__Types::PDU__DIAMETER& pdu, const DIAMETER__Types::AVP__Code_template& avp__code)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1367, TTCN_Location::LOCATION_FUNCTION, "f_DIAMETER_get_avp_or_fail");
current_location.update_lineno(1370);
/* DIAMETER_Templates.ttcn, line 1370 */
DIAMETER__Types::AVP_template avp;
current_location.update_lineno(1371);
/* DIAMETER_Templates.ttcn, line 1371 */
avp = f__DIAMETER__get__avp(pdu, avp__code);
current_location.update_lineno(1372);
/* DIAMETER_Templates.ttcn, line 1372 */
if (avp.get_istemplate_kind((const char*)cs_1)) {
current_location.update_lineno(1373);
/* DIAMETER_Templates.ttcn, line 1373 */
Misc__Helpers::f__shutdown(cs_6, 1373, FAIL, (TTCN_Logger::begin_event_log2str(),TTCN_Logger::log_event_str("AVP "),avp__code.log(),TTCN_Logger::log_event_str(" not found in "),pdu.log(),TTCN_Logger::end_event_log2str()));
}
current_location.update_lineno(1376);
/* DIAMETER_Templates.ttcn, line 1376 */
return avp.valueof();
}

DIAMETER__Types::AVP_template f__AVP__Grouped__get__avp(const DIAMETER__Types::AVP__list& avp__grp, const DIAMETER__Types::AVP__Code_template& avp__code)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1379, TTCN_Location::LOCATION_FUNCTION, "f_AVP_Grouped_get_avp");
current_location.update_lineno(1382);
/* DIAMETER_Templates.ttcn, line 1382 */
INTEGER i;
current_location.update_lineno(1384);
/* DIAMETER_Templates.ttcn, line 1384 */
i = 0;
current_location.update_lineno(1384);
/* DIAMETER_Templates.ttcn, line 1384 */
for ( ; ; ) {
current_location.update_lineno(1384);
/* DIAMETER_Templates.ttcn, line 1384 */
if (!(i < avp__grp.lengthof())) break;
{
current_location.update_lineno(1385);
/* DIAMETER_Templates.ttcn, line 1385 */
{
boolean tmp_145;
{
boolean tmp_140 = avp__grp.is_bound();
if(tmp_140) {
const int tmp_141 = i;
tmp_140 = (tmp_141 >= 0) && (avp__grp.size_of() > tmp_141);
if(tmp_140) {
const DIAMETER__Types::GenericAVP& tmp_142 = avp__grp[tmp_141];
tmp_140 = tmp_142.is_bound();
if(tmp_140) {
tmp_140 = tmp_142.ischosen(DIAMETER__Types::GenericAVP::ALT_avp);
}
if(tmp_140) {
const DIAMETER__Types::GenericAVP& tmp_143 = tmp_142;
const DIAMETER__Types::AVP& tmp_144 = tmp_143.avp();
tmp_140 = tmp_144.is_present();
}
}
}
tmp_145 = (!(tmp_140));
}
if (tmp_145) {
current_location.update_lineno(1386);
/* DIAMETER_Templates.ttcn, line 1386 */
goto tmp_139;
}
}
current_location.update_lineno(1388);
/* DIAMETER_Templates.ttcn, line 1388 */
DIAMETER__Types::AVP__Header hdr(const_cast< const DIAMETER__Types::AVP__list&>(avp__grp)[i].avp().avp__header());
current_location.update_lineno(1389);
/* DIAMETER_Templates.ttcn, line 1389 */
if (avp__code.match(const_cast< const DIAMETER__Types::AVP__Header&>(hdr).avp__code())) {
current_location.update_lineno(1390);
/* DIAMETER_Templates.ttcn, line 1390 */
return DIAMETER__Types::AVP_template(const_cast< const DIAMETER__Types::AVP__list&>(avp__grp)[i].avp());
}
}
tmp_139:
current_location.update_lineno(1384);
/* DIAMETER_Templates.ttcn, line 1384 */
{
INTEGER tmp_146;
++i;
}
}
current_location.update_lineno(1393);
/* DIAMETER_Templates.ttcn, line 1393 */
return DIAMETER__Types::AVP_template(OMIT_VALUE);
}

DIAMETER__Types::AVP f__AVP__Grouped__get__avp__or__fail(const DIAMETER__Types::AVP__list& avp__grp, const DIAMETER__Types::AVP__Code_template& avp__code)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1395, TTCN_Location::LOCATION_FUNCTION, "f_AVP_Grouped_get_avp_or_fail");
current_location.update_lineno(1398);
/* DIAMETER_Templates.ttcn, line 1398 */
DIAMETER__Types::AVP_template avp;
current_location.update_lineno(1399);
/* DIAMETER_Templates.ttcn, line 1399 */
avp = f__AVP__Grouped__get__avp(avp__grp, avp__code);
current_location.update_lineno(1400);
/* DIAMETER_Templates.ttcn, line 1400 */
if (avp.get_istemplate_kind((const char*)cs_1)) {
current_location.update_lineno(1401);
/* DIAMETER_Templates.ttcn, line 1401 */
Misc__Helpers::f__shutdown(cs_6, 1401, FAIL, (TTCN_Logger::begin_event_log2str(),TTCN_Logger::log_event_str("AVP "),avp__code.log(),TTCN_Logger::log_event_str(" not found in "),avp__grp.log(),TTCN_Logger::end_event_log2str()));
}
current_location.update_lineno(1404);
/* DIAMETER_Templates.ttcn, line 1404 */
return avp.valueof();
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SIPNumAuthDataItems(const INTEGER_template& num)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1412, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SIPNumAuthDataItems");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_148 = ret_val.avp();
tmp_148.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Number__Auth__Items), tr__DIA__Hdr__3GPP_flags_defval);
tmp_148.avp__data().avp__CxDx__3GPP__SIP__Number__Auth__Items() = Osmocom__Types::int2oct__tmpl(num, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__SIPNumAuthDataItems(const INTEGER& num)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1420, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_SIPNumAuthDataItems");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_149 = ret_val.avp();
tmp_149.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Number__Auth__Items), ts__DIA__Hdr__3GPP_flags_defval);
tmp_149.avp__data().avp__CxDx__3GPP__SIP__Number__Auth__Items() = int2oct(num, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SIPAuthScheme(const OCTETSTRING_template& scheme)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1430, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SIPAuthScheme");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_150 = ret_val.avp();
tmp_150.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Authentication__Scheme), tr__DIA__Hdr__3GPP_flags_defval);
tmp_150.avp__data().avp__CxDx__3GPP__SIP__Authentication__Scheme() = scheme;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__SIPAuthScheme(const OCTETSTRING_template& scheme)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1438, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_SIPAuthScheme");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_151 = ret_val.avp();
tmp_151.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Authentication__Scheme), ts__DIA__Hdr__3GPP_flags_defval);
tmp_151.avp__data().avp__CxDx__3GPP__SIP__Authentication__Scheme() = scheme;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SIPAuthenticate(const OCTETSTRING_template& rand__autn__concatenated)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1448, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SIPAuthenticate");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_152 = ret_val.avp();
tmp_152.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Authenticate), tr__DIA__Hdr__3GPP_flags_defval);
tmp_152.avp__data().avp__CxDx__3GPP__SIP__Authenticate() = rand__autn__concatenated;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__SIPAuthenticate(const OCTETSTRING_template& rand__autn__concatenated)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1456, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_SIPAuthenticate");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_153 = ret_val.avp();
tmp_153.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Authenticate), ts__DIA__Hdr__3GPP_flags_defval);
tmp_153.avp__data().avp__CxDx__3GPP__SIP__Authenticate() = rand__autn__concatenated;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SIPAuthorization(const OCTETSTRING_template& rand__autn__concatenated)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1466, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SIPAuthorization");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_154 = ret_val.avp();
tmp_154.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Authorization), tr__DIA__Hdr__3GPP_flags_defval);
tmp_154.avp__data().avp__CxDx__3GPP__SIP__Authorization() = rand__autn__concatenated;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__SIPAuthorization(const OCTETSTRING_template& rand__autn__concatenated)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1474, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_SIPAuthorization");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_155 = ret_val.avp();
tmp_155.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Authorization), ts__DIA__Hdr__3GPP_flags_defval);
tmp_155.avp__data().avp__CxDx__3GPP__SIP__Authorization() = rand__autn__concatenated;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SIPAuthContext(const OCTETSTRING_template& val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1484, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SIPAuthContext");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_156 = ret_val.avp();
tmp_156.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Authentication__Context), tr__DIA__Hdr__3GPP_flags_defval);
tmp_156.avp__data().avp__CxDx__3GPP__SIP__Authentication__Context() = val;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__SIPAuthContext(const OCTETSTRING_template& val)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1492, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_SIPAuthContext");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_157 = ret_val.avp();
tmp_157.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Authentication__Context), ts__DIA__Hdr__3GPP_flags_defval);
tmp_157.avp__data().avp__CxDx__3GPP__SIP__Authentication__Context() = val;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__SIPItemNumber(const INTEGER_template& num)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1502, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_SIPItemNumber");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_158 = ret_val.avp();
tmp_158.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Item__Number), tr__DIA__Hdr__3GPP_flags_defval);
tmp_158.avp__data().avp__CxDx__3GPP__SIP__Item__Number() = Osmocom__Types::int2oct__tmpl(num, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__SIPItemNumber(const INTEGER& num)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1510, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_SIPItemNumber");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_159 = ret_val.avp();
tmp_159.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__SIP__Item__Number), ts__DIA__Hdr__3GPP_flags_defval);
tmp_159.avp__data().avp__CxDx__3GPP__SIP__Item__Number() = int2oct(num, 4);
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__ConfidentialityKey(const OCTETSTRING_template& ckey)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1520, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_ConfidentialityKey");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_160 = ret_val.avp();
tmp_160.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__Confidentiality__Key), tr__DIA__Hdr__3GPP_flags_defval);
tmp_160.avp__data().avp__CxDx__3GPP__Confidentiality__Key() = ckey;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__ConfidentialityKey(const OCTETSTRING_template& ckey)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1528, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_ConfidentialityKey");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_161 = ret_val.avp();
tmp_161.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__Confidentiality__Key), ts__DIA__Hdr__3GPP_flags_defval);
tmp_161.avp__data().avp__CxDx__3GPP__Confidentiality__Key() = ckey;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__IntegrityKey(const OCTETSTRING_template& ckey)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1538, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_IntegrityKey");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_162 = ret_val.avp();
tmp_162.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__Integrity__Key), tr__DIA__Hdr__3GPP_flags_defval);
tmp_162.avp__data().avp__CxDx__3GPP__Integrity__Key() = ckey;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__IntegrityKey(const OCTETSTRING_template& ckey)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1546, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_IntegrityKey");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_163 = ret_val.avp();
tmp_163.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__Integrity__Key), ts__DIA__Hdr__3GPP_flags_defval);
tmp_163.avp__data().avp__CxDx__3GPP__Integrity__Key() = ckey;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template tr__AVP__3GPP__ServerAssignmentType(const DIAMETER__Types::CxDx__3GPP__Server__Assignment__Type_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1556, TTCN_Location::LOCATION_TEMPLATE, "tr_AVP_3GPP_ServerAssignmentType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_164 = ret_val.avp();
tmp_164.avp__header() = tr__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__Server__Assignment__Type), tr__DIA__Hdr__3GPP_flags_defval);
tmp_164.avp__data().avp__CxDx__3GPP__Server__Assignment__Type() = t;
}
return ret_val;
}

DIAMETER__Types::GenericAVP_template ts__AVP__3GPP__ServerAssignmentType(const DIAMETER__Types::CxDx__3GPP__Server__Assignment__Type_template& t)
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 1564, TTCN_Location::LOCATION_TEMPLATE, "ts_AVP_3GPP_ServerAssignmentType");
DIAMETER__Types::GenericAVP_template ret_val;
{
DIAMETER__Types::AVP_template& tmp_165 = ret_val.avp();
tmp_165.avp__header() = ts__DIA__Hdr__3GPP(DIAMETER__Types::AVP__Code_template(DIAMETER__Types::c__AVP__Code__CxDx__3GPP__Server__Assignment__Type), ts__DIA__Hdr__3GPP_flags_defval);
tmp_165.avp__data().avp__CxDx__3GPP__Server__Assignment__Type() = t;
}
return ret_val;
}


/* Bodies of static functions */

void pre_init_module()
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 0, TTCN_Location::LOCATION_UNKNOWN, "DIAMETER_Templates");
DIAMETER__Types::module_object.pre_init_module();
Osmocom__Types::module_object.pre_init_module();
Misc__Helpers::module_object.pre_init_module();
current_location.update_lineno(106);
/* DIAMETER_Templates.ttcn, line 106 */
const_c__DIAMETER__CREDIT__CONTROL__AID = 4;
current_location.update_lineno(108);
/* DIAMETER_Templates.ttcn, line 108 */
const_c__DIAMETER__3GPP__S7__AID = 16777308;
current_location.update_lineno(110);
/* DIAMETER_Templates.ttcn, line 110 */
const_c__def__sess__id = os_0;
module_object.add_function("f_tr_AVP_VendorId", (genericfunc_t)&f__tr__AVP__VendorId, NULL);
module_object.add_function("enum2int_Vendor_Id_tmpl", (genericfunc_t)&enum2int__Vendor__Id__tmpl, NULL);
module_object.add_function("f_tr_DIAMETER_Resultcode", (genericfunc_t)&f__tr__DIAMETER__Resultcode, NULL);
module_object.add_function("f_ts_DIA_CEA", (genericfunc_t)&f__ts__DIA__CEA, NULL);
module_object.add_function("f_DIAMETER_get_avp", (genericfunc_t)&f__DIAMETER__get__avp, NULL);
module_object.add_function("f_DIAMETER_get_avp_or_fail", (genericfunc_t)&f__DIAMETER__get__avp__or__fail, NULL);
module_object.add_function("f_AVP_Grouped_get_avp", (genericfunc_t)&f__AVP__Grouped__get__avp, NULL);
module_object.add_function("f_AVP_Grouped_get_avp_or_fail", (genericfunc_t)&f__AVP__Grouped__get__avp__or__fail, NULL);
}

void post_init_module()
{
TTCN_Location current_location("DIAMETER_Templates.ttcn", 0, TTCN_Location::LOCATION_UNKNOWN, "DIAMETER_Templates");
DIAMETER__Types::module_object.post_init_module();
Osmocom__Types::module_object.post_init_module();
Misc__Helpers::module_object.post_init_module();
current_location.update_lineno(115);
/* DIAMETER_Templates.ttcn, line 115 */
template_ts__DIAMETER_app__id_defval = os_1;
current_location.update_lineno(116);
/* DIAMETER_Templates.ttcn, line 116 */
template_ts__DIAMETER_hbh__id_defval = os_1;
current_location.update_lineno(117);
/* DIAMETER_Templates.ttcn, line 117 */
template_ts__DIAMETER_ete__id_defval = os_1;
current_location.update_lineno(118);
/* DIAMETER_Templates.ttcn, line 118 */
template_ts__DIAMETER_avps_defval = NULL_VALUE;
current_location.update_lineno(130);
/* DIAMETER_Templates.ttcn, line 130 */
template_tr__DIAMETER_flags_defval = ANY_VALUE;
current_location.update_lineno(131);
/* DIAMETER_Templates.ttcn, line 131 */
template_tr__DIAMETER_cmd__code_defval = ANY_VALUE;
current_location.update_lineno(132);
/* DIAMETER_Templates.ttcn, line 132 */
template_tr__DIAMETER_app__id_defval = ANY_VALUE;
current_location.update_lineno(133);
/* DIAMETER_Templates.ttcn, line 133 */
template_tr__DIAMETER_hbh__id_defval = ANY_VALUE;
current_location.update_lineno(134);
/* DIAMETER_Templates.ttcn, line 134 */
template_tr__DIAMETER_ete__id_defval = ANY_VALUE;
current_location.update_lineno(135);
/* DIAMETER_Templates.ttcn, line 135 */
template_tr__DIAMETER_avps_defval = ANY_VALUE;
current_location.update_lineno(147);
/* DIAMETER_Templates.ttcn, line 147 */
template_tr__DIAMETER__A_cmd__code_defval = ANY_VALUE;
current_location.update_lineno(148);
/* DIAMETER_Templates.ttcn, line 148 */
template_tr__DIAMETER__A_app__id_defval = ANY_VALUE;
current_location.update_lineno(149);
/* DIAMETER_Templates.ttcn, line 149 */
template_tr__DIAMETER__A_hbh__id_defval = ANY_VALUE;
current_location.update_lineno(150);
/* DIAMETER_Templates.ttcn, line 150 */
template_tr__DIAMETER__A_ete__id_defval = ANY_VALUE;
current_location.update_lineno(151);
/* DIAMETER_Templates.ttcn, line 151 */
template_tr__DIAMETER__A_avps_defval = ANY_VALUE;
current_location.update_lineno(155);
/* DIAMETER_Templates.ttcn, line 155 */
template_tr__DIAMETER__R_cmd__code_defval = ANY_VALUE;
current_location.update_lineno(156);
/* DIAMETER_Templates.ttcn, line 156 */
template_tr__DIAMETER__R_app__id_defval = ANY_VALUE;
current_location.update_lineno(157);
/* DIAMETER_Templates.ttcn, line 157 */
template_tr__DIAMETER__R_hbh__id_defval = ANY_VALUE;
current_location.update_lineno(158);
/* DIAMETER_Templates.ttcn, line 158 */
template_tr__DIAMETER__R_ete__id_defval = ANY_VALUE;
current_location.update_lineno(159);
/* DIAMETER_Templates.ttcn, line 159 */
template_tr__DIAMETER__R_avps_defval = ANY_VALUE;
current_location.update_lineno(165);
/* DIAMETER_Templates.ttcn, line 165 */
template_ts__DIA__Hdr_flags_defval = bs_0;
current_location.update_lineno(173);
/* DIAMETER_Templates.ttcn, line 173 */
template_tr__DIA__Hdr_flags_defval = bp_0;
current_location.update_lineno(182);
/* DIAMETER_Templates.ttcn, line 182 */
template_ts__DIA__Hdr__3GPP_flags_defval = bs_1;
current_location.update_lineno(190);
/* DIAMETER_Templates.ttcn, line 190 */
template_tr__DIA__Hdr__3GPP_flags_defval = bp_1;
current_location.update_lineno(197);
/* DIAMETER_Templates.ttcn, line 197 */
template_tr__AVP__Address_addr__type_defval = ANY_VALUE;
current_location.update_lineno(198);
/* DIAMETER_Templates.ttcn, line 198 */
template_tr__AVP__Address_addr__data_defval = ANY_VALUE;
current_location.update_lineno(257);
/* DIAMETER_Templates.ttcn, line 257 */
template_tr__AVP__RequestedAction_t_defval = ANY_VALUE;
current_location.update_lineno(266);
/* DIAMETER_Templates.ttcn, line 266 */
template_tr__AVP__MultipleServicesIndicator_t_defval = ANY_VALUE;
current_location.update_lineno(275);
/* DIAMETER_Templates.ttcn, line 275 */
template_tr__AVP__ServiceContextId_id_defval = ANY_VALUE;
current_location.update_lineno(292);
/* DIAMETER_Templates.ttcn, line 292 */
template_tr__AVP__OriginHost_host_defval = ANY_VALUE;
current_location.update_lineno(310);
/* DIAMETER_Templates.ttcn, line 310 */
template_tr__AVP__OriginRealm_realm_defval = ANY_VALUE;
current_location.update_lineno(328);
/* DIAMETER_Templates.ttcn, line 328 */
template_tr__AVP__OriginStateId_state__id_defval = ANY_VALUE;
current_location.update_lineno(434);
/* DIAMETER_Templates.ttcn, line 434 */
template_tr__AVP__VendorSpecAppId_vendor__id_defval = ANY_VALUE;
current_location.update_lineno(435);
/* DIAMETER_Templates.ttcn, line 435 */
template_tr__AVP__VendorSpecAppId_auth__app__id_defval = ANY_VALUE;
current_location.update_lineno(492);
/* DIAMETER_Templates.ttcn, line 492 */
template_tr__AVP__AuthAppId_auth__app__id_defval = ANY_VALUE;
current_location.update_lineno(509);
/* DIAMETER_Templates.ttcn, line 509 */
template_tr__AVP__CcReqType_r_defval = ANY_VALUE;
current_location.update_lineno(526);
/* DIAMETER_Templates.ttcn, line 526 */
template_tr__AVP__CcReqNum_n_defval = ANY_VALUE;
current_location.update_lineno(535);
/* DIAMETER_Templates.ttcn, line 535 */
template_tr__AVP__EventTimestamp_n_defval = ANY_VALUE;
current_location.update_lineno(544);
/* DIAMETER_Templates.ttcn, line 544 */
template_tr__AVP__ExperimentalResultCode_n_defval = ANY_VALUE;
current_location.update_lineno(561);
/* DIAMETER_Templates.ttcn, line 561 */
template_tr__AVP__ExperimentalResult_vendor__id_defval = ANY_VALUE;
current_location.update_lineno(562);
/* DIAMETER_Templates.ttcn, line 562 */
template_tr__AVP__ExperimentalResult_err__code_defval = ANY_VALUE;
current_location.update_lineno(574);
/* DIAMETER_Templates.ttcn, line 574 */
template_ts__AVP__ExperimentalResult_vendor__id_defval = DIAMETER__Types::Vendor__Id::vendor__id__3GPP;
current_location.update_lineno(626);
/* DIAMETER_Templates.ttcn, line 626 */
template_ts__AVP__AuthSessionState_ass_defval = DIAMETER__Types::BASE__NONE__Auth__Session__State::NO__STATE__MAINTAINED;
current_location.update_lineno(634);
/* DIAMETER_Templates.ttcn, line 634 */
template_tr__AVP__AuthSessionState_ass_defval = ANY_VALUE;
current_location.update_lineno(651);
/* DIAMETER_Templates.ttcn, line 651 */
template_tr__AVP__SessionId_session__id_defval = ANY_VALUE;
current_location.update_lineno(668);
/* DIAMETER_Templates.ttcn, line 668 */
template_tr__AVP__DestinationHost_host_defval = ANY_VALUE;
current_location.update_lineno(686);
/* DIAMETER_Templates.ttcn, line 686 */
template_tr__AVP__DestinationRealm_dest__realm_defval = ANY_VALUE;
current_location.update_lineno(704);
/* DIAMETER_Templates.ttcn, line 704 */
template_tr__AVP__UserName_uid_defval = ANY_VALUE;
current_location.update_lineno(713);
/* DIAMETER_Templates.ttcn, line 713 */
template_tr__AVP__UserNameImsi_imsi_defval = ANY_VALUE;
current_location.update_lineno(716);
/* DIAMETER_Templates.ttcn, line 716 */
template_ts__AVP__NumOfReqVectors_num__req_defval = os_2;
current_location.update_lineno(725);
/* DIAMETER_Templates.ttcn, line 725 */
template_ts__AVP__ImmReqPref_par_defval = os_1;
current_location.update_lineno(736);
/* DIAMETER_Templates.ttcn, line 736 */
template_ts__AVP__RequestedEutranAuthInfo_num__vec_defval = os_2;
current_location.update_lineno(748);
/* DIAMETER_Templates.ttcn, line 748 */
template_tr__AVP__3GPP__SubscrRauTauTmr_tmr_defval = ANY_VALUE;
current_location.update_lineno(766);
/* DIAMETER_Templates.ttcn, line 766 */
template_tr__AVP__PCC__3GPP__QoS__Information_list_defval = ANY_VALUE;
current_location.update_lineno(811);
/* DIAMETER_Templates.ttcn, line 811 */
template_tr__AVP__PCC__3GPP__QoS__Class__Identifier_val_defval = ANY_VALUE;
current_location.update_lineno(829);
/* DIAMETER_Templates.ttcn, line 829 */
template_tr__AVP__3GPP__PriorityLevel_prio_defval = ANY_VALUE;
current_location.update_lineno(847);
/* DIAMETER_Templates.ttcn, line 847 */
template_tr__AVP__PCC__3GPP__AllocRetenPrio_prio_defval = ANY_VALUE;
current_location.update_lineno(873);
/* DIAMETER_Templates.ttcn, line 873 */
template_tr__AVP__3GPP__EpsSubscrQosProfile_qos__class_defval = ANY_VALUE;
current_location.update_lineno(874);
/* DIAMETER_Templates.ttcn, line 874 */
template_tr__AVP__3GPP__EpsSubscrQosProfile_prio_defval = ANY_VALUE;
current_location.update_lineno(898);
/* DIAMETER_Templates.ttcn, line 898 */
template_tr__AVP__3GPP__Reporting__Reason_r_defval = ANY_VALUE;
current_location.update_lineno(907);
/* DIAMETER_Templates.ttcn, line 907 */
template_tr__AVP__3GPP__AoCRequestType_t_defval = ANY_VALUE;
current_location.update_lineno(916);
/* DIAMETER_Templates.ttcn, line 916 */
template_tr__AVP__3GPP__ServiceInformation_content_defval = ANY_VALUE;
current_location.update_lineno(925);
/* DIAMETER_Templates.ttcn, line 925 */
template_tr__AVP__3GPP__PSInformation_content_defval = ANY_VALUE;
current_location.update_lineno(934);
/* DIAMETER_Templates.ttcn, line 934 */
template_tr__AVP__3GPP__ChargingId_id_defval = ANY_VALUE;
current_location.update_lineno(943);
/* DIAMETER_Templates.ttcn, line 943 */
template_tr__AVP__3GPP__PDPType_t_defval = ANY_VALUE;
current_location.update_lineno(952);
/* DIAMETER_Templates.ttcn, line 952 */
template_tr__AVP__3GPP__PDPAddress_addr_defval = ANY_VALUE;
current_location.update_lineno(961);
/* DIAMETER_Templates.ttcn, line 961 */
template_tr__AVP__3GPP__SGSNAddress_addr_defval = ANY_VALUE;
current_location.update_lineno(970);
/* DIAMETER_Templates.ttcn, line 970 */
template_tr__AVP__3GPP__GGSNAddress_addr_defval = ANY_VALUE;
current_location.update_lineno(979);
/* DIAMETER_Templates.ttcn, line 979 */
template_tr__AVP__3GPP__SelectionMode_sm_defval = ANY_VALUE;
current_location.update_lineno(988);
/* DIAMETER_Templates.ttcn, line 988 */
template_tr__AVP__3GPP__ChargingCharacteristics_cc_defval = ANY_VALUE;
current_location.update_lineno(997);
/* DIAMETER_Templates.ttcn, line 997 */
template_tr__AVP__3GPP__SGSNMCCMNC_smn_defval = ANY_VALUE;
current_location.update_lineno(1006);
/* DIAMETER_Templates.ttcn, line 1006 */
template_tr__AVP__3GPP__NSAPI_nsapi_defval = ANY_VALUE;
current_location.update_lineno(1015);
/* DIAMETER_Templates.ttcn, line 1015 */
template_tr__AVP__3GPP__MS__TimeZone_ms__tz_defval = ANY_VALUE;
current_location.update_lineno(1024);
/* DIAMETER_Templates.ttcn, line 1024 */
template_tr__AVP__3GPP__ULI_uli_defval = ANY_VALUE;
current_location.update_lineno(1033);
/* DIAMETER_Templates.ttcn, line 1033 */
template_tr__AVP__UserEquipmentInfo_uei_defval = ANY_VALUE;
current_location.update_lineno(1042);
/* DIAMETER_Templates.ttcn, line 1042 */
template_tr__AVP__UserEquipmentInfoType_ueit_defval = ANY_VALUE;
current_location.update_lineno(1051);
/* DIAMETER_Templates.ttcn, line 1051 */
template_tr__AVP__UserEquipmentInfoValue_ueiv_defval = ANY_VALUE;
current_location.update_lineno(1069);
/* DIAMETER_Templates.ttcn, line 1069 */
template_tr__AVP__Multiple__Services__Credit__Control_content_defval = ANY_VALUE;
current_location.update_lineno(1079);
/* DIAMETER_Templates.ttcn, line 1079 */
template_tr__AVP__Requested__Service__Unit_content_defval = ANY_VALUE;
current_location.update_lineno(1089);
/* DIAMETER_Templates.ttcn, line 1089 */
template_tr__AVP__Used__Service__Unit_content_defval = ANY_VALUE;
current_location.update_lineno(1147);
/* DIAMETER_Templates.ttcn, line 1147 */
template_tr__AVP__3GPP__CalledStationId_id_defval = ANY_VALUE;
current_location.update_lineno(1203);
/* DIAMETER_Templates.ttcn, line 1203 */
template_ts__DIA__CER_orig__host_defval = cs_4;
current_location.update_lineno(1204);
/* DIAMETER_Templates.ttcn, line 1204 */
template_ts__DIA__CER_orig__realm_defval = cs_5;
current_location.update_lineno(1205);
/* DIAMETER_Templates.ttcn, line 1205 */
template_ts__DIA__CER_hbh__id_defval = os_1;
current_location.update_lineno(1206);
/* DIAMETER_Templates.ttcn, line 1206 */
template_ts__DIA__CER_ete__id_defval = os_1;
current_location.update_lineno(1283);
/* DIAMETER_Templates.ttcn, line 1283 */
template_ts__DIA__DWR_state__id_defval = os_1;
current_location.update_lineno(1284);
/* DIAMETER_Templates.ttcn, line 1284 */
template_ts__DIA__DWR_orig__host_defval = cs_4;
current_location.update_lineno(1285);
/* DIAMETER_Templates.ttcn, line 1285 */
template_ts__DIA__DWR_orig__realm_defval = cs_5;
current_location.update_lineno(1286);
/* DIAMETER_Templates.ttcn, line 1286 */
template_ts__DIA__DWR_hbh__id_defval = os_1;
current_location.update_lineno(1287);
/* DIAMETER_Templates.ttcn, line 1287 */
template_ts__DIA__DWR_ete__id_defval = os_1;
current_location.update_lineno(1299);
/* DIAMETER_Templates.ttcn, line 1299 */
template_tr__DIA__DWR_state__id_defval = ANY_VALUE;
current_location.update_lineno(1300);
/* DIAMETER_Templates.ttcn, line 1300 */
template_tr__DIA__DWR_orig__host_defval = ANY_VALUE;
current_location.update_lineno(1301);
/* DIAMETER_Templates.ttcn, line 1301 */
template_tr__DIA__DWR_orig__realm_defval = ANY_VALUE;
current_location.update_lineno(1302);
/* DIAMETER_Templates.ttcn, line 1302 */
template_tr__DIA__DWR_hbh__id_defval = ANY_VALUE;
current_location.update_lineno(1303);
/* DIAMETER_Templates.ttcn, line 1303 */
template_tr__DIA__DWR_ete__id_defval = ANY_VALUE;
current_location.update_lineno(1317);
/* DIAMETER_Templates.ttcn, line 1317 */
template_ts__DIA__DWA_state__id_defval = os_1;
current_location.update_lineno(1318);
/* DIAMETER_Templates.ttcn, line 1318 */
template_ts__DIA__DWA_orig__host_defval = cs_4;
current_location.update_lineno(1319);
/* DIAMETER_Templates.ttcn, line 1319 */
template_ts__DIA__DWA_orig__realm_defval = cs_5;
current_location.update_lineno(1320);
/* DIAMETER_Templates.ttcn, line 1320 */
template_ts__DIA__DWA_hbh__id_defval = os_1;
current_location.update_lineno(1321);
/* DIAMETER_Templates.ttcn, line 1321 */
template_ts__DIA__DWA_ete__id_defval = os_1;
current_location.update_lineno(1334);
/* DIAMETER_Templates.ttcn, line 1334 */
template_tr__DIA__DWA_state__id_defval = ANY_VALUE;
current_location.update_lineno(1335);
/* DIAMETER_Templates.ttcn, line 1335 */
template_tr__DIA__DWA_orig__host_defval = ANY_VALUE;
current_location.update_lineno(1336);
/* DIAMETER_Templates.ttcn, line 1336 */
template_tr__DIA__DWA_orig__realm_defval = ANY_VALUE;
current_location.update_lineno(1337);
/* DIAMETER_Templates.ttcn, line 1337 */
template_tr__DIA__DWA_hbh__id_defval = ANY_VALUE;
current_location.update_lineno(1338);
/* DIAMETER_Templates.ttcn, line 1338 */
template_tr__DIA__DWA_ete__id_defval = ANY_VALUE;
current_location.update_lineno(1412);
/* DIAMETER_Templates.ttcn, line 1412 */
template_tr__AVP__3GPP__SIPNumAuthDataItems_num_defval = ANY_VALUE;
current_location.update_lineno(1430);
/* DIAMETER_Templates.ttcn, line 1430 */
template_tr__AVP__3GPP__SIPAuthScheme_scheme_defval = ANY_VALUE;
current_location.update_lineno(1448);
/* DIAMETER_Templates.ttcn, line 1448 */
template_tr__AVP__3GPP__SIPAuthenticate_rand__autn__concatenated_defval = ANY_VALUE;
current_location.update_lineno(1466);
/* DIAMETER_Templates.ttcn, line 1466 */
template_tr__AVP__3GPP__SIPAuthorization_rand__autn__concatenated_defval = ANY_VALUE;
current_location.update_lineno(1484);
/* DIAMETER_Templates.ttcn, line 1484 */
template_tr__AVP__3GPP__SIPAuthContext_val_defval = ANY_VALUE;
current_location.update_lineno(1502);
/* DIAMETER_Templates.ttcn, line 1502 */
template_tr__AVP__3GPP__SIPItemNumber_num_defval = ANY_VALUE;
current_location.update_lineno(1520);
/* DIAMETER_Templates.ttcn, line 1520 */
template_tr__AVP__3GPP__ConfidentialityKey_ckey_defval = ANY_VALUE;
current_location.update_lineno(1538);
/* DIAMETER_Templates.ttcn, line 1538 */
template_tr__AVP__3GPP__IntegrityKey_ckey_defval = ANY_VALUE;
current_location.update_lineno(1556);
/* DIAMETER_Templates.ttcn, line 1556 */
template_tr__AVP__3GPP__ServerAssignmentType_t_defval = ANY_VALUE;
}


} /* end of namespace */
