Loading codec/c++/sip_codets.cpp +88 −98 Original line number Diff line number Diff line #include "gen_classes.h" #include "Regex.h" //#include "gen_classes.h" //#include "Regex.h" #include "common_sip_msrp.h" #include <iostream> #include <fstream> Loading @@ -21,7 +22,7 @@ namespace t3devlib { namespace gen { // to normalise the content so that two equivalent representation // will result in the same TTCN-3 charstring. // void normalise_quoted_string (Charstring& cs, bool remove_quotes = false) throw (DecodeError) void normalise_quoted_string (Charstring& cs, bool remove_quotes/* = false*/) throw (DecodeError) { std::string result; Loading Loading @@ -173,11 +174,6 @@ error_malformed: throw e; } //WSP: space, htab, vtab, form feed #define SIPCHARS_WSP " \t\v\f" #define SIPREG_LWS "(?:[" SIPCHARS_WSP "]*\\r\\n)?[" SIPCHARS_WSP "]+" #define SIPREG_SWS "(?:" SIPREG_LWS ")?" // move past the possible leading linear whitespaces in the buffer void remove_whitespace (Buffer & buffer) { static Regex reg_ws ("^" SIPREG_LWS); Loading Loading @@ -244,11 +240,6 @@ bool is_tel_scheme (const char * pszScheme) { #define SIPREG_DOMAINLABEL "[" SIPCHARS_ALFANUM "]([" SIPCHARS_ALFANUM "\\-]*[" SIPCHARS_ALFANUM "])?" #define SIPREG_HOSTNAME "(" SIPREG_DOMAINLABEL "\\.)*" SIPREG_TOPLABEL "\\.?" #define SIPREG_HCOLON "[ ]*:" SIPREG_SWS #define SIPREG_COMMA SIPREG_SWS "[,]" SIPREG_SWS #define SIPREG_SEMI SIPREG_SWS "[;]" SIPREG_SWS #define SIPREG_EQUAL SIPREG_SWS "[=]" SIPREG_SWS #define SIPREG_SLASH SIPREG_SWS "[/]" SIPREG_SWS // without leading and trailing whitespace #define SIPREG_QUOTED_PAIR "[\\x5C][\\x00-\\x09\\x0B\\x0C\\x0E-\\x7F]" Loading Loading @@ -1141,7 +1132,6 @@ private: SIP_HEADER_ADD (P-Charging-Function-Addresses, , pChargingFunctionAddresses, P_CHARGING_FUNCTION_ADDRESSES_E); SIP_HEADER_ADD (P-Charging-Vector, , pChargingVector, P_CHARGING_VECTOR_E); SIP_HEADER_ADD (Refer-To, r, referTo, REFER_TO_E); SIP_HEADER_ADD (Refer-Sub, r, referSub, REFER_SUB_E); SIP_HEADER_ADD (Replaces, , replaces, REPLACES_E); SIP_HEADER_ADD (Service-Route, , serviceRoute, SERVICE_ROUTE_E); SIP_HEADER_ADD (Accept-Contact, a, acceptContact, ACCEPT_CONTACT_E); Loading Loading @@ -1227,6 +1217,7 @@ void MessageHeader::PreDecodeField (Buffer& buffer) throw (DecodeError) std::ofstream logfile("C:\\Temp\\LibSip.log", ios::app); logfile << "MessageHeader::PreDecodeField: " << id << std::endl; logfile << "MessageHeader::PreDecodeField:MatchedName: " << reg_header_name.GetMatchedString(1) << std::endl; logfile.close(); Loading Loading @@ -1347,7 +1338,6 @@ const char* FieldName::msFields[] = { "P_PREFERRED_ID_E", "REASON_E", "REFER_TO_E", "REFER_SUB_E", "REFERRED_BY_E", "HISTORY_INFO_E", "P_MEDIA_AUTH_E", Loading codec/c++/sip_codets.h +2 −2 Original line number Diff line number Diff line Loading @@ -36,7 +36,7 @@ T3DEVLIB_BASIC_DEFINITION (LibSip_SIPTypesAndValues, Raw, Charstring); // Implementation of enumerated types (not handled by the generator yet) // class FieldName : public t3devlib::Enum class FieldName : public ::t3devlib::Enum { private: static const char* msFields[]; Loading @@ -50,7 +50,7 @@ public: void Decode (Buffer& buffer) throw (DecodeError); }; class Method : public t3devlib::Enum class Method : public ::t3devlib::Enum { private: static const char* msSipMethods[]; Loading Loading
codec/c++/sip_codets.cpp +88 −98 Original line number Diff line number Diff line #include "gen_classes.h" #include "Regex.h" //#include "gen_classes.h" //#include "Regex.h" #include "common_sip_msrp.h" #include <iostream> #include <fstream> Loading @@ -21,7 +22,7 @@ namespace t3devlib { namespace gen { // to normalise the content so that two equivalent representation // will result in the same TTCN-3 charstring. // void normalise_quoted_string (Charstring& cs, bool remove_quotes = false) throw (DecodeError) void normalise_quoted_string (Charstring& cs, bool remove_quotes/* = false*/) throw (DecodeError) { std::string result; Loading Loading @@ -173,11 +174,6 @@ error_malformed: throw e; } //WSP: space, htab, vtab, form feed #define SIPCHARS_WSP " \t\v\f" #define SIPREG_LWS "(?:[" SIPCHARS_WSP "]*\\r\\n)?[" SIPCHARS_WSP "]+" #define SIPREG_SWS "(?:" SIPREG_LWS ")?" // move past the possible leading linear whitespaces in the buffer void remove_whitespace (Buffer & buffer) { static Regex reg_ws ("^" SIPREG_LWS); Loading Loading @@ -244,11 +240,6 @@ bool is_tel_scheme (const char * pszScheme) { #define SIPREG_DOMAINLABEL "[" SIPCHARS_ALFANUM "]([" SIPCHARS_ALFANUM "\\-]*[" SIPCHARS_ALFANUM "])?" #define SIPREG_HOSTNAME "(" SIPREG_DOMAINLABEL "\\.)*" SIPREG_TOPLABEL "\\.?" #define SIPREG_HCOLON "[ ]*:" SIPREG_SWS #define SIPREG_COMMA SIPREG_SWS "[,]" SIPREG_SWS #define SIPREG_SEMI SIPREG_SWS "[;]" SIPREG_SWS #define SIPREG_EQUAL SIPREG_SWS "[=]" SIPREG_SWS #define SIPREG_SLASH SIPREG_SWS "[/]" SIPREG_SWS // without leading and trailing whitespace #define SIPREG_QUOTED_PAIR "[\\x5C][\\x00-\\x09\\x0B\\x0C\\x0E-\\x7F]" Loading Loading @@ -1141,7 +1132,6 @@ private: SIP_HEADER_ADD (P-Charging-Function-Addresses, , pChargingFunctionAddresses, P_CHARGING_FUNCTION_ADDRESSES_E); SIP_HEADER_ADD (P-Charging-Vector, , pChargingVector, P_CHARGING_VECTOR_E); SIP_HEADER_ADD (Refer-To, r, referTo, REFER_TO_E); SIP_HEADER_ADD (Refer-Sub, r, referSub, REFER_SUB_E); SIP_HEADER_ADD (Replaces, , replaces, REPLACES_E); SIP_HEADER_ADD (Service-Route, , serviceRoute, SERVICE_ROUTE_E); SIP_HEADER_ADD (Accept-Contact, a, acceptContact, ACCEPT_CONTACT_E); Loading Loading @@ -1227,6 +1217,7 @@ void MessageHeader::PreDecodeField (Buffer& buffer) throw (DecodeError) std::ofstream logfile("C:\\Temp\\LibSip.log", ios::app); logfile << "MessageHeader::PreDecodeField: " << id << std::endl; logfile << "MessageHeader::PreDecodeField:MatchedName: " << reg_header_name.GetMatchedString(1) << std::endl; logfile.close(); Loading Loading @@ -1347,7 +1338,6 @@ const char* FieldName::msFields[] = { "P_PREFERRED_ID_E", "REASON_E", "REFER_TO_E", "REFER_SUB_E", "REFERRED_BY_E", "HISTORY_INFO_E", "P_MEDIA_AUTH_E", Loading
codec/c++/sip_codets.h +2 −2 Original line number Diff line number Diff line Loading @@ -36,7 +36,7 @@ T3DEVLIB_BASIC_DEFINITION (LibSip_SIPTypesAndValues, Raw, Charstring); // Implementation of enumerated types (not handled by the generator yet) // class FieldName : public t3devlib::Enum class FieldName : public ::t3devlib::Enum { private: static const char* msFields[]; Loading @@ -50,7 +50,7 @@ public: void Decode (Buffer& buffer) throw (DecodeError); }; class Method : public t3devlib::Enum class Method : public ::t3devlib::Enum { private: static const char* msSipMethods[]; Loading