diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index a6f4568cd..f5617ed65 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -164,6 +164,8 @@ set(LINPHONE_CXX_OBJECTS_PRIVATE_HEADER_FILES utils/payload-type-handler.h variant/variant.h xml/conference-info.h + xml/imdn.h + xml/linphone-imdn.h xml/resource-lists.h xml/xml.h ) @@ -286,6 +288,8 @@ set(LINPHONE_CXX_OBJECTS_SOURCE_FILES utils/utils.cpp variant/variant.cpp xml/conference-info.cpp + xml/imdn.cpp + xml/linphone-imdn.cpp xml/resource-lists.cpp xml/xml.cpp ) diff --git a/src/chat/notification/imdn.cpp b/src/chat/notification/imdn.cpp index da89e9810..203eb7846 100644 --- a/src/chat/notification/imdn.cpp +++ b/src/chat/notification/imdn.cpp @@ -23,6 +23,8 @@ #include "chat/chat-room/chat-room-p.h" #include "core/core.h" #include "logger/logger.h" +#include "xml/imdn.h" +#include "xml/linphone-imdn.h" #include "imdn.h" @@ -32,8 +34,6 @@ using namespace std; LINPHONE_BEGIN_NAMESPACE -const string Imdn::imdnPrefix = "/imdn:imdn"; - // ----------------------------------------------------------------------------- Imdn::Imdn (ChatRoom *chatRoom) : chatRoom(chatRoom) {} @@ -74,184 +74,75 @@ void Imdn::notifyDisplay (const shared_ptr &message) { // ----------------------------------------------------------------------------- -string Imdn::createXml (const string &id, time_t time, Imdn::Type imdnType, LinphoneReason reason) { - xmlBufferPtr buf; - xmlTextWriterPtr writer; - int err; - string content; - char *datetime = nullptr; - - // Check that the chat message has a message id. - if (id.empty()) - return content; - - buf = xmlBufferCreate(); - if (buf == nullptr) { - lError() << "Error creating the XML buffer"; - return content; - } - writer = xmlNewTextWriterMemory(buf, 0); - if (writer == nullptr) { - lError() << "Error creating the XML writer"; - return content; - } - - datetime = linphone_timestamp_to_rfc3339_string(time); - err = xmlTextWriterStartDocument(writer, "1.0", "UTF-8", nullptr); - if (err >= 0) { - err = xmlTextWriterStartElementNS(writer, nullptr, (const xmlChar *)"imdn", - (const xmlChar *)"urn:ietf:params:xml:ns:imdn"); - } - if ((err >= 0) && (reason != LinphoneReasonNone)) { - err = xmlTextWriterWriteAttributeNS(writer, (const xmlChar *)"xmlns", (const xmlChar *)"linphoneimdn", nullptr, (const xmlChar *)"http://www.linphone.org/xsds/imdn.xsd"); - } - if (err >= 0) { - err = xmlTextWriterWriteElement(writer, (const xmlChar *)"message-id", (const xmlChar *)id.c_str()); - } - if (err >= 0) { - err = xmlTextWriterWriteElement(writer, (const xmlChar *)"datetime", (const xmlChar *)datetime); - } - if (err >= 0) { - if (imdnType == Imdn::Type::Delivery) { - err = xmlTextWriterStartElement(writer, (const xmlChar *)"delivery-notification"); - } else { - err = xmlTextWriterStartElement(writer, (const xmlChar *)"display-notification"); - } - } - if (err >= 0) { - err = xmlTextWriterStartElement(writer, (const xmlChar *)"status"); - } - if (err >= 0) { - if (reason == LinphoneReasonNone) { - if (imdnType == Imdn::Type::Delivery) { - err = xmlTextWriterStartElement(writer, (const xmlChar *)"delivered"); - } else { - err = xmlTextWriterStartElement(writer, (const xmlChar *)"displayed"); - } - } else { - err = xmlTextWriterStartElement(writer, (const xmlChar *)"error"); - } - } - if (err >= 0) { - // Close the "delivered", "displayed" or "error" element. - err = xmlTextWriterEndElement(writer); - } - if ((err >= 0) && (reason != LinphoneReasonNone)) { - err = xmlTextWriterStartElementNS(writer, (const xmlChar *)"linphoneimdn", (const xmlChar *)"reason", nullptr); - if (err >= 0) { - char codestr[16]; - snprintf(codestr, 16, "%d", linphone_reason_to_error_code(reason)); - err = xmlTextWriterWriteAttribute(writer, (const xmlChar *)"code", (const xmlChar *)codestr); - } - if (err >= 0) { - err = xmlTextWriterWriteString(writer, (const xmlChar *)linphone_reason_to_string(reason)); - } - if (err >= 0) { - err = xmlTextWriterEndElement(writer); - } - } - if (err >= 0) { - // Close the "status" element. - err = xmlTextWriterEndElement(writer); - } - if (err >= 0) { - // Close the "delivery-notification" or "display-notification" element. - err = xmlTextWriterEndElement(writer); - } - if (err >= 0) { - // Close the "imdn" element. - err = xmlTextWriterEndElement(writer); - } - if (err >= 0) { - err = xmlTextWriterEndDocument(writer); - } - if (err > 0) { - // xmlTextWriterEndDocument returns the size of the content. - content = string((char *)buf->content); - } - xmlFreeTextWriter(writer); - xmlBufferFree(buf); +string Imdn::createXml (const string &id, time_t timestamp, Imdn::Type imdnType, LinphoneReason reason) { + char *datetime = linphone_timestamp_to_rfc3339_string(timestamp); + Xsd::Imdn::Imdn imdn(id, datetime); ms_free(datetime); - return content; + if (imdnType == Imdn::Type::Delivery) { + Xsd::Imdn::Status status; + if (reason == LinphoneReasonNone) { + auto delivered = Xsd::Imdn::Delivered(); + status.setDelivered(delivered); + } else { + auto failed = Xsd::Imdn::Failed(); + status.setFailed(failed); + Xsd::LinphoneImdn::ImdnReason imdnReason(linphone_reason_to_string(reason)); + imdnReason.setCode(linphone_reason_to_error_code(reason)); + status.setReason(imdnReason); + } + Xsd::Imdn::DeliveryNotification deliveryNotification(status); + imdn.setDeliveryNotification(deliveryNotification); + } else if (imdnType == Imdn::Type::Display) { + Xsd::Imdn::Status1 status; + auto displayed = Xsd::Imdn::Displayed(); + status.setDisplayed(displayed); + Xsd::Imdn::DisplayNotification displayNotification(status); + imdn.setDisplayNotification(displayNotification); + } + + stringstream ss; + Xsd::XmlSchema::NamespaceInfomap map; + map[""].name = "urn:ietf:params:xml:ns:imdn"; + map["imdn"].name = "http://www.linphone.org/xsds/imdn.xsd"; + Xsd::Imdn::serializeImdn(ss, imdn, map); + return ss.str(); } void Imdn::parse (const shared_ptr &chatMessage) { - xmlparsing_context_t *xmlCtx = linphone_xmlparsing_context_new(); - xmlSetGenericErrorFunc(xmlCtx, linphone_xmlparsing_genericxml_error); - xmlCtx->doc = xmlReadDoc((const unsigned char *)chatMessage->getPrivate()->getText().c_str(), 0, nullptr, 0); - if (xmlCtx->doc) - parse(chatMessage, xmlCtx); - else - lWarning() << "Wrongly formatted IMDN XML: " << xmlCtx->errorBuffer; - linphone_xmlparsing_context_destroy(xmlCtx); + shared_ptr cr = chatMessage->getChatRoom(); + for (const auto &content : chatMessage->getPrivate()->getContents()) { + istringstream data(content->getBodyAsString()); + unique_ptr imdn(Xsd::Imdn::parseImdn(data, Xsd::XmlSchema::Flags::dont_validate)); + if (!imdn) + continue; + shared_ptr cm = cr->findChatMessage(imdn->getMessageId()); + if (!cm) { + lWarning() << "Received IMDN for unknown message " << imdn->getMessageId(); + } else { + auto policy = linphone_core_get_im_notif_policy(cr->getCore()->getCCore()); + time_t imdnTime = chatMessage->getTime(); + const IdentityAddress &participantAddress = chatMessage->getFromAddress().getAddressWithoutGruu(); + auto &deliveryNotification = imdn->getDeliveryNotification(); + auto &displayNotification = imdn->getDisplayNotification(); + if (deliveryNotification.present()) { + auto &status = deliveryNotification.get().getStatus(); + if (status.getDelivered().present() && linphone_im_notif_policy_get_recv_imdn_delivered(policy)) + cm->getPrivate()->setParticipantState(participantAddress, ChatMessage::State::DeliveredToUser, imdnTime); + else if ((status.getFailed().present() || status.getError().present()) + && linphone_im_notif_policy_get_recv_imdn_delivered(policy) + ) + cm->getPrivate()->setParticipantState(participantAddress, ChatMessage::State::NotDelivered, imdnTime); + } else if (displayNotification.present()) { + auto &status = displayNotification.get().getStatus(); + if (status.getDisplayed().present() && linphone_im_notif_policy_get_recv_imdn_displayed(policy)) + cm->getPrivate()->setParticipantState(participantAddress, ChatMessage::State::Displayed, imdnTime); + } + } + } } // ----------------------------------------------------------------------------- -void Imdn::parse (const shared_ptr &imdnMessage, xmlparsing_context_t *xmlCtx) { - char xpathStr[MAX_XPATH_LENGTH]; - char *messageIdStr = nullptr; - char *datetimeStr = nullptr; - if (linphone_create_xml_xpath_context(xmlCtx) < 0) - return; - - xmlXPathRegisterNs(xmlCtx->xpath_ctx, (const xmlChar *)"imdn", (const xmlChar *)"urn:ietf:params:xml:ns:imdn"); - xmlXPathObjectPtr imdnObject = linphone_get_xml_xpath_object_for_node_list(xmlCtx, imdnPrefix.c_str()); - if (imdnObject) { - if (imdnObject->nodesetval && (imdnObject->nodesetval->nodeNr >= 1)) { - snprintf(xpathStr, sizeof(xpathStr), "%s[1]/imdn:message-id", imdnPrefix.c_str()); - messageIdStr = linphone_get_xml_text_content(xmlCtx, xpathStr); - snprintf(xpathStr, sizeof(xpathStr), "%s[1]/imdn:datetime", imdnPrefix.c_str()); - datetimeStr = linphone_get_xml_text_content(xmlCtx, xpathStr); - } - xmlXPathFreeObject(imdnObject); - } - - if (messageIdStr && datetimeStr) { - shared_ptr cr = imdnMessage->getChatRoom(); - shared_ptr cm = cr->findChatMessage(messageIdStr); - const IdentityAddress &participantAddress = imdnMessage->getFromAddress().getAddressWithoutGruu(); - if (!cm) { - lWarning() << "Received IMDN for unknown message " << messageIdStr; - } else { - time_t imdnTime = imdnMessage->getTime(); - LinphoneImNotifPolicy *policy = linphone_core_get_im_notif_policy(cr->getCore()->getCCore()); - snprintf(xpathStr, sizeof(xpathStr), "%s[1]/imdn:delivery-notification/imdn:status", imdnPrefix.c_str()); - xmlXPathObjectPtr deliveryStatusObject = linphone_get_xml_xpath_object_for_node_list(xmlCtx, xpathStr); - snprintf(xpathStr, sizeof(xpathStr), "%s[1]/imdn:display-notification/imdn:status", imdnPrefix.c_str()); - xmlXPathObjectPtr displayStatusObject = linphone_get_xml_xpath_object_for_node_list(xmlCtx, xpathStr); - if (deliveryStatusObject && linphone_im_notif_policy_get_recv_imdn_delivered(policy)) { - if (deliveryStatusObject->nodesetval && (deliveryStatusObject->nodesetval->nodeNr >= 1)) { - xmlNodePtr node = deliveryStatusObject->nodesetval->nodeTab[0]; - if (node->children && node->children->name) { - if (strcmp((const char *)node->children->name, "delivered") == 0) { - cm->getPrivate()->setParticipantState(participantAddress, ChatMessage::State::DeliveredToUser, imdnTime); - } else if (strcmp((const char *)node->children->name, "error") == 0) { - cm->getPrivate()->setParticipantState(participantAddress, ChatMessage::State::NotDelivered, imdnTime); - } - } - } - xmlXPathFreeObject(deliveryStatusObject); - } - if (displayStatusObject && linphone_im_notif_policy_get_recv_imdn_displayed(policy)) { - if (displayStatusObject->nodesetval && (displayStatusObject->nodesetval->nodeNr >= 1)) { - xmlNodePtr node = displayStatusObject->nodesetval->nodeTab[0]; - if (node->children && node->children->name) { - if (strcmp((const char *)node->children->name, "displayed") == 0) { - cm->getPrivate()->setParticipantState(participantAddress, ChatMessage::State::Displayed, imdnTime); - } - } - } - xmlXPathFreeObject(displayStatusObject); - } - } - } - if (messageIdStr) - linphone_free_xml_text_content(messageIdStr); - if (datetimeStr) - linphone_free_xml_text_content(datetimeStr); -} - int Imdn::timerExpired (void *data, unsigned int revents) { Imdn *d = reinterpret_cast(data); d->stopTimer(); diff --git a/src/chat/notification/imdn.h b/src/chat/notification/imdn.h index 63927ab52..ca5095319 100644 --- a/src/chat/notification/imdn.h +++ b/src/chat/notification/imdn.h @@ -57,7 +57,6 @@ public: static void parse (const std::shared_ptr &chatMessage); private: - static void parse (const std::shared_ptr &chatMessage, xmlparsing_context_t *xmlCtx); static int timerExpired (void *data, unsigned int revents); void send (); @@ -65,8 +64,6 @@ private: void stopTimer (); private: - static const std::string imdnPrefix; - ChatRoom *chatRoom = nullptr; std::list> deliveredMessages; std::list> displayedMessages; diff --git a/src/xml/conference-info.cpp b/src/xml/conference-info.cpp index 5089051d7..fc2f8aac3 100644 --- a/src/xml/conference-info.cpp +++ b/src/xml/conference-info.cpp @@ -36,9 +36,10 @@ #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wfloat-equal" -#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) - #pragma GCC diagnostic ignored "-Wsuggest-override" #endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" #endif // // End prologue. @@ -54,7 +55,7 @@ namespace LinphonePrivate namespace ConferenceInfo { // ConferenceType - // + // const ConferenceType::ConferenceDescriptionOptional& ConferenceType:: getConferenceDescription () const @@ -376,7 +377,7 @@ namespace LinphonePrivate // StateType - // + // StateType:: StateType (Value v) @@ -413,7 +414,7 @@ namespace LinphonePrivate StateType& StateType:: operator= (Value v) { - static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = + static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = ::LinphonePrivate::Xsd::XmlSchema::String (_xsd_StateType_literals_[v]); return *this; @@ -421,7 +422,7 @@ namespace LinphonePrivate // ConferenceDescriptionType - // + // const ConferenceDescriptionType::DisplayTextOptional& ConferenceDescriptionType:: getDisplayText () const @@ -707,7 +708,7 @@ namespace LinphonePrivate // HostType - // + // const HostType::DisplayTextOptional& HostType:: getDisplayText () const @@ -849,7 +850,7 @@ namespace LinphonePrivate // ConferenceStateType - // + // const ConferenceStateType::UserCountOptional& ConferenceStateType:: getUserCount () const @@ -973,7 +974,7 @@ namespace LinphonePrivate // ConferenceMediaType - // + // const ConferenceMediaType::EntrySequence& ConferenceMediaType:: getEntry () const @@ -1025,7 +1026,7 @@ namespace LinphonePrivate // ConferenceMediumType - // + // const ConferenceMediumType::DisplayTextOptional& ConferenceMediumType:: getDisplayText () const @@ -1197,7 +1198,7 @@ namespace LinphonePrivate // UrisType - // + // const UrisType::EntrySequence& UrisType:: getEntry () const @@ -1285,7 +1286,7 @@ namespace LinphonePrivate // UriType - // + // const UriType::UriType1& UriType:: getUri () const @@ -1481,7 +1482,7 @@ namespace LinphonePrivate } // UsersType - // + // const UsersType::UserSequence& UsersType:: getUser () const @@ -1587,7 +1588,7 @@ namespace LinphonePrivate // UserType - // + // const UserType::DisplayTextOptional& UserType:: getDisplayText () const @@ -1873,7 +1874,7 @@ namespace LinphonePrivate // UserRolesType - // + // const UserRolesType::EntrySequence& UserRolesType:: getEntry () const @@ -1949,7 +1950,7 @@ namespace LinphonePrivate } // EndpointType - // + // const EndpointType::DisplayTextOptional& EndpointType:: getDisplayText () const @@ -2325,7 +2326,7 @@ namespace LinphonePrivate // EndpointStatusType - // + // EndpointStatusType:: EndpointStatusType (Value v) @@ -2362,7 +2363,7 @@ namespace LinphonePrivate EndpointStatusType& EndpointStatusType:: operator= (Value v) { - static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = + static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = ::LinphonePrivate::Xsd::XmlSchema::String (_xsd_EndpointStatusType_literals_[v]); return *this; @@ -2370,7 +2371,7 @@ namespace LinphonePrivate // JoiningType - // + // JoiningType:: JoiningType (Value v) @@ -2407,7 +2408,7 @@ namespace LinphonePrivate JoiningType& JoiningType:: operator= (Value v) { - static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = + static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = ::LinphonePrivate::Xsd::XmlSchema::String (_xsd_JoiningType_literals_[v]); return *this; @@ -2415,7 +2416,7 @@ namespace LinphonePrivate // DisconnectionType - // + // DisconnectionType:: DisconnectionType (Value v) @@ -2452,7 +2453,7 @@ namespace LinphonePrivate DisconnectionType& DisconnectionType:: operator= (Value v) { - static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = + static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = ::LinphonePrivate::Xsd::XmlSchema::String (_xsd_DisconnectionType_literals_[v]); return *this; @@ -2460,7 +2461,7 @@ namespace LinphonePrivate // ExecutionType - // + // const ExecutionType::WhenOptional& ExecutionType:: getWhen () const @@ -2584,7 +2585,7 @@ namespace LinphonePrivate // CallType - // + // const CallType::SipOptional& CallType:: getSip () const @@ -2666,7 +2667,7 @@ namespace LinphonePrivate // SipDialogIdType - // + // const SipDialogIdType::DisplayTextOptional& SipDialogIdType:: getDisplayText () const @@ -2838,7 +2839,7 @@ namespace LinphonePrivate // MediaType - // + // const MediaType::DisplayTextOptional& MediaType:: getDisplayText () const @@ -3070,7 +3071,7 @@ namespace LinphonePrivate // MediaStatusType - // + // MediaStatusType:: MediaStatusType (Value v) @@ -3107,7 +3108,7 @@ namespace LinphonePrivate MediaStatusType& MediaStatusType:: operator= (Value v) { - static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = + static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = ::LinphonePrivate::Xsd::XmlSchema::String (_xsd_MediaStatusType_literals_[v]); return *this; @@ -3115,7 +3116,7 @@ namespace LinphonePrivate // SidebarsByValType - // + // const SidebarsByValType::EntrySequence& SidebarsByValType:: getEntry () const @@ -3208,6 +3209,15 @@ namespace LinphonePrivate #include +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_factory_plate< 0, char > + type_factory_plate_init; +} + namespace LinphonePrivate { namespace Xsd @@ -6779,6 +6789,15 @@ namespace LinphonePrivate #include +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::std_ostream_plate< 0, char > + std_ostream_plate_init; +} + namespace LinphonePrivate { namespace Xsd @@ -7563,6 +7582,15 @@ namespace LinphonePrivate #include #include +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_serializer_plate< 0, char > + type_serializer_plate_init; +} + namespace LinphonePrivate { namespace Xsd @@ -9304,8 +9332,12 @@ namespace LinphonePrivate // Begin epilogue. // +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic pop #endif // // End epilogue. + diff --git a/src/xml/conference-info.h b/src/xml/conference-info.h index 79e9e19c3..cc7c48a96 100644 --- a/src/xml/conference-info.h +++ b/src/xml/conference-info.h @@ -51,9 +51,10 @@ #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wfloat-equal" -#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) - #pragma GCC diagnostic ignored "-Wsuggest-override" #endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" #endif // // End prologue. @@ -240,6 +241,8 @@ namespace LinphonePrivate typedef ::xsd::cxx::tree::unexpected_enumerator< char > UnexpectedEnumerator; typedef ::xsd::cxx::tree::expected_text_content< char > ExpectedTextContent; typedef ::xsd::cxx::tree::no_prefix_mapping< char > NoPrefixMapping; + typedef ::xsd::cxx::tree::no_type_info< char > NoTypeInfo; + typedef ::xsd::cxx::tree::not_derived< char > NotDerived; typedef ::xsd::cxx::tree::serialization< char > Serialization; // Error handler callback interface. @@ -573,7 +576,7 @@ namespace LinphonePrivate ConferenceType& operator= (const ConferenceType& x); - virtual + virtual ~ConferenceType (); // Implementation. @@ -882,7 +885,7 @@ namespace LinphonePrivate ConferenceDescriptionType& operator= (const ConferenceDescriptionType& x); - virtual + virtual ~ConferenceDescriptionType (); // Implementation. @@ -1030,7 +1033,7 @@ namespace LinphonePrivate HostType& operator= (const HostType& x); - virtual + virtual ~HostType (); // Implementation. @@ -1164,7 +1167,7 @@ namespace LinphonePrivate ConferenceStateType& operator= (const ConferenceStateType& x); - virtual + virtual ~ConferenceStateType (); // Implementation. @@ -1246,7 +1249,7 @@ namespace LinphonePrivate ConferenceMediaType& operator= (const ConferenceMediaType& x); - virtual + virtual ~ConferenceMediaType (); // Implementation. @@ -1406,7 +1409,7 @@ namespace LinphonePrivate ConferenceMediumType& operator= (const ConferenceMediumType& x); - virtual + virtual ~ConferenceMediumType (); // Implementation. @@ -1512,7 +1515,7 @@ namespace LinphonePrivate UrisType& operator= (const UrisType& x); - virtual + virtual ~UrisType (); // Implementation. @@ -1674,7 +1677,7 @@ namespace LinphonePrivate UriType& operator= (const UriType& x); - virtual + virtual ~UriType (); // Implementation. @@ -1730,7 +1733,7 @@ namespace LinphonePrivate _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; - virtual + virtual ~KeywordsType (); }; @@ -1834,7 +1837,7 @@ namespace LinphonePrivate UsersType& operator= (const UsersType& x); - virtual + virtual ~UsersType (); // Implementation. @@ -2080,7 +2083,7 @@ namespace LinphonePrivate UserType& operator= (const UserType& x); - virtual + virtual ~UserType (); // Implementation. @@ -2168,7 +2171,7 @@ namespace LinphonePrivate UserRolesType& operator= (const UserRolesType& x); - virtual + virtual ~UserRolesType (); // Implementation. @@ -2220,7 +2223,7 @@ namespace LinphonePrivate _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; - virtual + virtual ~UserLanguagesType (); }; @@ -2513,7 +2516,7 @@ namespace LinphonePrivate EndpointType& operator= (const EndpointType& x); - virtual + virtual ~EndpointType (); // Implementation. @@ -2828,7 +2831,7 @@ namespace LinphonePrivate ExecutionType& operator= (const ExecutionType& x); - virtual + virtual ~ExecutionType (); // Implementation. @@ -2928,7 +2931,7 @@ namespace LinphonePrivate CallType& operator= (const CallType& x); - virtual + virtual ~CallType (); // Implementation. @@ -3089,7 +3092,7 @@ namespace LinphonePrivate SipDialogIdType& operator= (const SipDialogIdType& x); - virtual + virtual ~SipDialogIdType (); // Implementation. @@ -3295,7 +3298,7 @@ namespace LinphonePrivate MediaType& operator= (const MediaType& x); - virtual + virtual ~MediaType (); // Implementation. @@ -3461,7 +3464,7 @@ namespace LinphonePrivate SidebarsByValType& operator= (const SidebarsByValType& x); - virtual + virtual ~SidebarsByValType (); // Implementation. @@ -3708,14 +3711,14 @@ namespace LinphonePrivate void serializeConferenceInfo (::std::ostream& os, - const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, + const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); void serializeConferenceInfo (::std::ostream& os, - const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, + const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", @@ -3723,7 +3726,7 @@ namespace LinphonePrivate void serializeConferenceInfo (::std::ostream& os, - const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, + const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, ::xercesc::DOMErrorHandler& eh, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", @@ -3734,14 +3737,14 @@ namespace LinphonePrivate void serializeConferenceInfo (::xercesc::XMLFormatTarget& ft, - const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, + const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); void serializeConferenceInfo (::xercesc::XMLFormatTarget& ft, - const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, + const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", @@ -3749,7 +3752,7 @@ namespace LinphonePrivate void serializeConferenceInfo (::xercesc::XMLFormatTarget& ft, - const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, + const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, ::xercesc::DOMErrorHandler& eh, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", @@ -3767,7 +3770,7 @@ namespace LinphonePrivate // ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > - serializeConferenceInfo (const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, + serializeConferenceInfo (const ::LinphonePrivate::Xsd::ConferenceInfo::ConferenceType& x, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); @@ -3899,6 +3902,9 @@ namespace LinphonePrivate // Begin epilogue. // +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic pop #endif diff --git a/src/xml/epilogue.txt b/src/xml/epilogue.txt index ebe68c888..b4e4ec06e 100644 --- a/src/xml/epilogue.txt +++ b/src/xml/epilogue.txt @@ -1,3 +1,6 @@ +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic pop #endif diff --git a/src/xml/generate.py b/src/xml/generate.py index 0046c4b05..c2fb8075a 100755 --- a/src/xml/generate.py +++ b/src/xml/generate.py @@ -51,6 +51,7 @@ def generate(name): "--generate-serialization", "--generate-ostream", "--generate-detach", + "--generate-polymorphic", "--std", "c++11", "--type-naming", "java", "--function-naming", "java", @@ -62,6 +63,7 @@ def generate(name): "--show-sloc", "--prologue-file", prologue_file, "--epilogue-file", epilogue_file, + "--root-element-first", "--type-regex", "%(?:[^ ]* )?([^,-]+)-([^,-]+)-([^,-]+)-?([^,-]*)%\\u$1\\u$2\\u$3\\u$4%", "--type-regex", "%(?:[^ ]* )?([^,-]+)-([^,-]+)-?([^,-]*)%\\u$1\\u$2\\u$3%", "--type-regex", "%(?:[^ ]* )?([^,-]+)-?([^,-]*)%\\u$1\\u$2%", @@ -90,6 +92,8 @@ def generate(name): "--serializer-regex", "%([^-]+)-?([^-]*)%serialize\\u$1\\u$2%", "--namespace-map", "http://www.w3.org/2001/XMLSchema=LinphonePrivate::Xsd::XmlSchema", "--namespace-map", "urn:ietf:params:xml:ns:conference-info=LinphonePrivate::Xsd::ConferenceInfo", + "--namespace-map", "urn:ietf:params:xml:ns:imdn=LinphonePrivate::Xsd::Imdn", + "--namespace-map", "http://www.linphone.org/xsds/imdn.xsd=LinphonePrivate::Xsd::LinphoneImdn", "--namespace-map", "urn:ietf:params:xml:ns:resource-lists=LinphonePrivate::Xsd::ResourceLists", source_file ], shell=False) @@ -100,6 +104,8 @@ def generate(name): def main(argv = None): generate("xml") generate("conference-info") + generate("imdn") + generate("linphone-imdn") generate("resource-lists") if __name__ == "__main__": diff --git a/src/xml/imdn.cpp b/src/xml/imdn.cpp new file mode 100644 index 000000000..d180b9078 --- /dev/null +++ b/src/xml/imdn.cpp @@ -0,0 +1,3440 @@ +// Copyright (c) 2005-2014 Code Synthesis Tools CC +// +// This program was generated by CodeSynthesis XSD, an XML Schema to +// C++ data binding compiler. +// +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License version 2 as +// published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the Free Software +// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +// +// In addition, as a special exception, Code Synthesis Tools CC gives +// permission to link this program with the Xerces-C++ library (or with +// modified versions of Xerces-C++ that use the same license as Xerces-C++), +// and distribute linked combinations including the two. You must obey +// the GNU General Public License version 2 in all respects for all of +// the code used other than Xerces-C++. If you modify this copy of the +// program, you may extend this exception to your version of the program, +// but you are not obligated to do so. If you do not wish to do so, delete +// this exception statement from your version. +// +// Furthermore, Code Synthesis Tools CC makes a special exception for +// the Free/Libre and Open Source Software (FLOSS) which is described +// in the accompanying FLOSSE file. +// + +// Begin prologue. +// +#if __clang__ || __GNUC__ >= 4 + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wfloat-equal" +#endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" +#endif +// +// End prologue. + +#include + +#include "imdn.h" + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + // Imdn + // + + const Imdn::MessageIdType& Imdn:: + getMessageId () const + { + return this->message_id_.get (); + } + + Imdn::MessageIdType& Imdn:: + getMessageId () + { + return this->message_id_.get (); + } + + void Imdn:: + setMessageId (const MessageIdType& x) + { + this->message_id_.set (x); + } + + void Imdn:: + setMessageId (::std::unique_ptr< MessageIdType > x) + { + this->message_id_.set (std::move (x)); + } + + ::std::unique_ptr< Imdn::MessageIdType > Imdn:: + setDetachMessage_id () + { + return this->message_id_.detach (); + } + + const Imdn::DatetimeType& Imdn:: + getDatetime () const + { + return this->datetime_.get (); + } + + Imdn::DatetimeType& Imdn:: + getDatetime () + { + return this->datetime_.get (); + } + + void Imdn:: + setDatetime (const DatetimeType& x) + { + this->datetime_.set (x); + } + + void Imdn:: + setDatetime (::std::unique_ptr< DatetimeType > x) + { + this->datetime_.set (std::move (x)); + } + + ::std::unique_ptr< Imdn::DatetimeType > Imdn:: + setDetachDatetime () + { + return this->datetime_.detach (); + } + + const Imdn::RecipientUriOptional& Imdn:: + getRecipientUri () const + { + return this->recipient_uri_; + } + + Imdn::RecipientUriOptional& Imdn:: + getRecipientUri () + { + return this->recipient_uri_; + } + + void Imdn:: + setRecipientUri (const RecipientUriType& x) + { + this->recipient_uri_.set (x); + } + + void Imdn:: + setRecipientUri (const RecipientUriOptional& x) + { + this->recipient_uri_ = x; + } + + void Imdn:: + setRecipientUri (::std::unique_ptr< RecipientUriType > x) + { + this->recipient_uri_.set (std::move (x)); + } + + const Imdn::OriginalRecipientUriOptional& Imdn:: + getOriginalRecipientUri () const + { + return this->original_recipient_uri_; + } + + Imdn::OriginalRecipientUriOptional& Imdn:: + getOriginalRecipientUri () + { + return this->original_recipient_uri_; + } + + void Imdn:: + setOriginalRecipientUri (const OriginalRecipientUriType& x) + { + this->original_recipient_uri_.set (x); + } + + void Imdn:: + setOriginalRecipientUri (const OriginalRecipientUriOptional& x) + { + this->original_recipient_uri_ = x; + } + + void Imdn:: + setOriginalRecipientUri (::std::unique_ptr< OriginalRecipientUriType > x) + { + this->original_recipient_uri_.set (std::move (x)); + } + + const Imdn::SubjectOptional& Imdn:: + getSubject () const + { + return this->subject_; + } + + Imdn::SubjectOptional& Imdn:: + getSubject () + { + return this->subject_; + } + + void Imdn:: + setSubject (const SubjectType& x) + { + this->subject_.set (x); + } + + void Imdn:: + setSubject (const SubjectOptional& x) + { + this->subject_ = x; + } + + void Imdn:: + setSubject (::std::unique_ptr< SubjectType > x) + { + this->subject_.set (std::move (x)); + } + + const Imdn::DeliveryNotificationOptional& Imdn:: + getDeliveryNotification () const + { + return this->delivery_notification_; + } + + Imdn::DeliveryNotificationOptional& Imdn:: + getDeliveryNotification () + { + return this->delivery_notification_; + } + + void Imdn:: + setDeliveryNotification (const DeliveryNotificationType& x) + { + this->delivery_notification_.set (x); + } + + void Imdn:: + setDeliveryNotification (const DeliveryNotificationOptional& x) + { + this->delivery_notification_ = x; + } + + void Imdn:: + setDeliveryNotification (::std::unique_ptr< DeliveryNotificationType > x) + { + this->delivery_notification_.set (std::move (x)); + } + + const Imdn::DisplayNotificationOptional& Imdn:: + getDisplayNotification () const + { + return this->display_notification_; + } + + Imdn::DisplayNotificationOptional& Imdn:: + getDisplayNotification () + { + return this->display_notification_; + } + + void Imdn:: + setDisplayNotification (const DisplayNotificationType& x) + { + this->display_notification_.set (x); + } + + void Imdn:: + setDisplayNotification (const DisplayNotificationOptional& x) + { + this->display_notification_ = x; + } + + void Imdn:: + setDisplayNotification (::std::unique_ptr< DisplayNotificationType > x) + { + this->display_notification_.set (std::move (x)); + } + + const Imdn::ProcessingNotificationOptional& Imdn:: + getProcessingNotification () const + { + return this->processing_notification_; + } + + Imdn::ProcessingNotificationOptional& Imdn:: + getProcessingNotification () + { + return this->processing_notification_; + } + + void Imdn:: + setProcessingNotification (const ProcessingNotificationType& x) + { + this->processing_notification_.set (x); + } + + void Imdn:: + setProcessingNotification (const ProcessingNotificationOptional& x) + { + this->processing_notification_ = x; + } + + void Imdn:: + setProcessingNotification (::std::unique_ptr< ProcessingNotificationType > x) + { + this->processing_notification_.set (std::move (x)); + } + + const Imdn::AnySequence& Imdn:: + getAny () const + { + return this->any_; + } + + Imdn::AnySequence& Imdn:: + getAny () + { + return this->any_; + } + + void Imdn:: + setAny (const AnySequence& s) + { + this->any_ = s; + } + + const ::xercesc::DOMDocument& Imdn:: + getDomDocument () const + { + return *this->dom_document_; + } + + ::xercesc::DOMDocument& Imdn:: + getDomDocument () + { + return *this->dom_document_; + } + + + // DeliveryNotification + // + + const DeliveryNotification::StatusType& DeliveryNotification:: + getStatus () const + { + return this->status_.get (); + } + + DeliveryNotification::StatusType& DeliveryNotification:: + getStatus () + { + return this->status_.get (); + } + + void DeliveryNotification:: + setStatus (const StatusType& x) + { + this->status_.set (x); + } + + void DeliveryNotification:: + setStatus (::std::unique_ptr< StatusType > x) + { + this->status_.set (std::move (x)); + } + + ::std::unique_ptr< DeliveryNotification::StatusType > DeliveryNotification:: + setDetachStatus () + { + return this->status_.detach (); + } + + + // Delivered + // + + + // Failed + // + + + // DisplayNotification + // + + const DisplayNotification::StatusType& DisplayNotification:: + getStatus () const + { + return this->status_.get (); + } + + DisplayNotification::StatusType& DisplayNotification:: + getStatus () + { + return this->status_.get (); + } + + void DisplayNotification:: + setStatus (const StatusType& x) + { + this->status_.set (x); + } + + void DisplayNotification:: + setStatus (::std::unique_ptr< StatusType > x) + { + this->status_.set (std::move (x)); + } + + ::std::unique_ptr< DisplayNotification::StatusType > DisplayNotification:: + setDetachStatus () + { + return this->status_.detach (); + } + + + // Displayed + // + + + // ProcessingNotification + // + + const ProcessingNotification::StatusType& ProcessingNotification:: + getStatus () const + { + return this->status_.get (); + } + + ProcessingNotification::StatusType& ProcessingNotification:: + getStatus () + { + return this->status_.get (); + } + + void ProcessingNotification:: + setStatus (const StatusType& x) + { + this->status_.set (x); + } + + void ProcessingNotification:: + setStatus (::std::unique_ptr< StatusType > x) + { + this->status_.set (std::move (x)); + } + + ::std::unique_ptr< ProcessingNotification::StatusType > ProcessingNotification:: + setDetachStatus () + { + return this->status_.detach (); + } + + + // Processed + // + + + // Stored + // + + + // Forbidden + // + + + // Error + // + + + // Status + // + + const Status::DeliveredOptional& Status:: + getDelivered () const + { + return this->delivered_; + } + + Status::DeliveredOptional& Status:: + getDelivered () + { + return this->delivered_; + } + + void Status:: + setDelivered (const DeliveredType& x) + { + this->delivered_.set (x); + } + + void Status:: + setDelivered (const DeliveredOptional& x) + { + this->delivered_ = x; + } + + void Status:: + setDelivered (::std::unique_ptr< DeliveredType > x) + { + this->delivered_.set (std::move (x)); + } + + const Status::FailedOptional& Status:: + getFailed () const + { + return this->failed_; + } + + Status::FailedOptional& Status:: + getFailed () + { + return this->failed_; + } + + void Status:: + setFailed (const FailedType& x) + { + this->failed_.set (x); + } + + void Status:: + setFailed (const FailedOptional& x) + { + this->failed_ = x; + } + + void Status:: + setFailed (::std::unique_ptr< FailedType > x) + { + this->failed_.set (std::move (x)); + } + + const Status::ForbiddenOptional& Status:: + getForbidden () const + { + return this->forbidden_; + } + + Status::ForbiddenOptional& Status:: + getForbidden () + { + return this->forbidden_; + } + + void Status:: + setForbidden (const ForbiddenType& x) + { + this->forbidden_.set (x); + } + + void Status:: + setForbidden (const ForbiddenOptional& x) + { + this->forbidden_ = x; + } + + void Status:: + setForbidden (::std::unique_ptr< ForbiddenType > x) + { + this->forbidden_.set (std::move (x)); + } + + const Status::ErrorOptional& Status:: + getError () const + { + return this->error_; + } + + Status::ErrorOptional& Status:: + getError () + { + return this->error_; + } + + void Status:: + setError (const ErrorType& x) + { + this->error_.set (x); + } + + void Status:: + setError (const ErrorOptional& x) + { + this->error_ = x; + } + + void Status:: + setError (::std::unique_ptr< ErrorType > x) + { + this->error_.set (std::move (x)); + } + + const Status::ReasonOptional& Status:: + getReason () const + { + return this->reason_; + } + + Status::ReasonOptional& Status:: + getReason () + { + return this->reason_; + } + + void Status:: + setReason (const ReasonType& x) + { + this->reason_.set (x); + } + + void Status:: + setReason (const ReasonOptional& x) + { + this->reason_ = x; + } + + void Status:: + setReason (::std::unique_ptr< ReasonType > x) + { + this->reason_.set (std::move (x)); + } + + + // Status1 + // + + const Status1::DisplayedOptional& Status1:: + getDisplayed () const + { + return this->displayed_; + } + + Status1::DisplayedOptional& Status1:: + getDisplayed () + { + return this->displayed_; + } + + void Status1:: + setDisplayed (const DisplayedType& x) + { + this->displayed_.set (x); + } + + void Status1:: + setDisplayed (const DisplayedOptional& x) + { + this->displayed_ = x; + } + + void Status1:: + setDisplayed (::std::unique_ptr< DisplayedType > x) + { + this->displayed_.set (std::move (x)); + } + + const Status1::ForbiddenOptional& Status1:: + getForbidden () const + { + return this->forbidden_; + } + + Status1::ForbiddenOptional& Status1:: + getForbidden () + { + return this->forbidden_; + } + + void Status1:: + setForbidden (const ForbiddenType& x) + { + this->forbidden_.set (x); + } + + void Status1:: + setForbidden (const ForbiddenOptional& x) + { + this->forbidden_ = x; + } + + void Status1:: + setForbidden (::std::unique_ptr< ForbiddenType > x) + { + this->forbidden_.set (std::move (x)); + } + + const Status1::ErrorOptional& Status1:: + getError () const + { + return this->error_; + } + + Status1::ErrorOptional& Status1:: + getError () + { + return this->error_; + } + + void Status1:: + setError (const ErrorType& x) + { + this->error_.set (x); + } + + void Status1:: + setError (const ErrorOptional& x) + { + this->error_ = x; + } + + void Status1:: + setError (::std::unique_ptr< ErrorType > x) + { + this->error_.set (std::move (x)); + } + + const Status1::AnySequence& Status1:: + getAny () const + { + return this->any_; + } + + Status1::AnySequence& Status1:: + getAny () + { + return this->any_; + } + + void Status1:: + setAny (const AnySequence& s) + { + this->any_ = s; + } + + const ::xercesc::DOMDocument& Status1:: + getDomDocument () const + { + return *this->dom_document_; + } + + ::xercesc::DOMDocument& Status1:: + getDomDocument () + { + return *this->dom_document_; + } + + + // Status2 + // + + const Status2::ProcessedOptional& Status2:: + getProcessed () const + { + return this->processed_; + } + + Status2::ProcessedOptional& Status2:: + getProcessed () + { + return this->processed_; + } + + void Status2:: + setProcessed (const ProcessedType& x) + { + this->processed_.set (x); + } + + void Status2:: + setProcessed (const ProcessedOptional& x) + { + this->processed_ = x; + } + + void Status2:: + setProcessed (::std::unique_ptr< ProcessedType > x) + { + this->processed_.set (std::move (x)); + } + + const Status2::StoredOptional& Status2:: + getStored () const + { + return this->stored_; + } + + Status2::StoredOptional& Status2:: + getStored () + { + return this->stored_; + } + + void Status2:: + setStored (const StoredType& x) + { + this->stored_.set (x); + } + + void Status2:: + setStored (const StoredOptional& x) + { + this->stored_ = x; + } + + void Status2:: + setStored (::std::unique_ptr< StoredType > x) + { + this->stored_.set (std::move (x)); + } + + const Status2::ForbiddenOptional& Status2:: + getForbidden () const + { + return this->forbidden_; + } + + Status2::ForbiddenOptional& Status2:: + getForbidden () + { + return this->forbidden_; + } + + void Status2:: + setForbidden (const ForbiddenType& x) + { + this->forbidden_.set (x); + } + + void Status2:: + setForbidden (const ForbiddenOptional& x) + { + this->forbidden_ = x; + } + + void Status2:: + setForbidden (::std::unique_ptr< ForbiddenType > x) + { + this->forbidden_.set (std::move (x)); + } + + const Status2::ErrorOptional& Status2:: + getError () const + { + return this->error_; + } + + Status2::ErrorOptional& Status2:: + getError () + { + return this->error_; + } + + void Status2:: + setError (const ErrorType& x) + { + this->error_.set (x); + } + + void Status2:: + setError (const ErrorOptional& x) + { + this->error_ = x; + } + + void Status2:: + setError (::std::unique_ptr< ErrorType > x) + { + this->error_.set (std::move (x)); + } + + const Status2::AnySequence& Status2:: + getAny () const + { + return this->any_; + } + + Status2::AnySequence& Status2:: + getAny () + { + return this->any_; + } + + void Status2:: + setAny (const AnySequence& s) + { + this->any_ = s; + } + + const ::xercesc::DOMDocument& Status2:: + getDomDocument () const + { + return *this->dom_document_; + } + + ::xercesc::DOMDocument& Status2:: + getDomDocument () + { + return *this->dom_document_; + } + } + } +} + +#include + +#include + +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_factory_plate< 0, char > + type_factory_plate_init; +} + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + // Imdn + // + + Imdn:: + Imdn (const MessageIdType& message_id, + const DatetimeType& datetime) + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + dom_document_ (::xsd::cxx::xml::dom::create_document< char > ()), + message_id_ (message_id, this), + datetime_ (datetime, this), + recipient_uri_ (this), + original_recipient_uri_ (this), + subject_ (this), + delivery_notification_ (this), + display_notification_ (this), + processing_notification_ (this), + any_ (this->getDomDocument ()) + { + } + + Imdn:: + Imdn (const Imdn& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c), + dom_document_ (::xsd::cxx::xml::dom::create_document< char > ()), + message_id_ (x.message_id_, f, this), + datetime_ (x.datetime_, f, this), + recipient_uri_ (x.recipient_uri_, f, this), + original_recipient_uri_ (x.original_recipient_uri_, f, this), + subject_ (x.subject_, f, this), + delivery_notification_ (x.delivery_notification_, f, this), + display_notification_ (x.display_notification_, f, this), + processing_notification_ (x.processing_notification_, f, this), + any_ (x.any_, this->getDomDocument ()) + { + } + + Imdn:: + Imdn (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f | ::LinphonePrivate::Xsd::XmlSchema::Flags::base, c), + dom_document_ (::xsd::cxx::xml::dom::create_document< char > ()), + message_id_ (this), + datetime_ (this), + recipient_uri_ (this), + original_recipient_uri_ (this), + subject_ (this), + delivery_notification_ (this), + display_notification_ (this), + processing_notification_ (this), + any_ (this->getDomDocument ()) + { + if ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::base) == 0) + { + ::xsd::cxx::xml::dom::parser< char > p (e, true, false, false); + this->parse (p, f); + } + } + + void Imdn:: + parse (::xsd::cxx::xml::dom::parser< char >& p, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + for (; p.more_content (); p.next_content (false)) + { + const ::xercesc::DOMElement& i (p.cur_element ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (i)); + + // message-id + // + if (n.name () == "message-id" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< MessageIdType > r ( + MessageIdTraits::create (i, f, this)); + + if (!message_id_.present ()) + { + this->message_id_.set (::std::move (r)); + continue; + } + } + + // datetime + // + if (n.name () == "datetime" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< DatetimeType > r ( + DatetimeTraits::create (i, f, this)); + + if (!datetime_.present ()) + { + this->datetime_.set (::std::move (r)); + continue; + } + } + + // recipient-uri + // + if (n.name () == "recipient-uri" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< RecipientUriType > r ( + RecipientUriTraits::create (i, f, this)); + + if (!this->recipient_uri_) + { + this->recipient_uri_.set (::std::move (r)); + continue; + } + } + + // original-recipient-uri + // + if (n.name () == "original-recipient-uri" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< OriginalRecipientUriType > r ( + OriginalRecipientUriTraits::create (i, f, this)); + + if (!this->original_recipient_uri_) + { + this->original_recipient_uri_.set (::std::move (r)); + continue; + } + } + + // subject + // + if (n.name () == "subject" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< SubjectType > r ( + SubjectTraits::create (i, f, this)); + + if (!this->subject_) + { + this->subject_.set (::std::move (r)); + continue; + } + } + + // delivery-notification + // + if (n.name () == "delivery-notification" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< DeliveryNotificationType > r ( + DeliveryNotificationTraits::create (i, f, this)); + + if (!this->delivery_notification_) + { + this->delivery_notification_.set (::std::move (r)); + continue; + } + } + + // display-notification + // + if (n.name () == "display-notification" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< DisplayNotificationType > r ( + DisplayNotificationTraits::create (i, f, this)); + + if (!this->display_notification_) + { + this->display_notification_.set (::std::move (r)); + continue; + } + } + + // processing-notification + // + if (n.name () == "processing-notification" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ProcessingNotificationType > r ( + ProcessingNotificationTraits::create (i, f, this)); + + if (!this->processing_notification_) + { + this->processing_notification_.set (::std::move (r)); + continue; + } + } + + // any + // + if ((!n.namespace_ ().empty () && n.namespace_ () != "urn:ietf:params:xml:ns:imdn")) + { + ::xercesc::DOMElement* r ( + static_cast< ::xercesc::DOMElement* > ( + this->getDomDocument ().importNode ( + const_cast< ::xercesc::DOMElement* > (&i), true))); + this->any_.push_back (r); + continue; + } + + break; + } + + if (!message_id_.present ()) + { + throw ::xsd::cxx::tree::expected_element< char > ( + "message-id", + "urn:ietf:params:xml:ns:imdn"); + } + + if (!datetime_.present ()) + { + throw ::xsd::cxx::tree::expected_element< char > ( + "datetime", + "urn:ietf:params:xml:ns:imdn"); + } + } + + Imdn* Imdn:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Imdn (*this, f, c); + } + + Imdn& Imdn:: + operator= (const Imdn& x) + { + if (this != &x) + { + static_cast< ::LinphonePrivate::Xsd::XmlSchema::Type& > (*this) = x; + this->message_id_ = x.message_id_; + this->datetime_ = x.datetime_; + this->recipient_uri_ = x.recipient_uri_; + this->original_recipient_uri_ = x.original_recipient_uri_; + this->subject_ = x.subject_; + this->delivery_notification_ = x.delivery_notification_; + this->display_notification_ = x.display_notification_; + this->processing_notification_ = x.processing_notification_; + this->any_ = x.any_; + } + + return *this; + } + + Imdn:: + ~Imdn () + { + } + + // DeliveryNotification + // + + DeliveryNotification:: + DeliveryNotification (const StatusType& status) + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + status_ (status, this) + { + } + + DeliveryNotification:: + DeliveryNotification (::std::unique_ptr< StatusType > status) + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + status_ (std::move (status), this) + { + } + + DeliveryNotification:: + DeliveryNotification (const DeliveryNotification& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c), + status_ (x.status_, f, this) + { + } + + DeliveryNotification:: + DeliveryNotification (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f | ::LinphonePrivate::Xsd::XmlSchema::Flags::base, c), + status_ (this) + { + if ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::base) == 0) + { + ::xsd::cxx::xml::dom::parser< char > p (e, true, false, false); + this->parse (p, f); + } + } + + void DeliveryNotification:: + parse (::xsd::cxx::xml::dom::parser< char >& p, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + for (; p.more_content (); p.next_content (false)) + { + const ::xercesc::DOMElement& i (p.cur_element ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (i)); + + // status + // + if (n.name () == "status" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< StatusType > r ( + StatusTraits::create (i, f, this)); + + if (!status_.present ()) + { + this->status_.set (::std::move (r)); + continue; + } + } + + break; + } + + if (!status_.present ()) + { + throw ::xsd::cxx::tree::expected_element< char > ( + "status", + "urn:ietf:params:xml:ns:imdn"); + } + } + + DeliveryNotification* DeliveryNotification:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class DeliveryNotification (*this, f, c); + } + + DeliveryNotification& DeliveryNotification:: + operator= (const DeliveryNotification& x) + { + if (this != &x) + { + static_cast< ::LinphonePrivate::Xsd::XmlSchema::Type& > (*this) = x; + this->status_ = x.status_; + } + + return *this; + } + + DeliveryNotification:: + ~DeliveryNotification () + { + } + + // Delivered + // + + Delivered:: + Delivered () + : ::LinphonePrivate::Xsd::XmlSchema::Type () + { + } + + Delivered:: + Delivered (const Delivered& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c) + { + } + + Delivered:: + Delivered (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f, c) + { + } + + Delivered:: + Delivered (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (a, f, c) + { + } + + Delivered:: + Delivered (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (s, e, f, c) + { + } + + Delivered* Delivered:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Delivered (*this, f, c); + } + + Delivered:: + ~Delivered () + { + } + + // Failed + // + + Failed:: + Failed () + : ::LinphonePrivate::Xsd::XmlSchema::Type () + { + } + + Failed:: + Failed (const Failed& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c) + { + } + + Failed:: + Failed (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f, c) + { + } + + Failed:: + Failed (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (a, f, c) + { + } + + Failed:: + Failed (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (s, e, f, c) + { + } + + Failed* Failed:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Failed (*this, f, c); + } + + Failed:: + ~Failed () + { + } + + // DisplayNotification + // + + DisplayNotification:: + DisplayNotification (const StatusType& status) + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + status_ (status, this) + { + } + + DisplayNotification:: + DisplayNotification (::std::unique_ptr< StatusType > status) + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + status_ (std::move (status), this) + { + } + + DisplayNotification:: + DisplayNotification (const DisplayNotification& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c), + status_ (x.status_, f, this) + { + } + + DisplayNotification:: + DisplayNotification (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f | ::LinphonePrivate::Xsd::XmlSchema::Flags::base, c), + status_ (this) + { + if ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::base) == 0) + { + ::xsd::cxx::xml::dom::parser< char > p (e, true, false, false); + this->parse (p, f); + } + } + + void DisplayNotification:: + parse (::xsd::cxx::xml::dom::parser< char >& p, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + for (; p.more_content (); p.next_content (false)) + { + const ::xercesc::DOMElement& i (p.cur_element ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (i)); + + // status + // + if (n.name () == "status" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< StatusType > r ( + StatusTraits::create (i, f, this)); + + if (!status_.present ()) + { + this->status_.set (::std::move (r)); + continue; + } + } + + break; + } + + if (!status_.present ()) + { + throw ::xsd::cxx::tree::expected_element< char > ( + "status", + "urn:ietf:params:xml:ns:imdn"); + } + } + + DisplayNotification* DisplayNotification:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class DisplayNotification (*this, f, c); + } + + DisplayNotification& DisplayNotification:: + operator= (const DisplayNotification& x) + { + if (this != &x) + { + static_cast< ::LinphonePrivate::Xsd::XmlSchema::Type& > (*this) = x; + this->status_ = x.status_; + } + + return *this; + } + + DisplayNotification:: + ~DisplayNotification () + { + } + + // Displayed + // + + Displayed:: + Displayed () + : ::LinphonePrivate::Xsd::XmlSchema::Type () + { + } + + Displayed:: + Displayed (const Displayed& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c) + { + } + + Displayed:: + Displayed (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f, c) + { + } + + Displayed:: + Displayed (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (a, f, c) + { + } + + Displayed:: + Displayed (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (s, e, f, c) + { + } + + Displayed* Displayed:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Displayed (*this, f, c); + } + + Displayed:: + ~Displayed () + { + } + + // ProcessingNotification + // + + ProcessingNotification:: + ProcessingNotification (const StatusType& status) + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + status_ (status, this) + { + } + + ProcessingNotification:: + ProcessingNotification (::std::unique_ptr< StatusType > status) + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + status_ (std::move (status), this) + { + } + + ProcessingNotification:: + ProcessingNotification (const ProcessingNotification& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c), + status_ (x.status_, f, this) + { + } + + ProcessingNotification:: + ProcessingNotification (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f | ::LinphonePrivate::Xsd::XmlSchema::Flags::base, c), + status_ (this) + { + if ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::base) == 0) + { + ::xsd::cxx::xml::dom::parser< char > p (e, true, false, false); + this->parse (p, f); + } + } + + void ProcessingNotification:: + parse (::xsd::cxx::xml::dom::parser< char >& p, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + for (; p.more_content (); p.next_content (false)) + { + const ::xercesc::DOMElement& i (p.cur_element ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (i)); + + // status + // + if (n.name () == "status" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< StatusType > r ( + StatusTraits::create (i, f, this)); + + if (!status_.present ()) + { + this->status_.set (::std::move (r)); + continue; + } + } + + break; + } + + if (!status_.present ()) + { + throw ::xsd::cxx::tree::expected_element< char > ( + "status", + "urn:ietf:params:xml:ns:imdn"); + } + } + + ProcessingNotification* ProcessingNotification:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class ProcessingNotification (*this, f, c); + } + + ProcessingNotification& ProcessingNotification:: + operator= (const ProcessingNotification& x) + { + if (this != &x) + { + static_cast< ::LinphonePrivate::Xsd::XmlSchema::Type& > (*this) = x; + this->status_ = x.status_; + } + + return *this; + } + + ProcessingNotification:: + ~ProcessingNotification () + { + } + + // Processed + // + + Processed:: + Processed () + : ::LinphonePrivate::Xsd::XmlSchema::Type () + { + } + + Processed:: + Processed (const Processed& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c) + { + } + + Processed:: + Processed (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f, c) + { + } + + Processed:: + Processed (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (a, f, c) + { + } + + Processed:: + Processed (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (s, e, f, c) + { + } + + Processed* Processed:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Processed (*this, f, c); + } + + Processed:: + ~Processed () + { + } + + // Stored + // + + Stored:: + Stored () + : ::LinphonePrivate::Xsd::XmlSchema::Type () + { + } + + Stored:: + Stored (const Stored& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c) + { + } + + Stored:: + Stored (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f, c) + { + } + + Stored:: + Stored (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (a, f, c) + { + } + + Stored:: + Stored (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (s, e, f, c) + { + } + + Stored* Stored:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Stored (*this, f, c); + } + + Stored:: + ~Stored () + { + } + + // Forbidden + // + + Forbidden:: + Forbidden () + : ::LinphonePrivate::Xsd::XmlSchema::Type () + { + } + + Forbidden:: + Forbidden (const Forbidden& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c) + { + } + + Forbidden:: + Forbidden (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f, c) + { + } + + Forbidden:: + Forbidden (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (a, f, c) + { + } + + Forbidden:: + Forbidden (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (s, e, f, c) + { + } + + Forbidden* Forbidden:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Forbidden (*this, f, c); + } + + Forbidden:: + ~Forbidden () + { + } + + // Error + // + + Error:: + Error () + : ::LinphonePrivate::Xsd::XmlSchema::Type () + { + } + + Error:: + Error (const Error& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c) + { + } + + Error:: + Error (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f, c) + { + } + + Error:: + Error (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (a, f, c) + { + } + + Error:: + Error (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (s, e, f, c) + { + } + + Error* Error:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Error (*this, f, c); + } + + Error:: + ~Error () + { + } + + // Status + // + + Status:: + Status () + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + delivered_ (this), + failed_ (this), + forbidden_ (this), + error_ (this), + reason_ (this) + { + } + + Status:: + Status (const Status& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c), + delivered_ (x.delivered_, f, this), + failed_ (x.failed_, f, this), + forbidden_ (x.forbidden_, f, this), + error_ (x.error_, f, this), + reason_ (x.reason_, f, this) + { + } + + Status:: + Status (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f | ::LinphonePrivate::Xsd::XmlSchema::Flags::base, c), + delivered_ (this), + failed_ (this), + forbidden_ (this), + error_ (this), + reason_ (this) + { + if ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::base) == 0) + { + ::xsd::cxx::xml::dom::parser< char > p (e, true, false, false); + this->parse (p, f); + } + } + + void Status:: + parse (::xsd::cxx::xml::dom::parser< char >& p, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + for (; p.more_content (); p.next_content (false)) + { + const ::xercesc::DOMElement& i (p.cur_element ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (i)); + + // delivered + // + if (n.name () == "delivered" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< DeliveredType > r ( + DeliveredTraits::create (i, f, this)); + + if (!this->delivered_) + { + this->delivered_.set (::std::move (r)); + continue; + } + } + + // failed + // + if (n.name () == "failed" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< FailedType > r ( + FailedTraits::create (i, f, this)); + + if (!this->failed_) + { + this->failed_.set (::std::move (r)); + continue; + } + } + + // forbidden + // + if (n.name () == "forbidden" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ForbiddenType > r ( + ForbiddenTraits::create (i, f, this)); + + if (!this->forbidden_) + { + this->forbidden_.set (::std::move (r)); + continue; + } + } + + // error + // + if (n.name () == "error" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ErrorType > r ( + ErrorTraits::create (i, f, this)); + + if (!this->error_) + { + this->error_.set (::std::move (r)); + continue; + } + } + + // reason + // + if (n.name () == "reason" && n.namespace_ () == "http://www.linphone.org/xsds/imdn.xsd") + { + ::std::unique_ptr< ReasonType > r ( + ReasonTraits::create (i, f, this)); + + if (!this->reason_) + { + this->reason_.set (::std::move (r)); + continue; + } + } + + break; + } + } + + Status* Status:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Status (*this, f, c); + } + + Status& Status:: + operator= (const Status& x) + { + if (this != &x) + { + static_cast< ::LinphonePrivate::Xsd::XmlSchema::Type& > (*this) = x; + this->delivered_ = x.delivered_; + this->failed_ = x.failed_; + this->forbidden_ = x.forbidden_; + this->error_ = x.error_; + this->reason_ = x.reason_; + } + + return *this; + } + + Status:: + ~Status () + { + } + + // Status1 + // + + Status1:: + Status1 () + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + dom_document_ (::xsd::cxx::xml::dom::create_document< char > ()), + displayed_ (this), + forbidden_ (this), + error_ (this), + any_ (this->getDomDocument ()) + { + } + + Status1:: + Status1 (const Status1& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c), + dom_document_ (::xsd::cxx::xml::dom::create_document< char > ()), + displayed_ (x.displayed_, f, this), + forbidden_ (x.forbidden_, f, this), + error_ (x.error_, f, this), + any_ (x.any_, this->getDomDocument ()) + { + } + + Status1:: + Status1 (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f | ::LinphonePrivate::Xsd::XmlSchema::Flags::base, c), + dom_document_ (::xsd::cxx::xml::dom::create_document< char > ()), + displayed_ (this), + forbidden_ (this), + error_ (this), + any_ (this->getDomDocument ()) + { + if ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::base) == 0) + { + ::xsd::cxx::xml::dom::parser< char > p (e, true, false, false); + this->parse (p, f); + } + } + + void Status1:: + parse (::xsd::cxx::xml::dom::parser< char >& p, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + for (; p.more_content (); p.next_content (false)) + { + const ::xercesc::DOMElement& i (p.cur_element ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (i)); + + // displayed + // + if (n.name () == "displayed" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< DisplayedType > r ( + DisplayedTraits::create (i, f, this)); + + if (!this->displayed_) + { + this->displayed_.set (::std::move (r)); + continue; + } + } + + // forbidden + // + if (n.name () == "forbidden" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ForbiddenType > r ( + ForbiddenTraits::create (i, f, this)); + + if (!this->forbidden_) + { + this->forbidden_.set (::std::move (r)); + continue; + } + } + + // error + // + if (n.name () == "error" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ErrorType > r ( + ErrorTraits::create (i, f, this)); + + if (!this->error_) + { + this->error_.set (::std::move (r)); + continue; + } + } + + // any + // + if ((!n.namespace_ ().empty () && n.namespace_ () != "urn:ietf:params:xml:ns:imdn")) + { + ::xercesc::DOMElement* r ( + static_cast< ::xercesc::DOMElement* > ( + this->getDomDocument ().importNode ( + const_cast< ::xercesc::DOMElement* > (&i), true))); + this->any_.push_back (r); + continue; + } + + break; + } + } + + Status1* Status1:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Status1 (*this, f, c); + } + + Status1& Status1:: + operator= (const Status1& x) + { + if (this != &x) + { + static_cast< ::LinphonePrivate::Xsd::XmlSchema::Type& > (*this) = x; + this->displayed_ = x.displayed_; + this->forbidden_ = x.forbidden_; + this->error_ = x.error_; + this->any_ = x.any_; + } + + return *this; + } + + Status1:: + ~Status1 () + { + } + + // Status2 + // + + Status2:: + Status2 () + : ::LinphonePrivate::Xsd::XmlSchema::Type (), + dom_document_ (::xsd::cxx::xml::dom::create_document< char > ()), + processed_ (this), + stored_ (this), + forbidden_ (this), + error_ (this), + any_ (this->getDomDocument ()) + { + } + + Status2:: + Status2 (const Status2& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (x, f, c), + dom_document_ (::xsd::cxx::xml::dom::create_document< char > ()), + processed_ (x.processed_, f, this), + stored_ (x.stored_, f, this), + forbidden_ (x.forbidden_, f, this), + error_ (x.error_, f, this), + any_ (x.any_, this->getDomDocument ()) + { + } + + Status2:: + Status2 (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::Type (e, f | ::LinphonePrivate::Xsd::XmlSchema::Flags::base, c), + dom_document_ (::xsd::cxx::xml::dom::create_document< char > ()), + processed_ (this), + stored_ (this), + forbidden_ (this), + error_ (this), + any_ (this->getDomDocument ()) + { + if ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::base) == 0) + { + ::xsd::cxx::xml::dom::parser< char > p (e, true, false, false); + this->parse (p, f); + } + } + + void Status2:: + parse (::xsd::cxx::xml::dom::parser< char >& p, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + for (; p.more_content (); p.next_content (false)) + { + const ::xercesc::DOMElement& i (p.cur_element ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (i)); + + // processed + // + if (n.name () == "processed" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ProcessedType > r ( + ProcessedTraits::create (i, f, this)); + + if (!this->processed_) + { + this->processed_.set (::std::move (r)); + continue; + } + } + + // stored + // + if (n.name () == "stored" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< StoredType > r ( + StoredTraits::create (i, f, this)); + + if (!this->stored_) + { + this->stored_.set (::std::move (r)); + continue; + } + } + + // forbidden + // + if (n.name () == "forbidden" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ForbiddenType > r ( + ForbiddenTraits::create (i, f, this)); + + if (!this->forbidden_) + { + this->forbidden_.set (::std::move (r)); + continue; + } + } + + // error + // + if (n.name () == "error" && n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ErrorType > r ( + ErrorTraits::create (i, f, this)); + + if (!this->error_) + { + this->error_.set (::std::move (r)); + continue; + } + } + + // any + // + if ((!n.namespace_ ().empty () && n.namespace_ () != "urn:ietf:params:xml:ns:imdn")) + { + ::xercesc::DOMElement* r ( + static_cast< ::xercesc::DOMElement* > ( + this->getDomDocument ().importNode ( + const_cast< ::xercesc::DOMElement* > (&i), true))); + this->any_.push_back (r); + continue; + } + + break; + } + } + + Status2* Status2:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class Status2 (*this, f, c); + } + + Status2& Status2:: + operator= (const Status2& x) + { + if (this != &x) + { + static_cast< ::LinphonePrivate::Xsd::XmlSchema::Type& > (*this) = x; + this->processed_ = x.processed_; + this->stored_ = x.stored_; + this->forbidden_ = x.forbidden_; + this->error_ = x.error_; + this->any_ = x.any_; + } + + return *this; + } + + Status2:: + ~Status2 () + { + } + } + } +} + +#include + +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::std_ostream_plate< 0, char > + std_ostream_plate_init; +} + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + ::std::ostream& + operator<< (::std::ostream& o, const Imdn& i) + { + o << ::std::endl << "message-id: " << i.getMessageId (); + o << ::std::endl << "datetime: " << i.getDatetime (); + if (i.getRecipientUri ()) + { + o << ::std::endl << "recipient-uri: " << *i.getRecipientUri (); + } + + if (i.getOriginalRecipientUri ()) + { + o << ::std::endl << "original-recipient-uri: " << *i.getOriginalRecipientUri (); + } + + if (i.getSubject ()) + { + o << ::std::endl << "subject: " << *i.getSubject (); + } + + if (i.getDeliveryNotification ()) + { + o << ::std::endl << "delivery-notification: " << *i.getDeliveryNotification (); + } + + if (i.getDisplayNotification ()) + { + o << ::std::endl << "display-notification: " << *i.getDisplayNotification (); + } + + if (i.getProcessingNotification ()) + { + o << ::std::endl << "processing-notification: " << *i.getProcessingNotification (); + } + + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const DeliveryNotification& i) + { + o << ::std::endl << "status: " << i.getStatus (); + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Delivered&) + { + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Failed&) + { + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const DisplayNotification& i) + { + o << ::std::endl << "status: " << i.getStatus (); + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Displayed&) + { + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const ProcessingNotification& i) + { + o << ::std::endl << "status: " << i.getStatus (); + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Processed&) + { + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Stored&) + { + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Forbidden&) + { + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Error&) + { + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Status& i) + { + if (i.getDelivered ()) + { + o << ::std::endl << "delivered: " << *i.getDelivered (); + } + + if (i.getFailed ()) + { + o << ::std::endl << "failed: " << *i.getFailed (); + } + + if (i.getForbidden ()) + { + o << ::std::endl << "forbidden: " << *i.getForbidden (); + } + + if (i.getError ()) + { + o << ::std::endl << "error: " << *i.getError (); + } + + if (i.getReason ()) + { + o << ::std::endl << "reason: " << *i.getReason (); + } + + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Status1& i) + { + if (i.getDisplayed ()) + { + o << ::std::endl << "displayed: " << *i.getDisplayed (); + } + + if (i.getForbidden ()) + { + o << ::std::endl << "forbidden: " << *i.getForbidden (); + } + + if (i.getError ()) + { + o << ::std::endl << "error: " << *i.getError (); + } + + return o; + } + + ::std::ostream& + operator<< (::std::ostream& o, const Status2& i) + { + if (i.getProcessed ()) + { + o << ::std::endl << "processed: " << *i.getProcessed (); + } + + if (i.getStored ()) + { + o << ::std::endl << "stored: " << *i.getStored (); + } + + if (i.getForbidden ()) + { + o << ::std::endl << "forbidden: " << *i.getForbidden (); + } + + if (i.getError ()) + { + o << ::std::endl << "error: " << *i.getError (); + } + + return o; + } + } + } +} + +#include +#include +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (const ::std::string& u, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::tree::error_handler< char > h; + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + u, h, p, f)); + + h.throw_if_failed< ::xsd::cxx::tree::parsing< char > > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > ( + ::LinphonePrivate::Xsd::Imdn::parseImdn ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (const ::std::string& u, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + u, h, p, f)); + + if (!d.get ()) + throw ::xsd::cxx::tree::parsing< char > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > ( + ::LinphonePrivate::Xsd::Imdn::parseImdn ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (const ::std::string& u, + ::xercesc::DOMErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + u, h, p, f)); + + if (!d.get ()) + throw ::xsd::cxx::tree::parsing< char > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > ( + ::LinphonePrivate::Xsd::Imdn::parseImdn ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::xml::sax::std_input_source isrc (is); + return ::LinphonePrivate::Xsd::Imdn::parseImdn (isrc, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::xml::sax::std_input_source isrc (is); + return ::LinphonePrivate::Xsd::Imdn::parseImdn (isrc, h, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + ::xercesc::DOMErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::sax::std_input_source isrc (is); + return ::LinphonePrivate::Xsd::Imdn::parseImdn (isrc, h, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + const ::std::string& sid, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::xml::sax::std_input_source isrc (is, sid); + return ::LinphonePrivate::Xsd::Imdn::parseImdn (isrc, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + const ::std::string& sid, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::xml::sax::std_input_source isrc (is, sid); + return ::LinphonePrivate::Xsd::Imdn::parseImdn (isrc, h, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + const ::std::string& sid, + ::xercesc::DOMErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::sax::std_input_source isrc (is, sid); + return ::LinphonePrivate::Xsd::Imdn::parseImdn (isrc, h, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::xercesc::InputSource& i, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::tree::error_handler< char > h; + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + i, h, p, f)); + + h.throw_if_failed< ::xsd::cxx::tree::parsing< char > > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > ( + ::LinphonePrivate::Xsd::Imdn::parseImdn ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::xercesc::InputSource& i, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + i, h, p, f)); + + if (!d.get ()) + throw ::xsd::cxx::tree::parsing< char > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > ( + ::LinphonePrivate::Xsd::Imdn::parseImdn ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::xercesc::InputSource& i, + ::xercesc::DOMErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + i, h, p, f)); + + if (!d.get ()) + throw ::xsd::cxx::tree::parsing< char > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > ( + ::LinphonePrivate::Xsd::Imdn::parseImdn ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (const ::xercesc::DOMDocument& doc, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + if (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + static_cast< ::xercesc::DOMDocument* > (doc.cloneNode (true))); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > ( + ::LinphonePrivate::Xsd::Imdn::parseImdn ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + const ::xercesc::DOMElement& e (*doc.getDocumentElement ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (e)); + + if (n.name () == "imdn" && + n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > r ( + ::xsd::cxx::tree::traits< ::LinphonePrivate::Xsd::Imdn::Imdn, char >::create ( + e, f, 0)); + return r; + } + + throw ::xsd::cxx::tree::unexpected_element < char > ( + n.name (), + n.namespace_ (), + "imdn", + "urn:ietf:params:xml:ns:imdn"); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties&) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > c ( + ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) && + !(f & ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom)) + ? static_cast< ::xercesc::DOMDocument* > (d->cloneNode (true)) + : 0); + + ::xercesc::DOMDocument& doc (c.get () ? *c : *d); + const ::xercesc::DOMElement& e (*doc.getDocumentElement ()); + + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (e)); + + if (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) + doc.setUserData (::LinphonePrivate::Xsd::XmlSchema::dom::treeNodeKey, + (c.get () ? &c : &d), + 0); + + if (n.name () == "imdn" && + n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > r ( + ::xsd::cxx::tree::traits< ::LinphonePrivate::Xsd::Imdn::Imdn, char >::create ( + e, f, 0)); + return r; + } + + throw ::xsd::cxx::tree::unexpected_element < char > ( + n.name (), + n.namespace_ (), + "imdn", + "urn:ietf:params:xml:ns:imdn"); + } + } + } +} + +#include +#include +#include + +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_serializer_plate< 0, char > + type_serializer_plate_init; +} + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + void + serializeImdn (::std::ostream& o, + const ::LinphonePrivate::Xsd::Imdn::Imdn& s, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0); + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::Imdn::serializeImdn (s, m, f)); + + ::xsd::cxx::tree::error_handler< char > h; + + ::xsd::cxx::xml::dom::ostream_format_target t (o); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + h.throw_if_failed< ::xsd::cxx::tree::serialization< char > > (); + } + } + + void + serializeImdn (::std::ostream& o, + const ::LinphonePrivate::Xsd::Imdn::Imdn& s, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0); + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::Imdn::serializeImdn (s, m, f)); + ::xsd::cxx::xml::dom::ostream_format_target t (o); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + throw ::xsd::cxx::tree::serialization< char > (); + } + } + + void + serializeImdn (::std::ostream& o, + const ::LinphonePrivate::Xsd::Imdn::Imdn& s, + ::xercesc::DOMErrorHandler& h, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::Imdn::serializeImdn (s, m, f)); + ::xsd::cxx::xml::dom::ostream_format_target t (o); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + throw ::xsd::cxx::tree::serialization< char > (); + } + } + + void + serializeImdn (::xercesc::XMLFormatTarget& t, + const ::LinphonePrivate::Xsd::Imdn::Imdn& s, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::Imdn::serializeImdn (s, m, f)); + + ::xsd::cxx::tree::error_handler< char > h; + + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + h.throw_if_failed< ::xsd::cxx::tree::serialization< char > > (); + } + } + + void + serializeImdn (::xercesc::XMLFormatTarget& t, + const ::LinphonePrivate::Xsd::Imdn::Imdn& s, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::Imdn::serializeImdn (s, m, f)); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + throw ::xsd::cxx::tree::serialization< char > (); + } + } + + void + serializeImdn (::xercesc::XMLFormatTarget& t, + const ::LinphonePrivate::Xsd::Imdn::Imdn& s, + ::xercesc::DOMErrorHandler& h, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::Imdn::serializeImdn (s, m, f)); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + throw ::xsd::cxx::tree::serialization< char > (); + } + } + + void + serializeImdn (::xercesc::DOMDocument& d, + const ::LinphonePrivate::Xsd::Imdn::Imdn& s, + ::LinphonePrivate::Xsd::XmlSchema::Flags) + { + ::xercesc::DOMElement& e (*d.getDocumentElement ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (e)); + + if (n.name () == "imdn" && + n.namespace_ () == "urn:ietf:params:xml:ns:imdn") + { + e << s; + } + else + { + throw ::xsd::cxx::tree::unexpected_element < char > ( + n.name (), + n.namespace_ (), + "imdn", + "urn:ietf:params:xml:ns:imdn"); + } + } + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > + serializeImdn (const ::LinphonePrivate::Xsd::Imdn::Imdn& s, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::serialize< char > ( + "imdn", + "urn:ietf:params:xml:ns:imdn", + m, f)); + + ::LinphonePrivate::Xsd::Imdn::serializeImdn (*d, s, f); + return d; + } + + void + operator<< (::xercesc::DOMElement& e, const Imdn& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + + // message-id + // + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "message-id", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << i.getMessageId (); + } + + // datetime + // + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "datetime", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << i.getDatetime (); + } + + // recipient-uri + // + if (i.getRecipientUri ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "recipient-uri", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getRecipientUri (); + } + + // original-recipient-uri + // + if (i.getOriginalRecipientUri ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "original-recipient-uri", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getOriginalRecipientUri (); + } + + // subject + // + if (i.getSubject ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "subject", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getSubject (); + } + + // delivery-notification + // + if (i.getDeliveryNotification ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "delivery-notification", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getDeliveryNotification (); + } + + // display-notification + // + if (i.getDisplayNotification ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "display-notification", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getDisplayNotification (); + } + + // processing-notification + // + if (i.getProcessingNotification ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "processing-notification", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getProcessingNotification (); + } + + // any + // + for (Imdn::AnyConstIterator + b (i.getAny ().begin ()), n (i.getAny ().end ()); + b != n; ++b) + { + e.appendChild ( + e.getOwnerDocument ()->importNode ( + const_cast< ::xercesc::DOMElement* > (&(*b)), true)); + } + } + + void + operator<< (::xercesc::DOMElement& e, const DeliveryNotification& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + + // status + // + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "status", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << i.getStatus (); + } + } + + void + operator<< (::xercesc::DOMElement& e, const Delivered& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + } + + void + operator<< (::xercesc::DOMAttr&, const Delivered&) + { + } + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Delivered&) + { + } + + void + operator<< (::xercesc::DOMElement& e, const Failed& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + } + + void + operator<< (::xercesc::DOMAttr&, const Failed&) + { + } + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Failed&) + { + } + + void + operator<< (::xercesc::DOMElement& e, const DisplayNotification& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + + // status + // + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "status", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << i.getStatus (); + } + } + + void + operator<< (::xercesc::DOMElement& e, const Displayed& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + } + + void + operator<< (::xercesc::DOMAttr&, const Displayed&) + { + } + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Displayed&) + { + } + + void + operator<< (::xercesc::DOMElement& e, const ProcessingNotification& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + + // status + // + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "status", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << i.getStatus (); + } + } + + void + operator<< (::xercesc::DOMElement& e, const Processed& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + } + + void + operator<< (::xercesc::DOMAttr&, const Processed&) + { + } + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Processed&) + { + } + + void + operator<< (::xercesc::DOMElement& e, const Stored& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + } + + void + operator<< (::xercesc::DOMAttr&, const Stored&) + { + } + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Stored&) + { + } + + void + operator<< (::xercesc::DOMElement& e, const Forbidden& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + } + + void + operator<< (::xercesc::DOMAttr&, const Forbidden&) + { + } + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Forbidden&) + { + } + + void + operator<< (::xercesc::DOMElement& e, const Error& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + } + + void + operator<< (::xercesc::DOMAttr&, const Error&) + { + } + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Error&) + { + } + + void + operator<< (::xercesc::DOMElement& e, const Status& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + + // delivered + // + if (i.getDelivered ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "delivered", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getDelivered (); + } + + // failed + // + if (i.getFailed ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "failed", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getFailed (); + } + + // forbidden + // + if (i.getForbidden ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "forbidden", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getForbidden (); + } + + // error + // + if (i.getError ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "error", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getError (); + } + + // reason + // + if (i.getReason ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "reason", + "http://www.linphone.org/xsds/imdn.xsd", + e)); + + s << *i.getReason (); + } + } + + void + operator<< (::xercesc::DOMElement& e, const Status1& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + + // displayed + // + if (i.getDisplayed ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "displayed", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getDisplayed (); + } + + // forbidden + // + if (i.getForbidden ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "forbidden", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getForbidden (); + } + + // error + // + if (i.getError ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "error", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getError (); + } + + // any + // + for (Status1::AnyConstIterator + b (i.getAny ().begin ()), n (i.getAny ().end ()); + b != n; ++b) + { + e.appendChild ( + e.getOwnerDocument ()->importNode ( + const_cast< ::xercesc::DOMElement* > (&(*b)), true)); + } + } + + void + operator<< (::xercesc::DOMElement& e, const Status2& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::Type& > (i); + + // processed + // + if (i.getProcessed ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "processed", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getProcessed (); + } + + // stored + // + if (i.getStored ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "stored", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getStored (); + } + + // forbidden + // + if (i.getForbidden ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "forbidden", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getForbidden (); + } + + // error + // + if (i.getError ()) + { + ::xercesc::DOMElement& s ( + ::xsd::cxx::xml::dom::create_element ( + "error", + "urn:ietf:params:xml:ns:imdn", + e)); + + s << *i.getError (); + } + + // any + // + for (Status2::AnyConstIterator + b (i.getAny ().begin ()), n (i.getAny ().end ()); + b != n; ++b) + { + e.appendChild ( + e.getOwnerDocument ()->importNode ( + const_cast< ::xercesc::DOMElement* > (&(*b)), true)); + } + } + } + } +} + +#include + +// Begin epilogue. +// +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif +#if __clang__ || __GNUC__ >= 4 + #pragma GCC diagnostic pop +#endif +// +// End epilogue. + diff --git a/src/xml/imdn.h b/src/xml/imdn.h new file mode 100644 index 000000000..687f80533 --- /dev/null +++ b/src/xml/imdn.h @@ -0,0 +1,1730 @@ +// Copyright (c) 2005-2014 Code Synthesis Tools CC +// +// This program was generated by CodeSynthesis XSD, an XML Schema to +// C++ data binding compiler. +// +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License version 2 as +// published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the Free Software +// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +// +// In addition, as a special exception, Code Synthesis Tools CC gives +// permission to link this program with the Xerces-C++ library (or with +// modified versions of Xerces-C++ that use the same license as Xerces-C++), +// and distribute linked combinations including the two. You must obey +// the GNU General Public License version 2 in all respects for all of +// the code used other than Xerces-C++. If you modify this copy of the +// program, you may extend this exception to your version of the program, +// but you are not obligated to do so. If you do not wish to do so, delete +// this exception statement from your version. +// +// Furthermore, Code Synthesis Tools CC makes a special exception for +// the Free/Libre and Open Source Software (FLOSS) which is described +// in the accompanying FLOSSE file. +// + +#ifndef XML_IMDN_H +#define XML_IMDN_H + +#ifndef XSD_CXX11 +#define XSD_CXX11 +#endif + +#ifndef XSD_USE_CHAR +#define XSD_USE_CHAR +#endif + +#ifndef XSD_CXX_TREE_USE_CHAR +#define XSD_CXX_TREE_USE_CHAR +#endif + +// Begin prologue. +// +#if __clang__ || __GNUC__ >= 4 + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wfloat-equal" +#endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" +#endif +// +// End prologue. + +#include + +#if (XSD_INT_VERSION != 4000000L) +#error XSD runtime version mismatch +#endif + +#include + +#include + +#include +#include +#include + +#include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace XmlSchema + { + // anyType and anySimpleType. + // + typedef ::xsd::cxx::tree::type Type; + typedef ::xsd::cxx::tree::simple_type< char, Type > SimpleType; + typedef ::xsd::cxx::tree::type Container; + + // 8-bit + // + typedef signed char Byte; + typedef unsigned char UnsignedByte; + + // 16-bit + // + typedef short Short; + typedef unsigned short UnsignedShort; + + // 32-bit + // + typedef int Int; + typedef unsigned int UnsignedInt; + + // 64-bit + // + typedef long long Long; + typedef unsigned long long UnsignedLong; + + // Supposed to be arbitrary-length integral types. + // + typedef long long Integer; + typedef long long NonPositiveInteger; + typedef unsigned long long NonNegativeInteger; + typedef unsigned long long PositiveInteger; + typedef long long NegativeInteger; + + // Boolean. + // + typedef bool Boolean; + + // Floating-point types. + // + typedef float Float; + typedef double Double; + typedef double Decimal; + + // String types. + // + typedef ::xsd::cxx::tree::string< char, SimpleType > String; + typedef ::xsd::cxx::tree::normalized_string< char, String > NormalizedString; + typedef ::xsd::cxx::tree::token< char, NormalizedString > Token; + typedef ::xsd::cxx::tree::name< char, Token > Name; + typedef ::xsd::cxx::tree::nmtoken< char, Token > Nmtoken; + typedef ::xsd::cxx::tree::nmtokens< char, SimpleType, Nmtoken > Nmtokens; + typedef ::xsd::cxx::tree::ncname< char, Name > Ncname; + typedef ::xsd::cxx::tree::language< char, Token > Language; + + // ID/IDREF. + // + typedef ::xsd::cxx::tree::id< char, Ncname > Id; + typedef ::xsd::cxx::tree::idref< char, Ncname, Type > Idref; + typedef ::xsd::cxx::tree::idrefs< char, SimpleType, Idref > Idrefs; + + // URI. + // + typedef ::xsd::cxx::tree::uri< char, SimpleType > Uri; + + // Qualified name. + // + typedef ::xsd::cxx::tree::qname< char, SimpleType, Uri, Ncname > Qname; + + // Binary. + // + typedef ::xsd::cxx::tree::buffer< char > Buffer; + typedef ::xsd::cxx::tree::base64_binary< char, SimpleType > Base64Binary; + typedef ::xsd::cxx::tree::hex_binary< char, SimpleType > HexBinary; + + // Date/time. + // + typedef ::xsd::cxx::tree::time_zone TimeZone; + typedef ::xsd::cxx::tree::date< char, SimpleType > Date; + typedef ::xsd::cxx::tree::date_time< char, SimpleType > DateTime; + typedef ::xsd::cxx::tree::duration< char, SimpleType > Duration; + typedef ::xsd::cxx::tree::gday< char, SimpleType > Gday; + typedef ::xsd::cxx::tree::gmonth< char, SimpleType > Gmonth; + typedef ::xsd::cxx::tree::gmonth_day< char, SimpleType > GmonthDay; + typedef ::xsd::cxx::tree::gyear< char, SimpleType > Gyear; + typedef ::xsd::cxx::tree::gyear_month< char, SimpleType > GyearMonth; + typedef ::xsd::cxx::tree::time< char, SimpleType > Time; + + // Entity. + // + typedef ::xsd::cxx::tree::entity< char, Ncname > Entity; + typedef ::xsd::cxx::tree::entities< char, SimpleType, Entity > Entities; + + typedef ::xsd::cxx::tree::content_order ContentOrder; + // Namespace information and list stream. Used in + // serialization functions. + // + typedef ::xsd::cxx::xml::dom::namespace_info< char > NamespaceInfo; + typedef ::xsd::cxx::xml::dom::namespace_infomap< char > NamespaceInfomap; + typedef ::xsd::cxx::tree::list_stream< char > ListStream; + typedef ::xsd::cxx::tree::as_double< Double > AsDouble; + typedef ::xsd::cxx::tree::as_decimal< Decimal > AsDecimal; + typedef ::xsd::cxx::tree::facet Facet; + + // Flags and properties. + // + typedef ::xsd::cxx::tree::flags Flags; + typedef ::xsd::cxx::tree::properties< char > Properties; + + // Parsing/serialization diagnostics. + // + typedef ::xsd::cxx::tree::severity Severity; + typedef ::xsd::cxx::tree::error< char > Error; + typedef ::xsd::cxx::tree::diagnostics< char > Diagnostics; + + // Exceptions. + // + typedef ::xsd::cxx::tree::exception< char > Exception; + typedef ::xsd::cxx::tree::bounds< char > Bounds; + typedef ::xsd::cxx::tree::duplicate_id< char > DuplicateId; + typedef ::xsd::cxx::tree::parsing< char > Parsing; + typedef ::xsd::cxx::tree::expected_element< char > ExpectedElement; + typedef ::xsd::cxx::tree::unexpected_element< char > UnexpectedElement; + typedef ::xsd::cxx::tree::expected_attribute< char > ExpectedAttribute; + typedef ::xsd::cxx::tree::unexpected_enumerator< char > UnexpectedEnumerator; + typedef ::xsd::cxx::tree::expected_text_content< char > ExpectedTextContent; + typedef ::xsd::cxx::tree::no_prefix_mapping< char > NoPrefixMapping; + typedef ::xsd::cxx::tree::no_type_info< char > NoTypeInfo; + typedef ::xsd::cxx::tree::not_derived< char > NotDerived; + typedef ::xsd::cxx::tree::serialization< char > Serialization; + + // Error handler callback interface. + // + typedef ::xsd::cxx::xml::error_handler< char > ErrorHandler; + + // DOM interaction. + // + namespace dom + { + // Automatic pointer for DOMDocument. + // + using ::xsd::cxx::xml::dom::unique_ptr; + +#ifndef XSD_CXX_TREE_TREE_NODE_KEY__LINPHONEPRIVATE__XSD__XMLSCHEMA +#define XSD_CXX_TREE_TREE_NODE_KEY__LINPHONEPRIVATE__XSD__XMLSCHEMA + // DOM user data key for back pointers to tree nodes. + // + const XMLCh* const treeNodeKey = ::xsd::cxx::tree::user_data_keys::node; +#endif + } + } + } +} + +// Forward declarations. +// +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + class Imdn; + class DeliveryNotification; + class Delivered; + class Failed; + class DisplayNotification; + class Displayed; + class ProcessingNotification; + class Processed; + class Stored; + class Forbidden; + class Error; + class Status; + class Status1; + class Status2; + } + } +} + + +#include // ::std::unique_ptr +#include // std::numeric_limits +#include // std::binary_search +#include // std::move + +#include + +#include +#include +#include +#include + +#include + +#include + +#include "linphone-imdn.h" + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + class Imdn: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // message-id + // + typedef ::LinphonePrivate::Xsd::XmlSchema::Token MessageIdType; + typedef ::xsd::cxx::tree::traits< MessageIdType, char > MessageIdTraits; + + const MessageIdType& + getMessageId () const; + + MessageIdType& + getMessageId (); + + void + setMessageId (const MessageIdType& x); + + void + setMessageId (::std::unique_ptr< MessageIdType > p); + + ::std::unique_ptr< MessageIdType > + setDetachMessage_id (); + + // datetime + // + typedef ::LinphonePrivate::Xsd::XmlSchema::String DatetimeType; + typedef ::xsd::cxx::tree::traits< DatetimeType, char > DatetimeTraits; + + const DatetimeType& + getDatetime () const; + + DatetimeType& + getDatetime (); + + void + setDatetime (const DatetimeType& x); + + void + setDatetime (::std::unique_ptr< DatetimeType > p); + + ::std::unique_ptr< DatetimeType > + setDetachDatetime (); + + // recipient-uri + // + typedef ::LinphonePrivate::Xsd::XmlSchema::Uri RecipientUriType; + typedef ::xsd::cxx::tree::optional< RecipientUriType > RecipientUriOptional; + typedef ::xsd::cxx::tree::traits< RecipientUriType, char > RecipientUriTraits; + + const RecipientUriOptional& + getRecipientUri () const; + + RecipientUriOptional& + getRecipientUri (); + + void + setRecipientUri (const RecipientUriType& x); + + void + setRecipientUri (const RecipientUriOptional& x); + + void + setRecipientUri (::std::unique_ptr< RecipientUriType > p); + + // original-recipient-uri + // + typedef ::LinphonePrivate::Xsd::XmlSchema::Uri OriginalRecipientUriType; + typedef ::xsd::cxx::tree::optional< OriginalRecipientUriType > OriginalRecipientUriOptional; + typedef ::xsd::cxx::tree::traits< OriginalRecipientUriType, char > OriginalRecipientUriTraits; + + const OriginalRecipientUriOptional& + getOriginalRecipientUri () const; + + OriginalRecipientUriOptional& + getOriginalRecipientUri (); + + void + setOriginalRecipientUri (const OriginalRecipientUriType& x); + + void + setOriginalRecipientUri (const OriginalRecipientUriOptional& x); + + void + setOriginalRecipientUri (::std::unique_ptr< OriginalRecipientUriType > p); + + // subject + // + typedef ::LinphonePrivate::Xsd::XmlSchema::String SubjectType; + typedef ::xsd::cxx::tree::optional< SubjectType > SubjectOptional; + typedef ::xsd::cxx::tree::traits< SubjectType, char > SubjectTraits; + + const SubjectOptional& + getSubject () const; + + SubjectOptional& + getSubject (); + + void + setSubject (const SubjectType& x); + + void + setSubject (const SubjectOptional& x); + + void + setSubject (::std::unique_ptr< SubjectType > p); + + // delivery-notification + // + typedef ::LinphonePrivate::Xsd::Imdn::DeliveryNotification DeliveryNotificationType; + typedef ::xsd::cxx::tree::optional< DeliveryNotificationType > DeliveryNotificationOptional; + typedef ::xsd::cxx::tree::traits< DeliveryNotificationType, char > DeliveryNotificationTraits; + + const DeliveryNotificationOptional& + getDeliveryNotification () const; + + DeliveryNotificationOptional& + getDeliveryNotification (); + + void + setDeliveryNotification (const DeliveryNotificationType& x); + + void + setDeliveryNotification (const DeliveryNotificationOptional& x); + + void + setDeliveryNotification (::std::unique_ptr< DeliveryNotificationType > p); + + // display-notification + // + typedef ::LinphonePrivate::Xsd::Imdn::DisplayNotification DisplayNotificationType; + typedef ::xsd::cxx::tree::optional< DisplayNotificationType > DisplayNotificationOptional; + typedef ::xsd::cxx::tree::traits< DisplayNotificationType, char > DisplayNotificationTraits; + + const DisplayNotificationOptional& + getDisplayNotification () const; + + DisplayNotificationOptional& + getDisplayNotification (); + + void + setDisplayNotification (const DisplayNotificationType& x); + + void + setDisplayNotification (const DisplayNotificationOptional& x); + + void + setDisplayNotification (::std::unique_ptr< DisplayNotificationType > p); + + // processing-notification + // + typedef ::LinphonePrivate::Xsd::Imdn::ProcessingNotification ProcessingNotificationType; + typedef ::xsd::cxx::tree::optional< ProcessingNotificationType > ProcessingNotificationOptional; + typedef ::xsd::cxx::tree::traits< ProcessingNotificationType, char > ProcessingNotificationTraits; + + const ProcessingNotificationOptional& + getProcessingNotification () const; + + ProcessingNotificationOptional& + getProcessingNotification (); + + void + setProcessingNotification (const ProcessingNotificationType& x); + + void + setProcessingNotification (const ProcessingNotificationOptional& x); + + void + setProcessingNotification (::std::unique_ptr< ProcessingNotificationType > p); + + // any + // + typedef ::xsd::cxx::tree::element_sequence AnySequence; + typedef AnySequence::iterator AnyIterator; + typedef AnySequence::const_iterator AnyConstIterator; + + const AnySequence& + getAny () const; + + AnySequence& + getAny (); + + void + setAny (const AnySequence& s); + + // DOMDocument for wildcard content. + // + const ::xercesc::DOMDocument& + getDomDocument () const; + + ::xercesc::DOMDocument& + getDomDocument (); + + // Constructors. + // + Imdn (const MessageIdType&, + const DatetimeType&); + + Imdn (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Imdn (const Imdn& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Imdn* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + Imdn& + operator= (const Imdn& x); + + virtual + ~Imdn (); + + // Implementation. + // + protected: + void + parse (::xsd::cxx::xml::dom::parser< char >&, + ::LinphonePrivate::Xsd::XmlSchema::Flags); + + protected: + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > dom_document_; + + ::xsd::cxx::tree::one< MessageIdType > message_id_; + ::xsd::cxx::tree::one< DatetimeType > datetime_; + RecipientUriOptional recipient_uri_; + OriginalRecipientUriOptional original_recipient_uri_; + SubjectOptional subject_; + DeliveryNotificationOptional delivery_notification_; + DisplayNotificationOptional display_notification_; + ProcessingNotificationOptional processing_notification_; + AnySequence any_; + }; + + class DeliveryNotification: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // status + // + typedef ::LinphonePrivate::Xsd::Imdn::Status StatusType; + typedef ::xsd::cxx::tree::traits< StatusType, char > StatusTraits; + + const StatusType& + getStatus () const; + + StatusType& + getStatus (); + + void + setStatus (const StatusType& x); + + void + setStatus (::std::unique_ptr< StatusType > p); + + ::std::unique_ptr< StatusType > + setDetachStatus (); + + // Constructors. + // + DeliveryNotification (const StatusType&); + + DeliveryNotification (::std::unique_ptr< StatusType >); + + DeliveryNotification (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + DeliveryNotification (const DeliveryNotification& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual DeliveryNotification* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + DeliveryNotification& + operator= (const DeliveryNotification& x); + + virtual + ~DeliveryNotification (); + + // Implementation. + // + protected: + void + parse (::xsd::cxx::xml::dom::parser< char >&, + ::LinphonePrivate::Xsd::XmlSchema::Flags); + + protected: + ::xsd::cxx::tree::one< StatusType > status_; + }; + + class Delivered: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // Constructors. + // + Delivered (); + + Delivered (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Delivered (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Delivered (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Delivered (const Delivered& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Delivered* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + virtual + ~Delivered (); + }; + + class Failed: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // Constructors. + // + Failed (); + + Failed (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Failed (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Failed (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Failed (const Failed& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Failed* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + virtual + ~Failed (); + }; + + class DisplayNotification: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // status + // + typedef ::LinphonePrivate::Xsd::Imdn::Status1 StatusType; + typedef ::xsd::cxx::tree::traits< StatusType, char > StatusTraits; + + const StatusType& + getStatus () const; + + StatusType& + getStatus (); + + void + setStatus (const StatusType& x); + + void + setStatus (::std::unique_ptr< StatusType > p); + + ::std::unique_ptr< StatusType > + setDetachStatus (); + + // Constructors. + // + DisplayNotification (const StatusType&); + + DisplayNotification (::std::unique_ptr< StatusType >); + + DisplayNotification (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + DisplayNotification (const DisplayNotification& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual DisplayNotification* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + DisplayNotification& + operator= (const DisplayNotification& x); + + virtual + ~DisplayNotification (); + + // Implementation. + // + protected: + void + parse (::xsd::cxx::xml::dom::parser< char >&, + ::LinphonePrivate::Xsd::XmlSchema::Flags); + + protected: + ::xsd::cxx::tree::one< StatusType > status_; + }; + + class Displayed: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // Constructors. + // + Displayed (); + + Displayed (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Displayed (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Displayed (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Displayed (const Displayed& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Displayed* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + virtual + ~Displayed (); + }; + + class ProcessingNotification: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // status + // + typedef ::LinphonePrivate::Xsd::Imdn::Status2 StatusType; + typedef ::xsd::cxx::tree::traits< StatusType, char > StatusTraits; + + const StatusType& + getStatus () const; + + StatusType& + getStatus (); + + void + setStatus (const StatusType& x); + + void + setStatus (::std::unique_ptr< StatusType > p); + + ::std::unique_ptr< StatusType > + setDetachStatus (); + + // Constructors. + // + ProcessingNotification (const StatusType&); + + ProcessingNotification (::std::unique_ptr< StatusType >); + + ProcessingNotification (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + ProcessingNotification (const ProcessingNotification& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual ProcessingNotification* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + ProcessingNotification& + operator= (const ProcessingNotification& x); + + virtual + ~ProcessingNotification (); + + // Implementation. + // + protected: + void + parse (::xsd::cxx::xml::dom::parser< char >&, + ::LinphonePrivate::Xsd::XmlSchema::Flags); + + protected: + ::xsd::cxx::tree::one< StatusType > status_; + }; + + class Processed: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // Constructors. + // + Processed (); + + Processed (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Processed (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Processed (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Processed (const Processed& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Processed* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + virtual + ~Processed (); + }; + + class Stored: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // Constructors. + // + Stored (); + + Stored (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Stored (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Stored (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Stored (const Stored& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Stored* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + virtual + ~Stored (); + }; + + class Forbidden: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // Constructors. + // + Forbidden (); + + Forbidden (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Forbidden (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Forbidden (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Forbidden (const Forbidden& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Forbidden* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + virtual + ~Forbidden (); + }; + + class Error: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // Constructors. + // + Error (); + + Error (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Error (const ::xercesc::DOMAttr& a, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Error (const ::std::string& s, + const ::xercesc::DOMElement* e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Error (const Error& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Error* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + virtual + ~Error (); + }; + + class Status: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // delivered + // + typedef ::LinphonePrivate::Xsd::Imdn::Delivered DeliveredType; + typedef ::xsd::cxx::tree::optional< DeliveredType > DeliveredOptional; + typedef ::xsd::cxx::tree::traits< DeliveredType, char > DeliveredTraits; + + const DeliveredOptional& + getDelivered () const; + + DeliveredOptional& + getDelivered (); + + void + setDelivered (const DeliveredType& x); + + void + setDelivered (const DeliveredOptional& x); + + void + setDelivered (::std::unique_ptr< DeliveredType > p); + + // failed + // + typedef ::LinphonePrivate::Xsd::Imdn::Failed FailedType; + typedef ::xsd::cxx::tree::optional< FailedType > FailedOptional; + typedef ::xsd::cxx::tree::traits< FailedType, char > FailedTraits; + + const FailedOptional& + getFailed () const; + + FailedOptional& + getFailed (); + + void + setFailed (const FailedType& x); + + void + setFailed (const FailedOptional& x); + + void + setFailed (::std::unique_ptr< FailedType > p); + + // forbidden + // + typedef ::LinphonePrivate::Xsd::Imdn::Forbidden ForbiddenType; + typedef ::xsd::cxx::tree::optional< ForbiddenType > ForbiddenOptional; + typedef ::xsd::cxx::tree::traits< ForbiddenType, char > ForbiddenTraits; + + const ForbiddenOptional& + getForbidden () const; + + ForbiddenOptional& + getForbidden (); + + void + setForbidden (const ForbiddenType& x); + + void + setForbidden (const ForbiddenOptional& x); + + void + setForbidden (::std::unique_ptr< ForbiddenType > p); + + // error + // + typedef ::LinphonePrivate::Xsd::Imdn::Error ErrorType; + typedef ::xsd::cxx::tree::optional< ErrorType > ErrorOptional; + typedef ::xsd::cxx::tree::traits< ErrorType, char > ErrorTraits; + + const ErrorOptional& + getError () const; + + ErrorOptional& + getError (); + + void + setError (const ErrorType& x); + + void + setError (const ErrorOptional& x); + + void + setError (::std::unique_ptr< ErrorType > p); + + // reason + // + typedef ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason ReasonType; + typedef ::xsd::cxx::tree::optional< ReasonType > ReasonOptional; + typedef ::xsd::cxx::tree::traits< ReasonType, char > ReasonTraits; + + const ReasonOptional& + getReason () const; + + ReasonOptional& + getReason (); + + void + setReason (const ReasonType& x); + + void + setReason (const ReasonOptional& x); + + void + setReason (::std::unique_ptr< ReasonType > p); + + // Constructors. + // + Status (); + + Status (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Status (const Status& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Status* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + Status& + operator= (const Status& x); + + virtual + ~Status (); + + // Implementation. + // + protected: + void + parse (::xsd::cxx::xml::dom::parser< char >&, + ::LinphonePrivate::Xsd::XmlSchema::Flags); + + protected: + DeliveredOptional delivered_; + FailedOptional failed_; + ForbiddenOptional forbidden_; + ErrorOptional error_; + ReasonOptional reason_; + }; + + class Status1: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // displayed + // + typedef ::LinphonePrivate::Xsd::Imdn::Displayed DisplayedType; + typedef ::xsd::cxx::tree::optional< DisplayedType > DisplayedOptional; + typedef ::xsd::cxx::tree::traits< DisplayedType, char > DisplayedTraits; + + const DisplayedOptional& + getDisplayed () const; + + DisplayedOptional& + getDisplayed (); + + void + setDisplayed (const DisplayedType& x); + + void + setDisplayed (const DisplayedOptional& x); + + void + setDisplayed (::std::unique_ptr< DisplayedType > p); + + // forbidden + // + typedef ::LinphonePrivate::Xsd::Imdn::Forbidden ForbiddenType; + typedef ::xsd::cxx::tree::optional< ForbiddenType > ForbiddenOptional; + typedef ::xsd::cxx::tree::traits< ForbiddenType, char > ForbiddenTraits; + + const ForbiddenOptional& + getForbidden () const; + + ForbiddenOptional& + getForbidden (); + + void + setForbidden (const ForbiddenType& x); + + void + setForbidden (const ForbiddenOptional& x); + + void + setForbidden (::std::unique_ptr< ForbiddenType > p); + + // error + // + typedef ::LinphonePrivate::Xsd::Imdn::Error ErrorType; + typedef ::xsd::cxx::tree::optional< ErrorType > ErrorOptional; + typedef ::xsd::cxx::tree::traits< ErrorType, char > ErrorTraits; + + const ErrorOptional& + getError () const; + + ErrorOptional& + getError (); + + void + setError (const ErrorType& x); + + void + setError (const ErrorOptional& x); + + void + setError (::std::unique_ptr< ErrorType > p); + + // any + // + typedef ::xsd::cxx::tree::element_sequence AnySequence; + typedef AnySequence::iterator AnyIterator; + typedef AnySequence::const_iterator AnyConstIterator; + + const AnySequence& + getAny () const; + + AnySequence& + getAny (); + + void + setAny (const AnySequence& s); + + // DOMDocument for wildcard content. + // + const ::xercesc::DOMDocument& + getDomDocument () const; + + ::xercesc::DOMDocument& + getDomDocument (); + + // Constructors. + // + Status1 (); + + Status1 (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Status1 (const Status1& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Status1* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + Status1& + operator= (const Status1& x); + + virtual + ~Status1 (); + + // Implementation. + // + protected: + void + parse (::xsd::cxx::xml::dom::parser< char >&, + ::LinphonePrivate::Xsd::XmlSchema::Flags); + + protected: + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > dom_document_; + + DisplayedOptional displayed_; + ForbiddenOptional forbidden_; + ErrorOptional error_; + AnySequence any_; + }; + + class Status2: public ::LinphonePrivate::Xsd::XmlSchema::Type + { + public: + // processed + // + typedef ::LinphonePrivate::Xsd::Imdn::Processed ProcessedType; + typedef ::xsd::cxx::tree::optional< ProcessedType > ProcessedOptional; + typedef ::xsd::cxx::tree::traits< ProcessedType, char > ProcessedTraits; + + const ProcessedOptional& + getProcessed () const; + + ProcessedOptional& + getProcessed (); + + void + setProcessed (const ProcessedType& x); + + void + setProcessed (const ProcessedOptional& x); + + void + setProcessed (::std::unique_ptr< ProcessedType > p); + + // stored + // + typedef ::LinphonePrivate::Xsd::Imdn::Stored StoredType; + typedef ::xsd::cxx::tree::optional< StoredType > StoredOptional; + typedef ::xsd::cxx::tree::traits< StoredType, char > StoredTraits; + + const StoredOptional& + getStored () const; + + StoredOptional& + getStored (); + + void + setStored (const StoredType& x); + + void + setStored (const StoredOptional& x); + + void + setStored (::std::unique_ptr< StoredType > p); + + // forbidden + // + typedef ::LinphonePrivate::Xsd::Imdn::Forbidden ForbiddenType; + typedef ::xsd::cxx::tree::optional< ForbiddenType > ForbiddenOptional; + typedef ::xsd::cxx::tree::traits< ForbiddenType, char > ForbiddenTraits; + + const ForbiddenOptional& + getForbidden () const; + + ForbiddenOptional& + getForbidden (); + + void + setForbidden (const ForbiddenType& x); + + void + setForbidden (const ForbiddenOptional& x); + + void + setForbidden (::std::unique_ptr< ForbiddenType > p); + + // error + // + typedef ::LinphonePrivate::Xsd::Imdn::Error ErrorType; + typedef ::xsd::cxx::tree::optional< ErrorType > ErrorOptional; + typedef ::xsd::cxx::tree::traits< ErrorType, char > ErrorTraits; + + const ErrorOptional& + getError () const; + + ErrorOptional& + getError (); + + void + setError (const ErrorType& x); + + void + setError (const ErrorOptional& x); + + void + setError (::std::unique_ptr< ErrorType > p); + + // any + // + typedef ::xsd::cxx::tree::element_sequence AnySequence; + typedef AnySequence::iterator AnyIterator; + typedef AnySequence::const_iterator AnyConstIterator; + + const AnySequence& + getAny () const; + + AnySequence& + getAny (); + + void + setAny (const AnySequence& s); + + // DOMDocument for wildcard content. + // + const ::xercesc::DOMDocument& + getDomDocument () const; + + ::xercesc::DOMDocument& + getDomDocument (); + + // Constructors. + // + Status2 (); + + Status2 (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + Status2 (const Status2& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual Status2* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + Status2& + operator= (const Status2& x); + + virtual + ~Status2 (); + + // Implementation. + // + protected: + void + parse (::xsd::cxx::xml::dom::parser< char >&, + ::LinphonePrivate::Xsd::XmlSchema::Flags); + + protected: + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > dom_document_; + + ProcessedOptional processed_; + StoredOptional stored_; + ForbiddenOptional forbidden_; + ErrorOptional error_; + AnySequence any_; + }; + } + } +} + +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + ::std::ostream& + operator<< (::std::ostream&, const Imdn&); + + ::std::ostream& + operator<< (::std::ostream&, const DeliveryNotification&); + + ::std::ostream& + operator<< (::std::ostream&, const Delivered&); + + ::std::ostream& + operator<< (::std::ostream&, const Failed&); + + ::std::ostream& + operator<< (::std::ostream&, const DisplayNotification&); + + ::std::ostream& + operator<< (::std::ostream&, const Displayed&); + + ::std::ostream& + operator<< (::std::ostream&, const ProcessingNotification&); + + ::std::ostream& + operator<< (::std::ostream&, const Processed&); + + ::std::ostream& + operator<< (::std::ostream&, const Stored&); + + ::std::ostream& + operator<< (::std::ostream&, const Forbidden&); + + ::std::ostream& + operator<< (::std::ostream&, const Error&); + + ::std::ostream& + operator<< (::std::ostream&, const Status&); + + ::std::ostream& + operator<< (::std::ostream&, const Status1&); + + ::std::ostream& + operator<< (::std::ostream&, const Status2&); + } + } +} + +#include + +#include +#include +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + // Parse a URI or a local file. + // + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (const ::std::string& uri, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (const ::std::string& uri, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (const ::std::string& uri, + ::xercesc::DOMErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + // Parse std::istream. + // + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + ::xercesc::DOMErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + const ::std::string& id, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + const ::std::string& id, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::std::istream& is, + const ::std::string& id, + ::xercesc::DOMErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + // Parse xercesc::InputSource. + // + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::xercesc::InputSource& is, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::xercesc::InputSource& is, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::xercesc::InputSource& is, + ::xercesc::DOMErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + // Parse xercesc::DOMDocument. + // + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (const ::xercesc::DOMDocument& d, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::Imdn::Imdn > + parseImdn (::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + } + } +} + +#include + +#include +#include +#include + +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace Imdn + { + // Serialize to std::ostream. + // + + void + serializeImdn (::std::ostream& os, + const ::LinphonePrivate::Xsd::Imdn::Imdn& x, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + serializeImdn (::std::ostream& os, + const ::LinphonePrivate::Xsd::Imdn::Imdn& x, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + serializeImdn (::std::ostream& os, + const ::LinphonePrivate::Xsd::Imdn::Imdn& x, + ::xercesc::DOMErrorHandler& eh, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + // Serialize to xercesc::XMLFormatTarget. + // + + void + serializeImdn (::xercesc::XMLFormatTarget& ft, + const ::LinphonePrivate::Xsd::Imdn::Imdn& x, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + serializeImdn (::xercesc::XMLFormatTarget& ft, + const ::LinphonePrivate::Xsd::Imdn::Imdn& x, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + serializeImdn (::xercesc::XMLFormatTarget& ft, + const ::LinphonePrivate::Xsd::Imdn::Imdn& x, + ::xercesc::DOMErrorHandler& eh, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + // Serialize to an existing xercesc::DOMDocument. + // + + void + serializeImdn (::xercesc::DOMDocument& d, + const ::LinphonePrivate::Xsd::Imdn::Imdn& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + // Serialize to a new xercesc::DOMDocument. + // + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > + serializeImdn (const ::LinphonePrivate::Xsd::Imdn::Imdn& x, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + operator<< (::xercesc::DOMElement&, const Imdn&); + + void + operator<< (::xercesc::DOMElement&, const DeliveryNotification&); + + void + operator<< (::xercesc::DOMElement&, const Delivered&); + + void + operator<< (::xercesc::DOMAttr&, const Delivered&); + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Delivered&); + + void + operator<< (::xercesc::DOMElement&, const Failed&); + + void + operator<< (::xercesc::DOMAttr&, const Failed&); + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Failed&); + + void + operator<< (::xercesc::DOMElement&, const DisplayNotification&); + + void + operator<< (::xercesc::DOMElement&, const Displayed&); + + void + operator<< (::xercesc::DOMAttr&, const Displayed&); + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Displayed&); + + void + operator<< (::xercesc::DOMElement&, const ProcessingNotification&); + + void + operator<< (::xercesc::DOMElement&, const Processed&); + + void + operator<< (::xercesc::DOMAttr&, const Processed&); + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Processed&); + + void + operator<< (::xercesc::DOMElement&, const Stored&); + + void + operator<< (::xercesc::DOMAttr&, const Stored&); + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Stored&); + + void + operator<< (::xercesc::DOMElement&, const Forbidden&); + + void + operator<< (::xercesc::DOMAttr&, const Forbidden&); + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Forbidden&); + + void + operator<< (::xercesc::DOMElement&, const Error&); + + void + operator<< (::xercesc::DOMAttr&, const Error&); + + void + operator<< (::LinphonePrivate::Xsd::XmlSchema::ListStream&, + const Error&); + + void + operator<< (::xercesc::DOMElement&, const Status&); + + void + operator<< (::xercesc::DOMElement&, const Status1&); + + void + operator<< (::xercesc::DOMElement&, const Status2&); + } + } +} + +#include + +// Begin epilogue. +// +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif +#if __clang__ || __GNUC__ >= 4 + #pragma GCC diagnostic pop +#endif +// +// End epilogue. + +#endif // XML_IMDN_H diff --git a/src/xml/imdn.xsd b/src/xml/imdn.xsd new file mode 100644 index 000000000..f69675f60 --- /dev/null +++ b/src/xml/imdn.xsd @@ -0,0 +1,158 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/xml/linphone-imdn.cpp b/src/xml/linphone-imdn.cpp new file mode 100644 index 000000000..d54b05414 --- /dev/null +++ b/src/xml/linphone-imdn.cpp @@ -0,0 +1,717 @@ +// Copyright (c) 2005-2014 Code Synthesis Tools CC +// +// This program was generated by CodeSynthesis XSD, an XML Schema to +// C++ data binding compiler. +// +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License version 2 as +// published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the Free Software +// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +// +// In addition, as a special exception, Code Synthesis Tools CC gives +// permission to link this program with the Xerces-C++ library (or with +// modified versions of Xerces-C++ that use the same license as Xerces-C++), +// and distribute linked combinations including the two. You must obey +// the GNU General Public License version 2 in all respects for all of +// the code used other than Xerces-C++. If you modify this copy of the +// program, you may extend this exception to your version of the program, +// but you are not obligated to do so. If you do not wish to do so, delete +// this exception statement from your version. +// +// Furthermore, Code Synthesis Tools CC makes a special exception for +// the Free/Libre and Open Source Software (FLOSS) which is described +// in the accompanying FLOSSE file. +// + +// Begin prologue. +// +#if __clang__ || __GNUC__ >= 4 + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wfloat-equal" +#endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" +#endif +// +// End prologue. + +#include + +#include "linphone-imdn.h" + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + // ImdnReason + // + + const ImdnReason::CodeType& ImdnReason:: + getCode () const + { + return this->code_.get (); + } + + ImdnReason::CodeType& ImdnReason:: + getCode () + { + return this->code_.get (); + } + + void ImdnReason:: + setCode (const CodeType& x) + { + this->code_.set (x); + } + + ImdnReason::CodeType ImdnReason:: + getCodeDefaultValue () + { + return CodeType (200); + } + } + } +} + +#include + +#include + +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_factory_plate< 0, char > + type_factory_plate_init; +} + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + // ImdnReason + // + + ImdnReason:: + ImdnReason () + : ::LinphonePrivate::Xsd::XmlSchema::String (), + code_ (getCodeDefaultValue (), this) + { + } + + ImdnReason:: + ImdnReason (const char* _xsd_String_base) + : ::LinphonePrivate::Xsd::XmlSchema::String (_xsd_String_base), + code_ (getCodeDefaultValue (), this) + { + } + + ImdnReason:: + ImdnReason (const ::std::string& _xsd_String_base) + : ::LinphonePrivate::Xsd::XmlSchema::String (_xsd_String_base), + code_ (getCodeDefaultValue (), this) + { + } + + ImdnReason:: + ImdnReason (const ::LinphonePrivate::Xsd::XmlSchema::String& _xsd_String_base) + : ::LinphonePrivate::Xsd::XmlSchema::String (_xsd_String_base), + code_ (getCodeDefaultValue (), this) + { + } + + ImdnReason:: + ImdnReason (const ImdnReason& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::String (x, f, c), + code_ (x.code_, f, this) + { + } + + ImdnReason:: + ImdnReason (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) + : ::LinphonePrivate::Xsd::XmlSchema::String (e, f | ::LinphonePrivate::Xsd::XmlSchema::Flags::base, c), + code_ (this) + { + if ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::base) == 0) + { + ::xsd::cxx::xml::dom::parser< char > p (e, false, false, true); + this->parse (p, f); + } + } + + void ImdnReason:: + parse (::xsd::cxx::xml::dom::parser< char >& p, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + while (p.more_attributes ()) + { + const ::xercesc::DOMAttr& i (p.next_attribute ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (i)); + + if (n.name () == "code" && n.namespace_ ().empty ()) + { + this->code_.set (CodeTraits::create (i, f, this)); + continue; + } + } + + if (!code_.present ()) + { + this->code_.set (getCodeDefaultValue ()); + } + } + + ImdnReason* ImdnReason:: + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f, + ::LinphonePrivate::Xsd::XmlSchema::Container* c) const + { + return new class ImdnReason (*this, f, c); + } + + ImdnReason& ImdnReason:: + operator= (const ImdnReason& x) + { + if (this != &x) + { + static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = x; + this->code_ = x.code_; + } + + return *this; + } + + ImdnReason:: + ~ImdnReason () + { + } + } + } +} + +#include + +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::std_ostream_plate< 0, char > + std_ostream_plate_init; +} + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + ::std::ostream& + operator<< (::std::ostream& o, const ImdnReason& i) + { + o << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::String& > (i); + + o << ::std::endl << "code: " << i.getCode (); + return o; + } + } + } +} + +#include +#include +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (const ::std::string& u, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::tree::error_handler< char > h; + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + u, h, p, f)); + + h.throw_if_failed< ::xsd::cxx::tree::parsing< char > > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > ( + ::LinphonePrivate::Xsd::LinphoneImdn::parseReason ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (const ::std::string& u, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + u, h, p, f)); + + if (!d.get ()) + throw ::xsd::cxx::tree::parsing< char > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > ( + ::LinphonePrivate::Xsd::LinphoneImdn::parseReason ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (const ::std::string& u, + ::xercesc::DOMErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + u, h, p, f)); + + if (!d.get ()) + throw ::xsd::cxx::tree::parsing< char > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > ( + ::LinphonePrivate::Xsd::LinphoneImdn::parseReason ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::xml::sax::std_input_source isrc (is); + return ::LinphonePrivate::Xsd::LinphoneImdn::parseReason (isrc, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::xml::sax::std_input_source isrc (is); + return ::LinphonePrivate::Xsd::LinphoneImdn::parseReason (isrc, h, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + ::xercesc::DOMErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::sax::std_input_source isrc (is); + return ::LinphonePrivate::Xsd::LinphoneImdn::parseReason (isrc, h, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + const ::std::string& sid, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::xml::sax::std_input_source isrc (is, sid); + return ::LinphonePrivate::Xsd::LinphoneImdn::parseReason (isrc, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + const ::std::string& sid, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0, + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) == 0); + + ::xsd::cxx::xml::sax::std_input_source isrc (is, sid); + return ::LinphonePrivate::Xsd::LinphoneImdn::parseReason (isrc, h, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + const ::std::string& sid, + ::xercesc::DOMErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::xml::sax::std_input_source isrc (is, sid); + return ::LinphonePrivate::Xsd::LinphoneImdn::parseReason (isrc, h, f, p); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::xercesc::InputSource& i, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::xsd::cxx::tree::error_handler< char > h; + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + i, h, p, f)); + + h.throw_if_failed< ::xsd::cxx::tree::parsing< char > > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > ( + ::LinphonePrivate::Xsd::LinphoneImdn::parseReason ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::xercesc::InputSource& i, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + i, h, p, f)); + + if (!d.get ()) + throw ::xsd::cxx::tree::parsing< char > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > ( + ::LinphonePrivate::Xsd::LinphoneImdn::parseReason ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::xercesc::InputSource& i, + ::xercesc::DOMErrorHandler& h, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::parse< char > ( + i, h, p, f)); + + if (!d.get ()) + throw ::xsd::cxx::tree::parsing< char > (); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > ( + ::LinphonePrivate::Xsd::LinphoneImdn::parseReason ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (const ::xercesc::DOMDocument& doc, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p) + { + if (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + static_cast< ::xercesc::DOMDocument* > (doc.cloneNode (true))); + + return ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > ( + ::LinphonePrivate::Xsd::LinphoneImdn::parseReason ( + std::move (d), f | ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom, p)); + } + + const ::xercesc::DOMElement& e (*doc.getDocumentElement ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (e)); + + if (n.name () == "reason" && + n.namespace_ () == "http://www.linphone.org/xsds/imdn.xsd") + { + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > r ( + ::xsd::cxx::tree::traits< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason, char >::create ( + e, f, 0)); + return r; + } + + throw ::xsd::cxx::tree::unexpected_element < char > ( + n.name (), + n.namespace_ (), + "reason", + "http://www.linphone.org/xsds/imdn.xsd"); + } + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d, + ::LinphonePrivate::Xsd::XmlSchema::Flags f, + const ::LinphonePrivate::Xsd::XmlSchema::Properties&) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > c ( + ((f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) && + !(f & ::LinphonePrivate::Xsd::XmlSchema::Flags::own_dom)) + ? static_cast< ::xercesc::DOMDocument* > (d->cloneNode (true)) + : 0); + + ::xercesc::DOMDocument& doc (c.get () ? *c : *d); + const ::xercesc::DOMElement& e (*doc.getDocumentElement ()); + + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (e)); + + if (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::keep_dom) + doc.setUserData (::LinphonePrivate::Xsd::XmlSchema::dom::treeNodeKey, + (c.get () ? &c : &d), + 0); + + if (n.name () == "reason" && + n.namespace_ () == "http://www.linphone.org/xsds/imdn.xsd") + { + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > r ( + ::xsd::cxx::tree::traits< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason, char >::create ( + e, f, 0)); + return r; + } + + throw ::xsd::cxx::tree::unexpected_element < char > ( + n.name (), + n.namespace_ (), + "reason", + "http://www.linphone.org/xsds/imdn.xsd"); + } + } + } +} + +#include +#include +#include + +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_serializer_plate< 0, char > + type_serializer_plate_init; +} + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + void + serializeReason (::std::ostream& o, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& s, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0); + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::LinphoneImdn::serializeReason (s, m, f)); + + ::xsd::cxx::tree::error_handler< char > h; + + ::xsd::cxx::xml::dom::ostream_format_target t (o); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + h.throw_if_failed< ::xsd::cxx::tree::serialization< char > > (); + } + } + + void + serializeReason (::std::ostream& o, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& s, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::xsd::cxx::xml::auto_initializer i ( + (f & ::LinphonePrivate::Xsd::XmlSchema::Flags::dont_initialize) == 0); + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::LinphoneImdn::serializeReason (s, m, f)); + ::xsd::cxx::xml::dom::ostream_format_target t (o); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + throw ::xsd::cxx::tree::serialization< char > (); + } + } + + void + serializeReason (::std::ostream& o, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& s, + ::xercesc::DOMErrorHandler& h, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::LinphoneImdn::serializeReason (s, m, f)); + ::xsd::cxx::xml::dom::ostream_format_target t (o); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + throw ::xsd::cxx::tree::serialization< char > (); + } + } + + void + serializeReason (::xercesc::XMLFormatTarget& t, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& s, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::LinphoneImdn::serializeReason (s, m, f)); + + ::xsd::cxx::tree::error_handler< char > h; + + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + h.throw_if_failed< ::xsd::cxx::tree::serialization< char > > (); + } + } + + void + serializeReason (::xercesc::XMLFormatTarget& t, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& s, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& h, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::LinphoneImdn::serializeReason (s, m, f)); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + throw ::xsd::cxx::tree::serialization< char > (); + } + } + + void + serializeReason (::xercesc::XMLFormatTarget& t, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& s, + ::xercesc::DOMErrorHandler& h, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + const ::std::string& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::LinphonePrivate::Xsd::LinphoneImdn::serializeReason (s, m, f)); + if (!::xsd::cxx::xml::dom::serialize (t, *d, e, h, f)) + { + throw ::xsd::cxx::tree::serialization< char > (); + } + } + + void + serializeReason (::xercesc::DOMDocument& d, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& s, + ::LinphonePrivate::Xsd::XmlSchema::Flags) + { + ::xercesc::DOMElement& e (*d.getDocumentElement ()); + const ::xsd::cxx::xml::qualified_name< char > n ( + ::xsd::cxx::xml::dom::name< char > (e)); + + if (n.name () == "reason" && + n.namespace_ () == "http://www.linphone.org/xsds/imdn.xsd") + { + e << s; + } + else + { + throw ::xsd::cxx::tree::unexpected_element < char > ( + n.name (), + n.namespace_ (), + "reason", + "http://www.linphone.org/xsds/imdn.xsd"); + } + } + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > + serializeReason (const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& s, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m, + ::LinphonePrivate::Xsd::XmlSchema::Flags f) + { + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d ( + ::xsd::cxx::xml::dom::serialize< char > ( + "reason", + "http://www.linphone.org/xsds/imdn.xsd", + m, f)); + + ::LinphonePrivate::Xsd::LinphoneImdn::serializeReason (*d, s, f); + return d; + } + + void + operator<< (::xercesc::DOMElement& e, const ImdnReason& i) + { + e << static_cast< const ::LinphonePrivate::Xsd::XmlSchema::String& > (i); + + // code + // + { + ::xercesc::DOMAttr& a ( + ::xsd::cxx::xml::dom::create_attribute ( + "code", + e)); + + a << i.getCode (); + } + } + } + } +} + +#include + +// Begin epilogue. +// +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif +#if __clang__ || __GNUC__ >= 4 + #pragma GCC diagnostic pop +#endif +// +// End epilogue. + diff --git a/src/xml/linphone-imdn.h b/src/xml/linphone-imdn.h new file mode 100644 index 000000000..42e1327a6 --- /dev/null +++ b/src/xml/linphone-imdn.h @@ -0,0 +1,592 @@ +// Copyright (c) 2005-2014 Code Synthesis Tools CC +// +// This program was generated by CodeSynthesis XSD, an XML Schema to +// C++ data binding compiler. +// +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License version 2 as +// published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the Free Software +// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +// +// In addition, as a special exception, Code Synthesis Tools CC gives +// permission to link this program with the Xerces-C++ library (or with +// modified versions of Xerces-C++ that use the same license as Xerces-C++), +// and distribute linked combinations including the two. You must obey +// the GNU General Public License version 2 in all respects for all of +// the code used other than Xerces-C++. If you modify this copy of the +// program, you may extend this exception to your version of the program, +// but you are not obligated to do so. If you do not wish to do so, delete +// this exception statement from your version. +// +// Furthermore, Code Synthesis Tools CC makes a special exception for +// the Free/Libre and Open Source Software (FLOSS) which is described +// in the accompanying FLOSSE file. +// + +#ifndef XML_LINPHONE_IMDN_H +#define XML_LINPHONE_IMDN_H + +#ifndef XSD_CXX11 +#define XSD_CXX11 +#endif + +#ifndef XSD_USE_CHAR +#define XSD_USE_CHAR +#endif + +#ifndef XSD_CXX_TREE_USE_CHAR +#define XSD_CXX_TREE_USE_CHAR +#endif + +// Begin prologue. +// +#if __clang__ || __GNUC__ >= 4 + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wfloat-equal" +#endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" +#endif +// +// End prologue. + +#include + +#if (XSD_INT_VERSION != 4000000L) +#error XSD runtime version mismatch +#endif + +#include + +#include + +#include +#include +#include + +#include + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace XmlSchema + { + // anyType and anySimpleType. + // + typedef ::xsd::cxx::tree::type Type; + typedef ::xsd::cxx::tree::simple_type< char, Type > SimpleType; + typedef ::xsd::cxx::tree::type Container; + + // 8-bit + // + typedef signed char Byte; + typedef unsigned char UnsignedByte; + + // 16-bit + // + typedef short Short; + typedef unsigned short UnsignedShort; + + // 32-bit + // + typedef int Int; + typedef unsigned int UnsignedInt; + + // 64-bit + // + typedef long long Long; + typedef unsigned long long UnsignedLong; + + // Supposed to be arbitrary-length integral types. + // + typedef long long Integer; + typedef long long NonPositiveInteger; + typedef unsigned long long NonNegativeInteger; + typedef unsigned long long PositiveInteger; + typedef long long NegativeInteger; + + // Boolean. + // + typedef bool Boolean; + + // Floating-point types. + // + typedef float Float; + typedef double Double; + typedef double Decimal; + + // String types. + // + typedef ::xsd::cxx::tree::string< char, SimpleType > String; + typedef ::xsd::cxx::tree::normalized_string< char, String > NormalizedString; + typedef ::xsd::cxx::tree::token< char, NormalizedString > Token; + typedef ::xsd::cxx::tree::name< char, Token > Name; + typedef ::xsd::cxx::tree::nmtoken< char, Token > Nmtoken; + typedef ::xsd::cxx::tree::nmtokens< char, SimpleType, Nmtoken > Nmtokens; + typedef ::xsd::cxx::tree::ncname< char, Name > Ncname; + typedef ::xsd::cxx::tree::language< char, Token > Language; + + // ID/IDREF. + // + typedef ::xsd::cxx::tree::id< char, Ncname > Id; + typedef ::xsd::cxx::tree::idref< char, Ncname, Type > Idref; + typedef ::xsd::cxx::tree::idrefs< char, SimpleType, Idref > Idrefs; + + // URI. + // + typedef ::xsd::cxx::tree::uri< char, SimpleType > Uri; + + // Qualified name. + // + typedef ::xsd::cxx::tree::qname< char, SimpleType, Uri, Ncname > Qname; + + // Binary. + // + typedef ::xsd::cxx::tree::buffer< char > Buffer; + typedef ::xsd::cxx::tree::base64_binary< char, SimpleType > Base64Binary; + typedef ::xsd::cxx::tree::hex_binary< char, SimpleType > HexBinary; + + // Date/time. + // + typedef ::xsd::cxx::tree::time_zone TimeZone; + typedef ::xsd::cxx::tree::date< char, SimpleType > Date; + typedef ::xsd::cxx::tree::date_time< char, SimpleType > DateTime; + typedef ::xsd::cxx::tree::duration< char, SimpleType > Duration; + typedef ::xsd::cxx::tree::gday< char, SimpleType > Gday; + typedef ::xsd::cxx::tree::gmonth< char, SimpleType > Gmonth; + typedef ::xsd::cxx::tree::gmonth_day< char, SimpleType > GmonthDay; + typedef ::xsd::cxx::tree::gyear< char, SimpleType > Gyear; + typedef ::xsd::cxx::tree::gyear_month< char, SimpleType > GyearMonth; + typedef ::xsd::cxx::tree::time< char, SimpleType > Time; + + // Entity. + // + typedef ::xsd::cxx::tree::entity< char, Ncname > Entity; + typedef ::xsd::cxx::tree::entities< char, SimpleType, Entity > Entities; + + typedef ::xsd::cxx::tree::content_order ContentOrder; + // Namespace information and list stream. Used in + // serialization functions. + // + typedef ::xsd::cxx::xml::dom::namespace_info< char > NamespaceInfo; + typedef ::xsd::cxx::xml::dom::namespace_infomap< char > NamespaceInfomap; + typedef ::xsd::cxx::tree::list_stream< char > ListStream; + typedef ::xsd::cxx::tree::as_double< Double > AsDouble; + typedef ::xsd::cxx::tree::as_decimal< Decimal > AsDecimal; + typedef ::xsd::cxx::tree::facet Facet; + + // Flags and properties. + // + typedef ::xsd::cxx::tree::flags Flags; + typedef ::xsd::cxx::tree::properties< char > Properties; + + // Parsing/serialization diagnostics. + // + typedef ::xsd::cxx::tree::severity Severity; + typedef ::xsd::cxx::tree::error< char > Error; + typedef ::xsd::cxx::tree::diagnostics< char > Diagnostics; + + // Exceptions. + // + typedef ::xsd::cxx::tree::exception< char > Exception; + typedef ::xsd::cxx::tree::bounds< char > Bounds; + typedef ::xsd::cxx::tree::duplicate_id< char > DuplicateId; + typedef ::xsd::cxx::tree::parsing< char > Parsing; + typedef ::xsd::cxx::tree::expected_element< char > ExpectedElement; + typedef ::xsd::cxx::tree::unexpected_element< char > UnexpectedElement; + typedef ::xsd::cxx::tree::expected_attribute< char > ExpectedAttribute; + typedef ::xsd::cxx::tree::unexpected_enumerator< char > UnexpectedEnumerator; + typedef ::xsd::cxx::tree::expected_text_content< char > ExpectedTextContent; + typedef ::xsd::cxx::tree::no_prefix_mapping< char > NoPrefixMapping; + typedef ::xsd::cxx::tree::no_type_info< char > NoTypeInfo; + typedef ::xsd::cxx::tree::not_derived< char > NotDerived; + typedef ::xsd::cxx::tree::serialization< char > Serialization; + + // Error handler callback interface. + // + typedef ::xsd::cxx::xml::error_handler< char > ErrorHandler; + + // DOM interaction. + // + namespace dom + { + // Automatic pointer for DOMDocument. + // + using ::xsd::cxx::xml::dom::unique_ptr; + +#ifndef XSD_CXX_TREE_TREE_NODE_KEY__LINPHONEPRIVATE__XSD__XMLSCHEMA +#define XSD_CXX_TREE_TREE_NODE_KEY__LINPHONEPRIVATE__XSD__XMLSCHEMA + // DOM user data key for back pointers to tree nodes. + // + const XMLCh* const treeNodeKey = ::xsd::cxx::tree::user_data_keys::node; +#endif + } + } + } +} + +// Forward declarations. +// +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + class ImdnReason; + } + } +} + + +#include // ::std::unique_ptr +#include // std::numeric_limits +#include // std::binary_search +#include // std::move + +#include + +#include +#include +#include +#include + +#include + +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + class ImdnReason: public ::LinphonePrivate::Xsd::XmlSchema::String + { + public: + // code + // + typedef ::LinphonePrivate::Xsd::XmlSchema::Int CodeType; + typedef ::xsd::cxx::tree::traits< CodeType, char > CodeTraits; + + const CodeType& + getCode () const; + + CodeType& + getCode (); + + void + setCode (const CodeType& x); + + static CodeType + getCodeDefaultValue (); + + // Constructors. + // + ImdnReason (); + + ImdnReason (const char*); + + ImdnReason (const ::std::string&); + + ImdnReason (const ::LinphonePrivate::Xsd::XmlSchema::String&); + + ImdnReason (const ::xercesc::DOMElement& e, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + ImdnReason (const ImdnReason& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0); + + virtual ImdnReason* + _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; + + ImdnReason& + operator= (const ImdnReason& x); + + virtual + ~ImdnReason (); + + // Implementation. + // + protected: + void + parse (::xsd::cxx::xml::dom::parser< char >&, + ::LinphonePrivate::Xsd::XmlSchema::Flags); + + protected: + ::xsd::cxx::tree::one< CodeType > code_; + }; + } + } +} + +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + ::std::ostream& + operator<< (::std::ostream&, const ImdnReason&); + } + } +} + +#include + +#include +#include +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + // Parse a URI or a local file. + // + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (const ::std::string& uri, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (const ::std::string& uri, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (const ::std::string& uri, + ::xercesc::DOMErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + // Parse std::istream. + // + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + ::xercesc::DOMErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + const ::std::string& id, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + const ::std::string& id, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::std::istream& is, + const ::std::string& id, + ::xercesc::DOMErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + // Parse xercesc::InputSource. + // + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::xercesc::InputSource& is, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::xercesc::InputSource& is, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::xercesc::InputSource& is, + ::xercesc::DOMErrorHandler& eh, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + // Parse xercesc::DOMDocument. + // + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (const ::xercesc::DOMDocument& d, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + + ::std::unique_ptr< ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason > + parseReason (::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > d, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, + const ::LinphonePrivate::Xsd::XmlSchema::Properties& p = ::LinphonePrivate::Xsd::XmlSchema::Properties ()); + } + } +} + +#include + +#include +#include +#include + +#include + +namespace LinphonePrivate +{ + namespace Xsd + { + namespace LinphoneImdn + { + // Serialize to std::ostream. + // + + void + serializeReason (::std::ostream& os, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& x, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + serializeReason (::std::ostream& os, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& x, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + serializeReason (::std::ostream& os, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& x, + ::xercesc::DOMErrorHandler& eh, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + // Serialize to xercesc::XMLFormatTarget. + // + + void + serializeReason (::xercesc::XMLFormatTarget& ft, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& x, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + serializeReason (::xercesc::XMLFormatTarget& ft, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& x, + ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + serializeReason (::xercesc::XMLFormatTarget& ft, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& x, + ::xercesc::DOMErrorHandler& eh, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + const ::std::string& e = "UTF-8", + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + // Serialize to an existing xercesc::DOMDocument. + // + + void + serializeReason (::xercesc::DOMDocument& d, + const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& x, + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + // Serialize to a new xercesc::DOMDocument. + // + + ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > + serializeReason (const ::LinphonePrivate::Xsd::LinphoneImdn::ImdnReason& x, + const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), + ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); + + void + operator<< (::xercesc::DOMElement&, const ImdnReason&); + } + } +} + +#include + +// Begin epilogue. +// +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif +#if __clang__ || __GNUC__ >= 4 + #pragma GCC diagnostic pop +#endif +// +// End epilogue. + +#endif // XML_LINPHONE_IMDN_H diff --git a/src/xml/linphone-imdn.xsd b/src/xml/linphone-imdn.xsd new file mode 100644 index 000000000..6a6136a0d --- /dev/null +++ b/src/xml/linphone-imdn.xsd @@ -0,0 +1,15 @@ + + + + + + + + + + + + diff --git a/src/xml/prologue.txt b/src/xml/prologue.txt index f2a7bf6f0..23e94d03a 100644 --- a/src/xml/prologue.txt +++ b/src/xml/prologue.txt @@ -1,7 +1,8 @@ #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wfloat-equal" -#ifndef __ANDROID__ +#endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wsuggest-override" #endif -#endif diff --git a/src/xml/resource-lists.cpp b/src/xml/resource-lists.cpp index 5d42e0137..79f90d384 100644 --- a/src/xml/resource-lists.cpp +++ b/src/xml/resource-lists.cpp @@ -36,9 +36,10 @@ #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wfloat-equal" -#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) - #pragma GCC diagnostic ignored "-Wsuggest-override" #endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" #endif // // End prologue. @@ -54,7 +55,7 @@ namespace LinphonePrivate namespace ResourceLists { // ListType - // + // const ListType::DisplayNameOptional& ListType:: getDisplayName () const @@ -238,7 +239,7 @@ namespace LinphonePrivate // EntryType - // + // const EntryType::DisplayNameOptional& EntryType:: getDisplayName () const @@ -350,7 +351,7 @@ namespace LinphonePrivate // EntryRefType - // + // const EntryRefType::DisplayNameOptional& EntryRefType:: getDisplayName () const @@ -462,7 +463,7 @@ namespace LinphonePrivate // ExternalType - // + // const ExternalType::DisplayNameOptional& ExternalType:: getDisplayName () const @@ -574,7 +575,7 @@ namespace LinphonePrivate // DisplayNameType - // + // const DisplayNameType::LangOptional& DisplayNameType:: getLang () const @@ -608,15 +609,15 @@ namespace LinphonePrivate // List - // + // // DisplayName - // + // // ResourceLists - // + // const ResourceLists::ListSequence& ResourceLists:: getList () const @@ -643,6 +644,15 @@ namespace LinphonePrivate #include +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_factory_plate< 0, char > + type_factory_plate_init; +} + namespace LinphonePrivate { namespace Xsd @@ -1558,6 +1568,15 @@ namespace LinphonePrivate #include +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::std_ostream_plate< 0, char > + std_ostream_plate_init; +} + namespace LinphonePrivate { namespace Xsd @@ -1976,6 +1995,15 @@ namespace LinphonePrivate #include #include +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_serializer_plate< 0, char > + type_serializer_plate_init; +} + namespace LinphonePrivate { namespace Xsd @@ -2483,8 +2511,12 @@ namespace LinphonePrivate // Begin epilogue. // +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic pop #endif // // End epilogue. + diff --git a/src/xml/resource-lists.h b/src/xml/resource-lists.h index 1062cfb31..4494881c4 100644 --- a/src/xml/resource-lists.h +++ b/src/xml/resource-lists.h @@ -51,9 +51,10 @@ #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wfloat-equal" -#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) - #pragma GCC diagnostic ignored "-Wsuggest-override" #endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" #endif // // End prologue. @@ -240,6 +241,8 @@ namespace LinphonePrivate typedef ::xsd::cxx::tree::unexpected_enumerator< char > UnexpectedEnumerator; typedef ::xsd::cxx::tree::expected_text_content< char > ExpectedTextContent; typedef ::xsd::cxx::tree::no_prefix_mapping< char > NoPrefixMapping; + typedef ::xsd::cxx::tree::no_type_info< char > NoTypeInfo; + typedef ::xsd::cxx::tree::not_derived< char > NotDerived; typedef ::xsd::cxx::tree::serialization< char > Serialization; // Error handler callback interface. @@ -480,7 +483,7 @@ namespace LinphonePrivate ListType& operator= (const ListType& x); - virtual + virtual ~ListType (); // Implementation. @@ -604,7 +607,7 @@ namespace LinphonePrivate EntryType& operator= (const EntryType& x); - virtual + virtual ~EntryType (); // Implementation. @@ -724,7 +727,7 @@ namespace LinphonePrivate EntryRefType& operator= (const EntryRefType& x); - virtual + virtual ~EntryRefType (); // Implementation. @@ -845,7 +848,7 @@ namespace LinphonePrivate ExternalType& operator= (const ExternalType& x); - virtual + virtual ~ExternalType (); // Implementation. @@ -913,7 +916,7 @@ namespace LinphonePrivate DisplayNameType& operator= (const DisplayNameType& x); - virtual + virtual ~DisplayNameType (); // Implementation. @@ -946,7 +949,7 @@ namespace LinphonePrivate _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; - virtual + virtual ~List (); }; @@ -975,7 +978,7 @@ namespace LinphonePrivate _clone (::LinphonePrivate::Xsd::XmlSchema::Flags f = 0, ::LinphonePrivate::Xsd::XmlSchema::Container* c = 0) const; - virtual + virtual ~DisplayName (); }; @@ -1018,7 +1021,7 @@ namespace LinphonePrivate ResourceLists& operator= (const ResourceLists& x); - virtual + virtual ~ResourceLists (); // Implementation. @@ -1209,14 +1212,14 @@ namespace LinphonePrivate void serializeResourceLists (::std::ostream& os, - const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, + const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); void serializeResourceLists (::std::ostream& os, - const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, + const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", @@ -1224,7 +1227,7 @@ namespace LinphonePrivate void serializeResourceLists (::std::ostream& os, - const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, + const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, ::xercesc::DOMErrorHandler& eh, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", @@ -1235,14 +1238,14 @@ namespace LinphonePrivate void serializeResourceLists (::xercesc::XMLFormatTarget& ft, - const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, + const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); void serializeResourceLists (::xercesc::XMLFormatTarget& ft, - const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, + const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, ::LinphonePrivate::Xsd::XmlSchema::ErrorHandler& eh, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", @@ -1250,7 +1253,7 @@ namespace LinphonePrivate void serializeResourceLists (::xercesc::XMLFormatTarget& ft, - const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, + const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, ::xercesc::DOMErrorHandler& eh, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), const ::std::string& e = "UTF-8", @@ -1268,7 +1271,7 @@ namespace LinphonePrivate // ::LinphonePrivate::Xsd::XmlSchema::dom::unique_ptr< ::xercesc::DOMDocument > - serializeResourceLists (const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, + serializeResourceLists (const ::LinphonePrivate::Xsd::ResourceLists::ResourceLists& x, const ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap& m = ::LinphonePrivate::Xsd::XmlSchema::NamespaceInfomap (), ::LinphonePrivate::Xsd::XmlSchema::Flags f = 0); @@ -1291,6 +1294,9 @@ namespace LinphonePrivate // Begin epilogue. // +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic pop #endif diff --git a/src/xml/xml.cpp b/src/xml/xml.cpp index b8c204909..f052e7f5a 100644 --- a/src/xml/xml.cpp +++ b/src/xml/xml.cpp @@ -36,9 +36,10 @@ #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wfloat-equal" -#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) - #pragma GCC diagnostic ignored "-Wsuggest-override" #endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" #endif // // End prologue. @@ -73,7 +74,7 @@ namespace namespace_ } // Space - // + // Space:: Space (Value v) @@ -110,7 +111,7 @@ namespace namespace_ Space& Space:: operator= (Value v) { - static_cast< ::LinphonePrivate::Xsd::XmlSchema::Ncname& > (*this) = + static_cast< ::LinphonePrivate::Xsd::XmlSchema::Ncname& > (*this) = ::LinphonePrivate::Xsd::XmlSchema::Ncname (_xsd_Space_literals_[v]); return *this; @@ -118,7 +119,7 @@ namespace namespace_ // Lang_member - // + // Lang_member:: Lang_member (Value v) @@ -155,7 +156,7 @@ namespace namespace_ Lang_member& Lang_member:: operator= (Value v) { - static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = + static_cast< ::LinphonePrivate::Xsd::XmlSchema::String& > (*this) = ::LinphonePrivate::Xsd::XmlSchema::String (_xsd_Lang_member_literals_[v]); return *this; @@ -166,6 +167,15 @@ namespace namespace_ #include +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_factory_plate< 0, char > + type_factory_plate_init; +} + namespace namespace_ { // Lang @@ -344,6 +354,15 @@ namespace namespace_ #include +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::std_ostream_plate< 0, char > + std_ostream_plate_init; +} + namespace namespace_ { ::std::ostream& @@ -389,6 +408,15 @@ namespace namespace_ #include #include +#include + +namespace _xsd +{ + static + const ::xsd::cxx::tree::type_serializer_plate< 0, char > + type_serializer_plate_init; +} + namespace namespace_ { void @@ -453,8 +481,12 @@ namespace namespace_ // Begin epilogue. // +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic pop #endif // // End epilogue. + diff --git a/src/xml/xml.h b/src/xml/xml.h index af3c3c3a2..681dc279d 100644 --- a/src/xml/xml.h +++ b/src/xml/xml.h @@ -51,9 +51,10 @@ #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wfloat-equal" -#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) - #pragma GCC diagnostic ignored "-Wsuggest-override" #endif +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wsuggest-override" #endif // // End prologue. @@ -240,6 +241,8 @@ namespace LinphonePrivate typedef ::xsd::cxx::tree::unexpected_enumerator< char > UnexpectedEnumerator; typedef ::xsd::cxx::tree::expected_text_content< char > ExpectedTextContent; typedef ::xsd::cxx::tree::no_prefix_mapping< char > NoPrefixMapping; + typedef ::xsd::cxx::tree::no_type_info< char > NoTypeInfo; + typedef ::xsd::cxx::tree::not_derived< char > NotDerived; typedef ::xsd::cxx::tree::serialization< char > Serialization; // Error handler callback interface. @@ -510,6 +513,9 @@ namespace namespace_ // Begin epilogue. // +#if __GNUC__ > 5 || (__GNUC__ == 5 && __GNUC_MINOR__ >= 1) + #pragma GCC diagnostic pop +#endif #if __clang__ || __GNUC__ >= 4 #pragma GCC diagnostic pop #endif diff --git a/tester/group_chat_tester.c b/tester/group_chat_tester.c index d5c5b427b..ca6eed11d 100644 --- a/tester/group_chat_tester.c +++ b/tester/group_chat_tester.c @@ -3077,8 +3077,8 @@ static void imdn_for_group_chat_room (void) { // Chloe begins composing a message const char *chloeTextMessage = "Hello"; LinphoneChatMessage *chloeMessage = _send_message(chloeCr, chloeTextMessage); - BC_ASSERT_TRUE(wait_for_list(coresList, &marie->stat.number_of_LinphoneMessageReceived, initialMarieStats.number_of_LinphoneMessageReceived + 1, 10000)); - BC_ASSERT_TRUE(wait_for_list(coresList, &pauline->stat.number_of_LinphoneMessageReceived, initialPaulineStats.number_of_LinphoneMessageReceived + 1, 10000)); + BC_ASSERT_TRUE(wait_for_list(coresList, &marie->stat.number_of_LinphoneMessageReceived, initialMarieStats.number_of_LinphoneMessageReceived + 1, 3000)); + BC_ASSERT_TRUE(wait_for_list(coresList, &pauline->stat.number_of_LinphoneMessageReceived, initialPaulineStats.number_of_LinphoneMessageReceived + 1, 3000)); LinphoneChatMessage *marieLastMsg = marie->stat.last_received_chat_message; if (!BC_ASSERT_PTR_NOT_NULL(marieLastMsg)) goto end; @@ -3088,7 +3088,7 @@ static void imdn_for_group_chat_room (void) { linphone_address_unref(chloeAddr); // Check that the message has been delivered to Marie and Pauline - BC_ASSERT_TRUE(wait_for_list(coresList, &chloe->stat.number_of_LinphoneMessageDeliveredToUser, initialChloeStats.number_of_LinphoneMessageDeliveredToUser + 1, 1000)); + BC_ASSERT_TRUE(wait_for_list(coresList, &chloe->stat.number_of_LinphoneMessageDeliveredToUser, initialChloeStats.number_of_LinphoneMessageDeliveredToUser + 1, 3000)); BC_ASSERT_PTR_NULL(linphone_chat_message_get_participants_that_have_displayed(chloeMessage)); bctbx_list_t *participantsThatReceivedChloeMessage = linphone_chat_message_get_participants_that_have_received(chloeMessage); if (BC_ASSERT_PTR_NOT_NULL(participantsThatReceivedChloeMessage)) { @@ -3105,7 +3105,7 @@ static void imdn_for_group_chat_room (void) { // Marie marks the message as read, check that the state is not yet displayed on Chloe's side linphone_chat_room_mark_as_read(marieCr); - BC_ASSERT_FALSE(wait_for_list(coresList, &chloe->stat.number_of_LinphoneMessageDisplayed, initialChloeStats.number_of_LinphoneMessageDisplayed + 1, 1000)); + BC_ASSERT_FALSE(wait_for_list(coresList, &chloe->stat.number_of_LinphoneMessageDisplayed, initialChloeStats.number_of_LinphoneMessageDisplayed + 1, 3000)); bctbx_list_t *participantsThatDisplayedChloeMessage = linphone_chat_message_get_participants_that_have_displayed(chloeMessage); if (BC_ASSERT_PTR_NOT_NULL(participantsThatDisplayedChloeMessage)) { BC_ASSERT_EQUAL((int)bctbx_list_size(participantsThatDisplayedChloeMessage), 1, int, "%d"); @@ -3120,7 +3120,7 @@ static void imdn_for_group_chat_room (void) { // Pauline also marks the message as read, check that the state is now displayed on Chloe's side linphone_chat_room_mark_as_read(paulineCr); - BC_ASSERT_TRUE(wait_for_list(coresList, &chloe->stat.number_of_LinphoneMessageDisplayed, initialChloeStats.number_of_LinphoneMessageDisplayed + 1, 1000)); + BC_ASSERT_TRUE(wait_for_list(coresList, &chloe->stat.number_of_LinphoneMessageDisplayed, initialChloeStats.number_of_LinphoneMessageDisplayed + 1, 3000)); participantsThatDisplayedChloeMessage = linphone_chat_message_get_participants_that_have_displayed(chloeMessage); if (BC_ASSERT_PTR_NOT_NULL(participantsThatDisplayedChloeMessage)) { BC_ASSERT_EQUAL((int)bctbx_list_size(participantsThatDisplayedChloeMessage), 2, int, "%d");