0
我需要將以下命名空間添加到我的XSD文件:添加命名空間XML文檔不包含http:
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:tns="catalog.enterprise.level3.com" attributeFormDefault="unqualified">
當我嘗試添加目標命名空間,它抱怨一個MalformedURIException,我以爲是因爲名稱空間URI中沒有http://。我正在使用XOM。
Element rootWriter;
rootWriter.addNamespaceDeclaration("tns","catalog.enterprise.level3.com");
有人請給我建議,如何解決這個問題。