{"id":209,"date":"2021-04-27T10:37:37","date_gmt":"2021-04-27T02:37:37","guid":{"rendered":"http:\/\/112.124.66.68\/?p=209"},"modified":"2021-04-27T10:37:37","modified_gmt":"2021-04-27T02:37:37","slug":"spring%e4%be%9d%e8%b5%96%e6%b3%a8%e5%85%a5%e7%9a%84%e6%96%b9%e5%bc%8f%e6%9c%89%e5%87%a0%e7%a7%8d%ef%bc%8c%e5%90%84%e6%98%af%e4%bb%80%e4%b9%88","status":"publish","type":"post","link":"https:\/\/sanlangcode.com\/index.php\/2021\/04\/27\/spring%e4%be%9d%e8%b5%96%e6%b3%a8%e5%85%a5%e7%9a%84%e6%96%b9%e5%bc%8f%e6%9c%89%e5%87%a0%e7%a7%8d%ef%bc%8c%e5%90%84%e6%98%af%e4%bb%80%e4%b9%88\/","title":{"rendered":"spring\u4f9d\u8d56\u6ce8\u5165\u7684\u65b9\u5f0f\u6709\u51e0\u79cd\uff0c\u5404\u662f\u4ec0\u4e48?"},"content":{"rendered":"\n<p> \u4e00\u3001\u6784\u9020\u5668\u6ce8\u5165<br>\u5c06\u88ab\u4f9d\u8d56\u5bf9\u8c61\u901a\u8fc7\u6784\u9020\u51fd\u6570\u7684\u53c2\u6570\u6ce8\u5165\u7ed9\u4f9d\u8d56\u5bf9\u8c61\uff0c\u5e76\u4e14\u5728\u521d\u59cb\u5316\u5bf9\u8c61\u7684\u65f6\u5019\u6ce8\u5165\u3002<br>\u4f18\u70b9\uff1a<br>\u5bf9\u8c61\u521d\u59cb\u5316\u5b8c\u6210\u540e\u4fbf\u53ef\u83b7\u5f97\u53ef\u4f7f\u7528\u7684\u5bf9\u8c61\u3002<br>\u7f3a\u70b9\uff1a<br>\u5f53\u9700\u8981\u6ce8\u5165\u7684\u5bf9\u8c61\u5f88\u591a\u65f6\uff0c\u6784\u9020\u5668\u53c2\u6570\u5217\u8868\u5c06\u4f1a\u5f88\u957f\uff1b<br>\u4e0d\u591f\u7075\u6d3b\u3002\u82e5\u6709\u591a\u79cd\u6ce8\u5165\u65b9\u5f0f\uff0c\u6bcf\u79cd\u65b9\u5f0f\u53ea\u9700\u6ce8\u5165\u6307\u5b9a\u51e0\u4e2a\u4f9d\u8d56\uff0c\u90a3\u4e48\u5c31\u9700\u8981\u63d0\u4f9b\u591a\u4e2a\u91cd\u8f7d\u7684\u6784\u9020\u51fd<br>\u6570\uff0c\u9ebb\u70e6\u3002<br>\u4e8c\u3001setter\u65b9\u6cd5\u6ce8\u5165<br>IoC Service Provider\u901a\u8fc7\u8c03\u7528\u6210\u5458\u53d8\u91cf\u63d0\u4f9b\u7684setter\u51fd\u6570\u5c06\u88ab\u4f9d\u8d56\u5bf9\u8c61\u6ce8\u5165\u7ed9\u4f9d\u8d56\u7c7b\u3002<br>\u4f18\u70b9\uff1a<br>\u7075\u6d3b\u3002\u53ef\u4ee5\u9009\u62e9\u6027\u5730\u6ce8\u5165\u9700\u8981\u7684\u5bf9\u8c61\u3002<br>\u7f3a\u70b9\uff1a<br>\u4f9d\u8d56\u5bf9\u8c61\u521d\u59cb\u5316\u5b8c\u6210\u540e\u7531\u4e8e\u5c1a\u672a\u6ce8\u5165\u88ab\u4f9d\u8d56\u5bf9\u8c61\uff0c\u56e0\u6b64\u8fd8\u4e0d\u80fd\u4f7f\u7528\u3002<br>\u4e09\u3001\u63a5\u53e3\u6ce8\u5165<br>\u4f9d\u8d56\u7c7b\u5fc5\u987b\u8981\u5b9e\u73b0\u6307\u5b9a\u7684\u63a5\u53e3\uff0c\u7136\u540e\u5b9e\u73b0\u8be5\u63a5\u53e3\u4e2d\u7684\u4e00\u4e2a\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u5c31\u662f\u7528\u4e8e\u4f9d\u8d56\u6ce8\u5165\u3002\u8be5\u51fd\u6570\u7684\u53c2<br>\u6570\u5c31\u662f\u8981\u6ce8\u5165\u7684\u5bf9\u8c61\u3002<br>\u4f18\u70b9<br>\u63a5\u53e3\u6ce8\u5165\u4e2d\uff0c\u63a5\u53e3\u7684\u540d\u5b57\u3001\u51fd\u6570\u7684\u540d\u5b57\u90fd\u4e0d\u91cd\u8981\uff0c\u53ea\u8981\u4fdd\u8bc1\u51fd\u6570\u7684\u53c2\u6570\u662f\u8981\u6ce8\u5165\u7684\u5bf9\u8c61\u7c7b\u578b\u5373\u53ef\u3002<br>\u7f3a\u70b9\uff1a<br>\u4fb5\u5165\u884c\u592a\u5f3a\uff0c\u4e0d\u5efa\u8bae\u4f7f\u7528\u3002<br><span class=\"has-inline-color has-luminous-vivid-orange-color\">PS\uff1a\u4ec0\u4e48\u662f\u4fb5\u5165\u884c\uff1f<\/span><br>\u5982\u679c\u7c7bA\u8981\u4f7f\u7528\u522b\u4eba\u63d0\u4f9b\u7684\u4e00\u4e2a\u529f\u80fd\uff0c\u82e5\u4e3a\u4e86\u4f7f\u7528\u8fd9\u529f\u80fd\uff0c\u9700\u8981\u5728\u81ea\u5df1\u7684\u7c7b\u4e2d\u589e\u52a0\u989d\u5916\u7684\u4ee3\u7801\uff0c\u8fd9\u5c31\u662f<br>\u4fb5\u5165\u6027<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4e00\u3001\u6784\u9020\u5668\u6ce8\u5165\u5c06\u88ab\u4f9d\u8d56\u5bf9\u8c61\u901a\u8fc7\u6784&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":206,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[10],"tags":[],"class_list":["post-209","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-spring"],"_links":{"self":[{"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/posts\/209","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/comments?post=209"}],"version-history":[{"count":0,"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/posts\/209\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/media\/206"}],"wp:attachment":[{"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/media?parent=209"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/categories?post=209"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sanlangcode.com\/index.php\/wp-json\/wp\/v2\/tags?post=209"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}