Spring 框架中都用到的設計模式

Spring框架中使用到了大量的設計模式,下面列舉了比較有表明性的:spring 代理模式—在AOP和remoting中被用的比較多。 單例模式—在spring配置文件中定義的bean默認爲單例模式。 模板方法—用來解決代碼重複的問題。好比. RestTemplate, JmsTemplate, JpaTemplate。 工廠模式—BeanFactory用來建立對象的實例。 適配器--spring
相關文章
相關標籤/搜索