users@jaxb.java.net

Re: Questions on JAXB2 Reflection Project

From: Kohsuke Kawaguchi <Kohsuke.Kawaguchi_at_Sun.COM>
Date: Fri, 22 Jun 2007 14:54:41 -0700

Sachith Dhanushka wrote:
> I am sorry for contacting you directly but I didn't see any mailing list for
> JAXB2 Reflections project.

Yeah, I use the JAXB lists for this project.

> I am trying to use this library for a project. But I have couple of
> questions and if you can help me to clarify them, it would be great. My
> project is to build a schema model from a given set of JAXB2 generated
> classes. I use your library to read the annotations of those JAXB2 classes
> and create a schema model. I can not use JAXB2 model as my project requires
> me to generate castor schema model. Here are the questions.
>
> 1. If I am given a set of JAXB2 annotated classes, how can I know from where
> to start? Meaning how can I find the root element? For the time being I am
> thinking of searching for all the files to search for that element which i
> donot think as an elegant method to approach the problem.

You create TypeInfoSet, and from there you can list up elements.

> 2. In the user guide posted in the site, there is a method
> RuntimePropertyInfo.getKind(). But when I am trying to use that method it is
> not available inside that class. Which method should I use instead of that?

Hmm. Which version are you using?

> I have more questions, but will get them to you once I get the answers to
> the above. Thanks for your effort and this is a great project for my work.
> Thanks again.

My pleasure.

-- 
Kohsuke Kawaguchi
Sun Microsystems                   kohsuke.kawaguchi_at_sun.com