spring中bean的創建

bean對象創建的細節  1) 對象創建: 單例/多例   scope="singleton", 默認值, 即 默認是單例【service/dao/工具類】    scope="prototype", 多例; 【Action對象】     2) 什麼時候創建?   scope="prototype"  在用到對象的時候,才創建對象。   scope="singleton"  在啓動(容器初始化之前
相關文章
相關標籤/搜索