Author: mukulg
Date: Fri Apr 12 06:32:27 2013
New Revision: 1467171
URL: http://svn.apache.org/r1467171
Log:
committing few minor improvements to xerces xsd 1.1 docs
Modified:
xerces/java/branches/xml-schema-1.1-dev/docs/faq-xs.xml
Modified: xerces/java/branches/xml-schema-1.1-dev/docs/faq-xs.xml
URL:
http://svn.apache.org/viewvc/xerces/java/branches/xml-schema-1.1-dev/docs/faq-xs.xml?rev=1467171&r1=1467170&r2=1467171&view=diff
==
--- xerces/java/branches/xml-schema-1.1-dev/docs/faq-xs.xml (original)
+++ xerces/java/branches/xml-schema-1.1-dev/docs/faq-xs.xml Fri Apr 12 06:32:27
2013
@@ -90,7 +90,7 @@ v.validate(instanceDocument);
- How Xerces-J uses an XPath 2.0 engine for XML Schema 1.1 assertions
and CTAs?
+ How an XPath 2.0 engine is used for XML Schema 1.1 assertions and
CTAs?
XML Schema 1.1 assertions and CTAs require an XPath processor
during evaluation. For XSD 1.1 assertions,
full http://www.w3.org/TR/xpath20/";>XPath 2.0
support is required. For XSD 1.1 CTAs the XSD schema engines can
@@ -102,33 +102,26 @@ v.validate(instanceDocument);
(for XSD 1.1 assertions, and optionally for CTAs), Xerces-J uses the
http://wiki.eclipse.org/PsychoPathXPathProcessor";>Eclipse/PsychoPath
XPath 2.0 engine.
Xerces-J does bundle along a PsychoPath XPath 2.0 jar (which
requires JDK 1.4 or later).
-
- Users should be aware that more recent releases of the Eclipse
PsychoPath
- XPath engine may have better conformance to the W3C XPath 2.0
language than the PsychoPath XPath 2.0 jar that's bundled with Apache Xerces-J.
- Official builds of the PsychoPath XPath 2.0 jar are available for
download from the location, http://www.eclipse.org/webtools/";>Eclipse Web Tools Platform (WTP)
Project -
- The latest 'Released' or a 'Stable milestone' WTP version can be
downloaded from here (from which the PsychoPath XPath 2.0 jar can be extracted).
- The latest PsychoPath XPath 2.0 engine builds at Eclipse require a
minimum JDK level of 1.5.
-
How to specify a user defined error message, when an XML Schema 1.1
assertion returns a 'false' result?
-By default when an XSD 1.1 assertion fails, the Xerces XML Schema
validator would produce a default error message,
+When evaluation of an XSD 1.1 assertion fails the Xerces XML Schema
validator would produce a default error message,
which would say that which element or attribute was not validated
successfully by an assertion and the schema type involved
during validation. It is however possible to, specify an user-defined
error message for assertion failures. This is done by
-specifying an attribute "message" in the XML namespace
'http://xerces.apache.org' on an xs:assert or
xs:assertion
-element in the schema. The value of attribute "message"
is the text of user-defined assertion error message, which is produced by
-the Xerces XML Schema validator when an assertion fails.
+specifying an attribute "message" in the XML namespace
'http://xerces.apache.org' on an
+xs:assert or xs:assertion element in the
schema. In this case, the value of attribute "message"
+is a text of user-defined assertion error message which is generated
by the Xerces XML Schema validator when an assertion fails.
-In case of use of the XML Schema xs:assertion facet
within simple types, if a user defined error message is used, if a user wants
-it is further possible to dynamically construct the assertion error
message by fetching the value of XPath 2.0 context variable
-$value into the assertion error message. Following is an
example of such an assertion error message:
-xerces:message="The number {$value} is not divisible by
2". With such a specification of assertion error message,
-a value from XML instance document is assigned to a variable
placeholder {$value} (which is a key word). Therefore at
-runtime, an assertion message for this example would be produced as
follows, "The number 3 is not divisible by 2"
-(the value 3 was assigned to the variable reference
{$value}).
+While using xs:assertion facet within simple types, if a
user defined error message is used, a user may
+dynamically construct the assertion error message by getting the value
of XPath 2.0 context variable
+$value into the error message. Following is an example of
such an assertion error message:
+xerces:message="The number {$value} is not divisible by
2". With such a description of assertion error message,
+a value from XML instance document is assigned to a variable reference
{$value} which is a defined keyword.
+During a validati