media-io / yaserde

Yet Another Serializer/Deserializer
MIT License
174 stars 58 forks source link

Feature Request: Include directive not processed #161

Open PRTGC opened 1 year ago

PRTGC commented 1 year ago

Hi... This package is utilized by Zeep which is generating rust code from SOAP wsdl's. One issue is that Includes are not processed, which causes Zeep to fail to generate code when it is processsing any multi-file project...

<?xml version="1.0" encoding="UTF-8" ?>
<!--
   Copyright 2005-2018 VMware, Inc.  All rights reserved.
-->
<definitions targetNamespace="urn:vim25"
   xmlns="http://schemas.xmlsoap.org/wsdl/"
   xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
   xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
   xmlns:vim25="urn:vim25"
   xmlns:xsd="http://www.w3.org/2001/XMLSchema"
>
   <types>
      <schema
         targetNamespace="urn:vim25"
         xmlns="http://www.w3.org/2001/XMLSchema"
         xmlns:vim25="urn:vim25"
         xmlns:xsd="http://www.w3.org/2001/XMLSchema"
         xmlns:reflect="urn:reflect"
         elementFormDefault="qualified"
      >
         <include schemaLocation="query-messagetypes.xsd" />
         <include schemaLocation="vim-types.xsd" />
         <include schemaLocation="core-types.xsd" />
         <import namespace="urn:reflect" schemaLocation="reflect-messagetypes.xsd" />
...
</definitions>

Any chance this feature could be added ?

Thanks JR

MarcAntoine-Arnaud commented 5 months ago

Hi @PRTGC ,

The support of include verb will not be considered in YaSerDe. It's out of the scope of serializing/deserializing XML.

But regarding the related issue on Zeep, you may have to open another issue about supporting AnyType on YaSerDe.