Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » XML Schema Definition (XSD) » XSDSimpleTypeDefinition - facets, syntheticFacets, and facetContents
XSDSimpleTypeDefinition - facets, syntheticFacets, and facetContents [message #47141] Thu, 03 June 2004 17:01 Go to next message
Dennis Fuglsang is currently offline Dennis Fuglsang
Messages: 77
Registered: July 2009
Member
Ed or Frank,

Can you briefly explain the difference between the facets, syntheticFacets,
and facetContents features with XSDSimpleTypeDefintion ?
I have studied the implementation and even looked at feature values for
various sample schemas but I still do not have a clear understanding
of what each is intended to hold. Thanks !

Dennis Fuglsang
Re: XSDSimpleTypeDefinition - facets, syntheticFacets, and facetContents [message #47172 is a reply to message #47141] Thu, 03 June 2004 18:30 Go to previous message
Eclipse User
Originally posted by: merks.ca.ibm.com

--------------72D6D0FC2A7100696EAA9017
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Dennis,

XSDSimpleTypeDefinition.getFacets returns exactly what's defined in the spec.
It's computed from the concrete syntax (i.e.,
XSDSimpleTypeDefinition.getFacetConents, which represents what literally
appears in each type definition in the XML syntax) by walking up the base type
hierarchy and collecting the deepest version of each kind of facet that appears
literally, i.e., the effective ones. There is a rule that specifies that a
list's whitespace facet is "collapse",
thttp://www.w3.org/TR/xmlschema-2/#derivation-by-list, so that requires
creating a facet and containing it somewhere (so that it isn't a dangling
reference). This is what XSDSimpleTypeDefinition.getSyntheticFacets() is used
for. It's also used to hold the result of folding repeating facets, i.e.,
pattern and enumeration, into a single one that provides a list of all the
values, as required by http://www.w3.org/TR/xmlschema-2/#dc-enumeration and
http://www.w3.org/TR/xmlschema-2/#dc-pattern. In general, you will not be
interested in looking at the getSyntheticFacets directly, getFacetContents will
be of limited interest, unless you are constructing an instance or editing one,
and it's getFacets that provides you access to the fully analysed semantic
result...


Dennis Fuglsang wrote:

> Ed or Frank,
>
> Can you briefly explain the difference between the facets, syntheticFacets,
> and facetContents features with XSDSimpleTypeDefintion ?
> I have studied the implementation and even looked at feature values for
> various sample schemas but I still do not have a clear understanding
> of what each is intended to hold. Thanks !
>
> Dennis Fuglsang

--------------72D6D0FC2A7100696EAA9017
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Dennis,
<p>XSDSimpleTypeDefinition.getFacets returns exactly what's defined in
the spec. It's computed from the concrete syntax (i.e., XSDSimpleTypeDefinition.getFacetConents,
which represents what literally appears in each type definition in the
XML syntax) by walking up the base type hierarchy and collecting the deepest
version of each kind of facet that appears literally, i.e., the effective
ones.&nbsp; There is a rule that specifies that a list's whitespace facet
is "collapse",
<a href="http://www.w3.org/TR/xmlschema-2/#derivation-by-list">thttp://www.w3.org/TR/xmlschema-2/#derivation-by-list</a>,
so that requires creating a facet and containing it somewhere (so that
it isn't a dangling reference).&nbsp; This is what XSDSimpleTypeDefinition.getSyntheticFacets()
is used for.&nbsp; It's also used to hold the result of folding repeating
facets, i.e., pattern and enumeration, into a single one that provides
a list of all the values, as required by&nbsp; <a href="http://www.w3.org/TR/xmlschema-2/#dc-enumeration">http://www.w3.org/TR/xmlschema-2/#dc-enumeration</a>
and <a href="http://www.w3.org/TR/xmlschema-2/#dc-pattern">http://www.w3.org/TR/xmlschema-2/#dc-pattern</a>.
In general, you will not be interested in looking at the getSyntheticFacets
directly, getFacetContents will be of limited interest, unless you are
constructing an instance or editing one, and it's getFacets that provides
you access to the fully analysed semantic result...
<br>&nbsp;
<p>Dennis Fuglsang wrote:
<blockquote TYPE=CITE>Ed or Frank,
<p>Can you briefly explain the difference between the facets, syntheticFacets,
<br>and facetContents features with XSDSimpleTypeDefintion ?
<br>I have studied the implementation and even looked at feature values
for
<br>various sample schemas but I still do not have a clear understanding
<br>of what each is intended to hold.&nbsp; Thanks !
<p>Dennis Fuglsang</blockquote>
</html>

--------------72D6D0FC2A7100696EAA9017--
Re: XSDSimpleTypeDefinition - facets, syntheticFacets, and facetContents [message #588140 is a reply to message #47141] Thu, 03 June 2004 18:30 Go to previous message
Ed Merks is currently offline Ed Merks
Messages: 25942
Registered: July 2009
Senior Member
--------------72D6D0FC2A7100696EAA9017
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Dennis,

XSDSimpleTypeDefinition.getFacets returns exactly what's defined in the spec.
It's computed from the concrete syntax (i.e.,
XSDSimpleTypeDefinition.getFacetConents, which represents what literally
appears in each type definition in the XML syntax) by walking up the base type
hierarchy and collecting the deepest version of each kind of facet that appears
literally, i.e., the effective ones. There is a rule that specifies that a
list's whitespace facet is "collapse",
thttp://www.w3.org/TR/xmlschema-2/#derivation-by-list, so that requires
creating a facet and containing it somewhere (so that it isn't a dangling
reference). This is what XSDSimpleTypeDefinition.getSyntheticFacets() is used
for. It's also used to hold the result of folding repeating facets, i.e.,
pattern and enumeration, into a single one that provides a list of all the
values, as required by http://www.w3.org/TR/xmlschema-2/#dc-enumeration and
http://www.w3.org/TR/xmlschema-2/#dc-pattern In general, you will not be
interested in looking at the getSyntheticFacets directly, getFacetContents will
be of limited interest, unless you are constructing an instance or editing one,
and it's getFacets that provides you access to the fully analysed semantic
result...


Dennis Fuglsang wrote:

> Ed or Frank,
>
> Can you briefly explain the difference between the facets, syntheticFacets,
> and facetContents features with XSDSimpleTypeDefintion ?
> I have studied the implementation and even looked at feature values for
> various sample schemas but I still do not have a clear understanding
> of what each is intended to hold. Thanks !
>
> Dennis Fuglsang

--------------72D6D0FC2A7100696EAA9017
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
Dennis,
<p>XSDSimpleTypeDefinition.getFacets returns exactly what's defined in
the spec. It's computed from the concrete syntax (i.e., XSDSimpleTypeDefinition.getFacetConents,
which represents what literally appears in each type definition in the
XML syntax) by walking up the base type hierarchy and collecting the deepest
version of each kind of facet that appears literally, i.e., the effective
ones.&nbsp; There is a rule that specifies that a list's whitespace facet
is "collapse",
<a href="http://www.w3.org/TR/xmlschema-2/#derivation-by-list">thttp://www.w3.org/TR/xmlschema-2/#derivation-by-list</a>,
so that requires creating a facet and containing it somewhere (so that
it isn't a dangling reference).&nbsp; This is what XSDSimpleTypeDefinition.getSyntheticFacets()
is used for.&nbsp; It's also used to hold the result of folding repeating
facets, i.e., pattern and enumeration, into a single one that provides
a list of all the values, as required by&nbsp; <a href="http://www.w3.org/TR/xmlschema-2/#dc-enumeration">http://www.w3.org/TR/xmlschema-2/#dc-enumeration</a>
and <a href="http://www.w3.org/TR/xmlschema-2/#dc-pattern">http://www.w3.org/TR/xmlschema-2/#dc-pattern</a>.
In general, you will not be interested in looking at the getSyntheticFacets
directly, getFacetContents will be of limited interest, unless you are
constructing an instance or editing one, and it's getFacets that provides
you access to the fully analysed semantic result...
<br>&nbsp;
<p>Dennis Fuglsang wrote:
<blockquote TYPE=CITE>Ed or Frank,
<p>Can you briefly explain the difference between the facets, syntheticFacets,
<br>and facetContents features with XSDSimpleTypeDefintion ?
<br>I have studied the implementation and even looked at feature values
for
<br>various sample schemas but I still do not have a clear understanding
<br>of what each is intended to hold.&nbsp; Thanks !
<p>Dennis Fuglsang</blockquote>
</html>

--------------72D6D0FC2A7100696EAA9017--
Previous Topic:XSDSimpleTypeDefinition - facets, syntheticFacets, and facetContents
Next Topic:maxLength not permitted in string
Goto Forum:
  


Current Time: Wed Jul 30 03:07:50 EDT 2014

Powered by FUDForum. Page generated in 0.01939 seconds