solved it like this: private ContentManager contentManager;
private static String[] getConfigLocations() { return new String[] { "classpath:/applicationContext-resources.xml", "classpath:/applicationContext-dao.xml", "classpath:/applicationContext-service.xml", "classpath:/applicationContext.xml" }; } public static void main(String[] args) { ApplicationContext context = new ClassPathXmlApplicationContext(getConfigLocations()); BeanFactory factory = context; CustomerInformationReader ciReader = new CustomerInformationReader(); ciReader.setContentManager((ContentManager) factory.getBean("contentManager")); } public void setContentManager(ContentManager contentManager) { this.contentManager = contentManager; } t...@dds.nl wrote: > > Is it possible to add a main method entry point to a > struts/spring/hibernate project? > so i can make an commandline version? > > i need to read a file into the database every 24 hours and would like > to reuse all the code. > > > > thanks, > > tibi > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@appfuse.dev.java.net > For additional commands, e-mail: users-h...@appfuse.dev.java.net > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@appfuse.dev.java.net For additional commands, e-mail: users-h...@appfuse.dev.java.net