[xsd-users] Attempting to access attribute xml:base.

Jeroen N. Witmond [Bahco] jnw at xs4all.nl
Mon Sep 10 06:58:03 EDT 2007


Hi Boris,

Thanks for your hint. With it, I got my example to compile. I did not get
it to link, because of deficiencies in my code.

I have given up on this example, numbered 4 and named custom-intended, as
these deficiencies are in code that is manually copied from code that xsd
would generate. Instead I have gotten xsd to generate all required code in
a custom type, without making any changes to xsd itself. See the example
numbered 6 and named custom-anyType on my page
http://www.xs4all.nl/~jnw/codesynthesis/xmlnamespace/index.html (Note to
other readers: custom-anyType has been tested only with the prelease
3.1.0.a1 of xsd, and will not work with previous versions.)

Now the only code I have to write is the application logic. At the moment
this works for xml:base, but it should be trivial to expand this to
include the xml:id, xml:lang and xml:space attributes. Also this his been
tested only for xsd's --generate-ostream option, but again it should be
trivial to expand it to other --generate options.

Thanks,

Jeroen.

Boris Kolpackov <boris at codesynthesis.com> writes:
> Hi Jeroen,
>
> Jeroen N. Witmond [Bahco] <jnw at xs4all.nl> writes:
>
>> Unfortunately, I still get compiler errors on the generated code with
>> this
>> pre-release; see the attached file. Please let me know if you need more
>> information to solve this problem.
>
> You need to change xml_schema::type* in XmlNamespace.* to
> xml_schema::container* as is done in the comments example. After that
> change I was able to compile your example successfully.
>
> Boris
>
>





More information about the xsd-users mailing list