You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commons-dev@ws.apache.org by Martin Ahrer <ma...@gmx.net> on 2006/10/17 11:01:45 UTC

XmlSchema: Support for non Standard XML Schema Attributes

I'm trying to process the following XML Schema using the Apache XMLSchema 
1.0.3 API.

<xs:simpleType name="Timestamp" basel:isdate="Yes" 
basel:dateformat="yyyy-MM-dd HH:mm:ss">
    <xs:restriction base="xs:string">
        <xs:pattern 
value="\d{4}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01]) 
([01][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9])"/>
    </xs:restriction>
</xs:simpleType>

Non-standard XMLSchema attributes (here basel:isDate, basel:dateformat 
etc.) are included in the schema definition.
Does XmlSchema provide any support for retaining this application specific 
attributes to be later read by some custom code? I haven't found any API to 
read this from the schema information returned by the XmlSchema parser.

Should information of this kind rather be modeled as annotation/appinfo - 
for which in fact is support by XmlSchema?

Thanks
  Martin

    
-- 
GMX DSL-Flatrate 0,- Euro* - Überall, wo DSL verfügbar ist!
NEU: Jetzt bis zu 16.000 kBit/s! http://www.gmx.net/de/go/dsl

Re: XmlSchema: Support for non Standard XML Schema Attributes

Posted by Davanum Srinivas <da...@gmail.com>.
Dan,

Martin already helped with a patch:
http://svn.apache.org/viewvc?view=rev&revision=467325

So he is all set. Please log a separate bug for comments and any other
issue you have.

thanks,
dims

On 10/25/06, Dan Diephouse <da...@envoisolutions.com> wrote:
> I would like to see this kind of stuff retained. Right now we lose
> comments too. :-\
>
> Can you file a JIRA issue for this? I'm not sure what the solution is
> (retain the underlying xml document?), but if you have ideas would love
> to hear them.
>
> - Dan
>
> Martin Ahrer wrote:
> > I'm trying to process the following XML Schema using the Apache XMLSchema
> > 1.0.3 API.
> >
> > <xs:simpleType name="Timestamp" basel:isdate="Yes"
> > basel:dateformat="yyyy-MM-dd HH:mm:ss">
> >     <xs:restriction base="xs:string">
> >         <xs:pattern
> > value="\d{4}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])
> > ([01][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9])"/>
> >     </xs:restriction>
> > </xs:simpleType>
> >
> > Non-standard XMLSchema attributes (here basel:isDate, basel:dateformat
> > etc.) are included in the schema definition.
> > Does XmlSchema provide any support for retaining this application specific
> > attributes to be later read by some custom code? I haven't found any API to
> > read this from the schema information returned by the XmlSchema parser.
> >
> > Should information of this kind rather be modeled as annotation/appinfo -
> > for which in fact is support by XmlSchema?
> >
> > Thanks
> >   Martin
> >
> >
> >
>
>
> --
> Dan Diephouse
> Envoi Solutions
> http://envoisolutions.com
> http://netzooid.com/blog
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: commons-dev-help@ws.apache.org
>
>


-- 
Davanum Srinivas : http://www.wso2.net (Oxygen for Web Service Developers)

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: commons-dev-help@ws.apache.org


Re: XmlSchema: Support for non Standard XML Schema Attributes

Posted by Dan Diephouse <da...@envoisolutions.com>.
I would like to see this kind of stuff retained. Right now we lose 
comments too. :-\

Can you file a JIRA issue for this? I'm not sure what the solution is 
(retain the underlying xml document?), but if you have ideas would love 
to hear them.

- Dan

Martin Ahrer wrote:
> I'm trying to process the following XML Schema using the Apache XMLSchema 
> 1.0.3 API.
>
> <xs:simpleType name="Timestamp" basel:isdate="Yes" 
> basel:dateformat="yyyy-MM-dd HH:mm:ss">
>     <xs:restriction base="xs:string">
>         <xs:pattern 
> value="\d{4}-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01]) 
> ([01][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9])"/>
>     </xs:restriction>
> </xs:simpleType>
>
> Non-standard XMLSchema attributes (here basel:isDate, basel:dateformat 
> etc.) are included in the schema definition.
> Does XmlSchema provide any support for retaining this application specific 
> attributes to be later read by some custom code? I haven't found any API to 
> read this from the schema information returned by the XmlSchema parser.
>
> Should information of this kind rather be modeled as annotation/appinfo - 
> for which in fact is support by XmlSchema?
>
> Thanks
>   Martin
>
>     
>   


-- 
Dan Diephouse
Envoi Solutions
http://envoisolutions.com
http://netzooid.com/blog


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: commons-dev-help@ws.apache.org