以下のリンクから例を実行しています。
http://chathurangat.blogspot.se/2011/12/send-email-in-spring-with-gmail.html
そして、それはうまくいきます。私の質問はなぜですか
ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("emailConfiguration.xml");
EmailSender emailSender=(EmailSender)context.getBean("emailSenderBean");
コントローラーに配置されますか?xml ファイルを読み取るためのより良い方法はありますか? Beanを作成しますか?
ClassPathXmlApplicationContext を自動配線できますか?
この例を JPA で使用するにはどうすればよいですか?
ありがとう