Hi Werner,

Thanks for the explication. It worked and I can successfully build now.

Best Regards, Ahmad

On Fri, May 22, 2009 at 7:31 PM, Werner Guttmann <werner.guttm...@gmx.net>wrote:

> Hi Ahmad,
>
> usually a 'mvn clean compile' should do the trick. Here's why:
>
> 1)
>
> 'mvn clean' cleans all Maven artefacts from the target directory, incl.
> the cache files that the Maven plugin for the Castor XML code generator
> maintains to minimize the amount of the code generation taking place
> during your builds. In other words, if your XML schemas have not
> changed, no generation will be performed.
>
> 2)
>
> 'mvn compile' will compile all available Java class files (taking from
> src/main/java) into target/classes. Before this build phase, Maven will
> trigger code generation through the Maven plugin for the Castor XML code
> generator, as a result of which new Java sources are being produced (in
> target/generated-sources/castor). As this directory is added to the
> source folders for compilation on the fly, those (generated) files will
> be compiled as well.
>
> I hope this makes things a bit clearer.
>
> Cheers
> Werner
>
> Ahmad Hassan wrote:
> > Hi Ralf,
> >
> > Thanks for the message. I ran 'mvn clean' and 'mvn install' on project
> root
> > but 'mvn install' is throwing the same error  as follows:
> >
> > [INFO]
> > ------------------------------------------------------------------------
> > [ERROR] BUILD FAILURE
> > [INFO]
> > ------------------------------------------------------------------------
> > [INFO] Compilation failure
> >
> >
> D:\ECLIPSE_PROJECTS\workspace\castor\cpa\src\main\java\org\exolab\castor\persist
> > \ClassMolder.java:[79,36] cannot find symbol
> > symbol  : class NamedNativeQuery
> > location: package org.exolab.castor.mapping.xml
> >
> > 'mvn install also cannot resolve this dependency.
> >
> > Best Regards, Ahmad
> >
> > 2009/5/22 Ralf Joachim <ralf.joac...@syscon.eu>
> >
> >> Hi Ahmad,
> >>
> >> some classes of Castor are generated during build. If one of the source
> >> files of generation (e.g. mapping.xsd) changes it may happen that new
> >> files are generated and you get compile failures until you execute build
> >> once again. org.exolab.castor.mapping.xml.NamedNativeQuery is one of
> >> those. After execution of 'mvn clean' and 'mvn install' on project root
> >> followed by a refresh of your eclipse project this errors should
> disapear.
> >>
> >> Regards
> >> Ralf
> >>
> >> Ahmad Hassan schrieb:
> >>> Hi,
> >>>
> >>> I have just downloaded the updated ClassMolder class. There has been
> >>> new dependency added in this class and because of that I am getting
> >>> import error
> >>>
> >>> import org.exolab.castor.mapping.xml.NamedNativeQuery;
> >>>
> >>> Can someone please tell me how to resolve this new dependency.
> >>>
> >>> Thanks.
> >>>
> >>> --
> >>> Best Regards, Hassan
> >>>
> >>> Erasmus Student
> >>> Current Institute: University Of Carlos III, Madrid Spain
> >>> Previous Institute: Aristotle University of Thessaloniki, Greece
> >>> Home Institute: The University of Reading, UK
> >> --
> >>
> >> Syscon Ingenieurbüro für Meß- und Datentechnik GmbH
> >> Ralf Joachim
> >> Raiffeisenstraße 11
> >> 72127 Kusterdingen
> >> Germany
> >>
> >> Tel.   +49 7071 3690 52
> >> Mobil: +49 173 9630135
> >> Fax    +49 7071 3690 98
> >>
> >> Internet: www.syscon.eu
> >> E-Mail: ralf.joac...@syscon.eu
> >>
> >> Sitz der Gesellschaft: D-72127 Kusterdingen
> >> Registereintrag: Amtsgericht Stuttgart, HRB 382295
> >> Geschäftsleitung: Jens Joachim, Ralf Joachim
> >>
> >>
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe from this list, please visit:
> >>
> >>    http://xircles.codehaus.org/manage_email
> >>
> >>
> >>
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>
>


-- 
Best Regards, Hassan

Erasmus Student
Current Institute: University Of Carlos III, Madrid Spain
Previous Institute: Aristotle University of Thessaloniki, Greece
Home Institute: The University of Reading, UK

Reply via email to