docs: protected void addImportedSchemas(Schema schema) throws WSDLException, IOException, TransformerException, TransformerFactoryConfigurationError {
          for (Object imports : schema.getImports().values()) {
              for (SchemaImport schemaImport : (Vector<SchemaImport>)imports) {
                  // Prevent duplicate imports
                  if (!importedSchemas.contains(schemaImport.getNamespaceURI())) {
                      importedSchemas.add(schemaImport.getNamespaceURI());
                      Schema referencedSchema = schemaImport.getReferencedSchema();
  
                      if (referencedSchema != null) {
                          ByteArrayOutputStream bos = new ByteArrayOutputStream();
                          Source source = new DOMSource(referencedSchema.getElement());
                          Result result = new StreamResult(bos);
  
                          TransformerFactory.newInstance().newTransformer().transform(source, result);
                          Resource schemaResource = new ByteArrayResource(bos.toByteArray());
  
                          addImportedSchemas(referencedSchema);
                          schemaResources.add(schemaResource);
                      }
                  }
              }
          }
      }