Hello, Thanks for answer
I made that because I want to use a sort of dependency injection in my application. Is there a simpler way to do it? Other questions: 1- How to call a DAO function from another class inside my appfuse application? I tried to instantiated the DAOHibernate class but it didn't work (NullPointerException when calling a function) 2- I my application I have two access two databases : MySql & SQL Server, how to load hibernate configuration for the second database? 3- I want to use a configuration file to store some private params. What is the best way? I am sorry for the length of my question. Regards From: mraible [via AppFuse] [mailto:ml-node+1679257-931909702-139...@n4.nabble.com] Sent: Tuesday, March 23, 2010 3:41 PM To: mlounnaci Subject: Re: applicationContext.xml not found Why do you want to do this? Why not simply inject the service you're looking for into your WebService class? On Mar 23, 2010, at 3:20 AM, mlounnaci wrote: > > > Hello friends > > I tried to use the following inside my webservice method : > > BeanFactory factory = new XmlBeanFactory(new > ClassPathResource("/WEB-INF/applicationContext.xml")); > > The exception resulted: > > .....org.springframework.beans.factory.BeanDefinitionStoreException: > IOException pars > ing XML document from class path resource [/WEB-INF/applicationContext.xml]; > nested excep > tion is java.io.FileNotFoundException: class path resource > [/WEB-INF/applicationContext.xml] cannot be opened because it does not exist > > How can i locate my applicationContext.xml file? > > Thanks for help. > -- > View this message in context: http://n4.nabble.com/applicationContext-xml-not-found-tp1678836p1678836.html > Sent from the AppFuse - User mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [hidden email] <http://n4.nabble.com/user/SendEmail.jtp?type=node&node=1679257&i=0> > For additional commands, e-mail: [hidden email] <http://n4.nabble.com/user/SendEmail.jtp?type=node&node=1679257&i=1> > --------------------------------------------------------------------- To unsubscribe, e-mail: [hidden email] <http://n4.nabble.com/user/SendEmail.jtp?type=node&node=1679257&i=2> For additional commands, e-mail: [hidden email] <http://n4.nabble.com/user/SendEmail.jtp?type=node&node=1679257&i=3> _____ View message @ http://n4.nabble.com/applicationContext-xml-not-found-tp1678836p1679257.html To start a new topic under AppFuse - User, email ml-node+547864-324903980-139...@n4.nabble.com To unsubscribe from AppFuse - User, click < (link removed) lY2hub2xvZ2llcy5kenw1NDc4NjR8LTMzMjk3MjgxMw==> here. -- View this message in context: http://n4.nabble.com/applicationContext-xml-not-found-tp1678836p1680125.html Sent from the AppFuse - User mailing list archive at Nabble.com.