Validate module and catalogs
Thursday, 16 June 2016 · 3 messages · last reply 21 Jun 2016
FB
France Baril16 Jun 2016 22:28 #
I created an entire process for my xquery to read a catalog that is built from multiple catalogs (<nextCatalog/>) so I can find the correct schema to validate my XML topics based on the schema reference (My XML files don't all use the same schemas) <topic xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance" xml:lang="en-us" class="- topic/topic " xsi:noNamespaceSchemaLocation="
urn:oasis:names:tc:dita:psd:ditabase.xsd:1.3", only to discover that once I have my schema and
validate:xsd-info($doc, $xsd), it can't be processed because the main .xsd uses references that also require the catalog:<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:ditaarch="
http://dita.oasis-open.org/architecture/2005/" elementFormDefault=
"qualified" attributeFormDefault="unqualified">
<!-- ================ TOPIC DOMAINS ===================== -->
<xs:include schemaLocation="
urn:oasis:names:tc:dita:xsd:abbreviateDomain.xsd:1.3"/>
<xs:include schemaLocation=
"urn:oasis:names:tc:dita:xsd:deliveryTargetAttDomain.xsd:1.3"/>
<xs:include schemaLocation=
"urn:oasis:names:tc:dita:xsd:equationDomain.xsd:1.3"/>
<xs:include schemaLocation=
"urn:oasis:names:tc:dita:xsd:hazardDomain.xsd:1.3"/>
<xs:include schemaLocation=
"urn:oasis:names:tc:dita:psd:highlightDomain.xsd:1.3"/>My question is: Is it worth it for me to keep going with my ugly parse/replace + export game or is BaseX going to support
validate:xsd-info($doc,
$catalog) soon? If so how soon?
Also, any chance we can keep the DOCTYPE and allow the same type of validation with DTDs? Ya, I know, I'm pushing my luck... but I have to ask because some clients cannot move to schemas.--
France Baril
Architecte documentaire / Documentation architect
france.baril at architextus.com
CG
Christian Grün18 Jun 2016 15:02 #
Hi France,
Quoted text · France Baril · 3 lines
> My question is: Is it worth it for me to keep going with my ugly > parse/replace + export game or is BaseX going to support > validate:xsd-info($doc, $catalog) soon? If so how soon?
Currently, it has no high priority on our agenda, sorry. However, if someone provides me with some straightforward Java code, or would even be willing to include it in the code [1] (which should be
straightforward as well), I’ll be glad to have a look at it.
Cheers,
Christian
[1] https://github.com/BaseXdb/basex/blob/master/basex-core/src/main/java/org/basex/query/func/validate/ValidateXsd.java
Quoted text · France Baril · 11 lines
> > > Also, any chance we can keep the DOCTYPE and allow the same type of > validation with DTDs? Ya, I know, I'm pushing my luck... but I have to ask > because some clients cannot move to schemas. > > > -- > France Baril > Architecte documentaire / Documentation architect > france.baril at architextus.com
FB
France Baril21 Jun 2016 01:29 #
I'm really bad at java. I know just enough to break everything. I'll work with what I have from xquery.
Thanks for the come back!
Quoted text · Christian Grün · 33 lines
On Sat, Jun 18, 2016 at 6:02 AM, Christian Grün <christian.gruen at gmail.com> wrote: > Hi France, > > > My question is: Is it worth it for me to keep going with my ugly > > parse/replace + export game or is BaseX going to support > > > validate:xsd-info($doc, $catalog) soon? If so how soon? > > Currently, it has no high priority on our agenda, sorry. However, if > someone provides me with some straightforward Java code, or would even > be willing to include it in the code [1] (which should be > straightforward as well), I’ll be glad to have a look at it. > > Cheers, > Christian > > [1] > https://github.com/BaseXdb/basex/blob/master/basex-core/src/main/java/org/basex/query/func/validate/ValidateXsd.java > > > > > > > Also, any chance we can keep the DOCTYPE and allow the same type of > > validation with DTDs? Ya, I know, I'm pushing my luck... but I have to > ask > > because some clients cannot move to schemas. > > > > > > -- > > France Baril > > Architecte documentaire / Documentation architect > > france.baril at architextus.com >
--
France Baril
Architecte documentaire / Documentation architect
france.baril at architextus.com
Written for BaseX 8.4. BaseX may have changed since: please check the current documentation.
⚡Generated with XQuery