Hi Bill, You can try to implement your own ClassDescriptorResolver to specify where to look for your classes. For the performance comparing the mapping and the introspector, I would say that the mapping is preferable since it prevents to use the full introspection mode and as you know java reflection takes a lot of time. IMO (note that I never tested it), the performance diagram should look like
Hard-coded descriptors (Source generator for instance) < Mapping < Introspection. Dennis Sosnosky is currently working on performance testing on Castor and I am sure he will be glad to share his work once his work is done. Hope that helps, Arnaud > -----Original Message----- > From: Bill Marcum [mailto:bmarcum@;raindance.com] > Sent: Wednesday, November 13, 2002 5:14 PM > To: [EMAIL PROTECTED] > Subject: [castor-dev] xml mapping > > I'm experimenting with the xml mapping functionality, and I have a couple > questions: > 1) If I don't supply a complete mapping, the unmarshaller is unable to > resolve some classes. According to the documentation: > "If no mapping information is present, Castor will use the name of the > element to try to guess the name of a class to instantiate (for example, for > an element named 'test-element', Castor will try to instantiate a class > named 'TestElement' if no information is given in the mapping file). Castor > will then use the field information of the mapping file to handle the > content of the element." > so, I was hoping the unmarshaller would be able to resolve these other > classes. I'm guessing it's unable to do so because my generated classes are > in a package, and the unmarshaller doesn't know what package to use. Is > there any way to tell the unmarshaller what package name to prepend to the > classname? > 2) What are the performance implications of explicitly specifying all the > class mapping information, vs. letting the unmarshaller dynamically resolve > the classes? > > ----------------------------------------------------------- > If you wish to unsubscribe from this mailing, send mail to > [EMAIL PROTECTED] with a subject of: > unsubscribe castor-dev ----------------------------------------------------------- If you wish to unsubscribe from this mailing, send mail to [EMAIL PROTECTED] with a subject of: unsubscribe castor-dev
