package ee.springdemo; import org.springframework.context.ApplicationContext; import org.springframework.context.support.ClassPathXmlApplicationContext; public class NewbieMain { public static void main(String[] args) { ApplicationContext context = new ClassPathXmlApplicationContext( "beans.xml"); Player noob = (Player) context.getBean("noob"); noob.setName("New Noob"); noob.beginGame(); noob.getWeapon().describe(); noob.endGame(); } }