{"id":1865,"date":"2019-06-10T08:00:52","date_gmt":"2019-06-10T00:00:52","guid":{"rendered":"https:\/\/coderbee.net\/?p=1865"},"modified":"2019-06-09T17:19:57","modified_gmt":"2019-06-09T09:19:57","slug":"springboot-%e5%90%af%e5%8a%a8%e5%88%86%e6%9e%90%e4%b8%80","status":"publish","type":"post","link":"https:\/\/coderbee.net\/index.php\/framework\/20190610\/1865","title":{"rendered":"SpringBoot \u542f\u52a8\u5206\u6790(\u4e00)"},"content":{"rendered":"<p>SpringBoot \u542f\u52a8\u5206\u6790 \u5e8f\u5217\u6587\u7ae0\u57fa\u4e8e spring-boot-starter-parent 1.5.19.RELEASE \u3002<\/p>\n<h1>1. \u542f\u52a8\u4e00\u4e2a SpringBoot \u5e94\u7528<\/h1>\n<p>\u542f\u52a8\u4e00\u4e2a SpringBoot \u5e94\u7528\u53ea\u9700\u8981\u4e0b\u9762\u51e0\u884c\u4ee3\u7801\u5373\u53ef\uff1a<\/p>\n<pre><code class=\"java\">@SpringBootApplication\npublic class SpringBootDemoApplication {\n    public static void main(String[] args) {\n        SpringApplication.run(SpringBootDemoApplication.class, args);\n    }\n}\n<\/code><\/pre>\n<p>\u67e5\u770b <code>SpringApplication.run<\/code> \u65b9\u6cd5\u65f6\u4f1a\u6765\u5230\uff1a<\/p>\n<pre><code class=\"java\">public static ConfigurableApplicationContext run(Object source, String... args) {\n    return run(new Object[] { source }, args);\n}\n\npublic static ConfigurableApplicationContext run(Object[] sources, String[] args) {\n    return new SpringApplication(sources).run(args);\n}\n<\/code><\/pre>\n<p>\u53ef\u4ee5\u770b\u5230 SpringBoot \u7684\u9b54\u6cd5\u5c31\u662f\u90a3\u4e48\u7b80\u5355\uff1a<strong>\u521b\u5efa\u4e00\u4e2a SpringApplication\uff0c\u6267\u884c\u5176 run \u65b9\u6cd5<\/strong>\u3002<br \/>\n\u5c31\u50cf \u201c\u6253\u5f00\u51b0\u7bb1\u95e8\u3001\u628a\u5927\u8c61\u585e\u8fdb\u51b0\u7bb1\u3001\u5173\u4e0a\u51b0\u7bb1\u95e8\u201d \u90a3\u4e48\u7b80\u5355\u3001\u6709\u529b\u3002<\/p>\n<p>\u5f53\u7136\uff0c\u8981\u4e86\u89e3\u539f\u7406\u662f\u4e0d\u80fd\u53ea\u770b\u9ad8\u5c42\u62bd\u8c61\u7684\u3002<\/p>\n<h1>2. SPI \u673a\u5236 SpringFactoriesLoader<\/h1>\n<p>SpringFactoriesLoader \u662f Spring \u63d0\u4f9b\u7684 SPI \u5b9e\u73b0\u673a\u5236\uff0c\u4ece\u7c7b\u8def\u5f84\u4e0b\u7684 <code>META-INF\/spring.factories<\/code> \u6587\u4ef6\u91cc\u52a0\u8f7d\u6307\u5b9a\u63a5\u53e3\u7684\u6240\u6709\u5b9e\u73b0\u3002\u4ee5\u63a5\u53e3\u7684\u5b8c\u6574\u7c7b\u540d\u4f5c\u4e3a key\uff0c\u5b9e\u73b0\u7c7b\u7684\u5b8c\u6574\u540d\u5b57\u4f5c\u4e3a\u503c\uff0c\u591a\u4e2a\u5b9e\u73b0\u7c7b\u7528 <code>,<\/code> \u5206\u9694\u3002<\/p>\n<p>\u4e0b\u9762\u662f spring-boot-autoconfigure \u5305\u4e0b <code>META-INF\/spring.factories<\/code> \u6587\u4ef6\u91cc\u7684 \u4e00\u5c0f\u90e8\u5206\uff1a<\/p>\n<pre><code># Auto Configure\norg.springframework.boot.autoconfigure.EnableAutoConfiguration=\\\norg.springframework.boot.autoconfigure.admin.SpringApplicationAdminJmxAutoConfiguration,\\\norg.springframework.boot.autoconfigure.aop.AopAutoConfiguration,\\\norg.springframework.boot.autoconfigure.amqp.RabbitAutoConfiguration,\\\norg.springframework.boot.autoconfigure.batch.BatchAutoConfiguration,\\\norg.springframework.boot.autoconfigure.cache.CacheAutoConfiguration,\\\norg.springframework.boot.autoconfigure.cassandra.CassandraAutoConfiguration,\\\norg.springframework.boot.autoconfigure.cloud.CloudAutoConfiguration,\\\n<\/code><\/pre>\n<p>SpringFactoriesLoader \u5185\u90e8\u901a\u8fc7 <code>ClassLoader.getResources<\/code> \u65b9\u6cd5\u6765\u52a0\u8f7d\u7c7b\u8def\u5f84\u4e0b\u7684\u6587\u4ef6\u3002<\/p>\n<p><!--more--><\/p>\n<h1>3. \u4e8b\u4ef6\u4e0e\u76d1\u542c\u5668<\/h1>\n<p>SpringBoot \u5229\u7528\u4e8b\u4ef6\u4e0e\u76d1\u542c\u5668\u6765\u7b80\u5316\u542f\u52a8\u4e3b\u6d41\u7a0b\u7684\u903b\u8f91\u3002<\/p>\n<ul>\n<li>\n<p><code>SpringApplicationRunListeners<\/code>\uff1a\u6301\u6709\u4e00\u7ec4 <code>SpringApplicationRunListener<\/code> \u7684\u5f15\u7528\uff0c\u7528\u4e8e\u6279\u91cf\u901a\u77e5 <code>SpringApplicationRunListener<\/code> \u3002<\/p>\n<\/li>\n<li>\n<p><code>SpringApplicationRunListener<\/code>\uff1a\u7528\u4e8e\u76d1\u542c <code>SpringApplication<\/code>.<code>run<\/code> \u65b9\u6cd5\u7684\u6267\u884c\uff0c\u67095\u4e2a\u56de\u8c03\u65b9\u6cd5\uff1a<\/p>\n<ul>\n<li><code>started<\/code>\uff1arun\u65b9\u6cd5\u6267\u884c\u7684\u65f6\u5019\u7acb\u9a6c\u6267\u884c\uff1b\u5bf9\u5e94\u4e8b\u4ef6\u7684\u7c7b\u578b<code>\u662fApplicationStartedEvent<\/code>\u3002<\/li>\n<li><code>environmentPrepared<\/code>\uff1a<code>ApplicationContext<\/code> \u521b\u5efa\u4e4b\u524d\u5e76\u4e14\u73af\u5883\u4fe1\u606f\u51c6\u5907\u597d\u7684\u65f6\u5019\u8c03\u7528\uff1b\u5bf9\u5e94\u4e8b\u4ef6\u7684\u7c7b\u578b\u662f<code>ApplicationEnvironmentPreparedEvent<\/code>\u3002<\/li>\n<li><code>contextPrepared<\/code>\uff1a<code>ApplicationContext<\/code>\u521b\u5efa\u597d\u5e76\u4e14\u5728source\u52a0\u8f7d\u4e4b\u524d\u8c03\u7528\u4e00\u6b21\uff1b\u6ca1\u6709\u5177\u4f53\u7684\u5bf9\u5e94\u4e8b\u4ef6\u3002<\/li>\n<li><code>contextLoaded<\/code>\uff1a<code>ApplicationContext<\/code>\u521b\u5efa\u5e76\u52a0\u8f7d\u4e4b\u540e\u5e76\u5728refresh\u4e4b\u524d\u8c03\u7528\uff1b\u5bf9\u5e94\u4e8b\u4ef6\u7684\u7c7b\u578b\u662f<code>ApplicationPreparedEvent<\/code>\u3002<\/li>\n<li><code>finished<\/code>\uff1arun\u65b9\u6cd5\u7ed3\u675f\u4e4b\u524d\u8c03\u7528\uff1b\u5bf9\u5e94\u4e8b\u4ef6\u7684\u7c7b\u578b\u662f<code>ApplicationReadyEvent<\/code>\u6216<code>ApplicationFailedEvent<\/code>\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code>ApplicationListener<\/code>\uff1a\u5e94\u7528\u4e8b\u4ef6\u76d1\u542c\u5668\u3002<\/p>\n<\/li>\n<li>\n<p>\u4e8b\u4ef6\u5e7f\u64ad\u5173\u7cfb\uff1a<\/p>\n<\/li>\n<\/ul>\n<pre><code>SpringApplicationRunListeners --&gt; \nSpringApplicationRunListener(EventPublishingRunListener) --&gt;  ApplicationEventMulticaster(SimpleApplicationEventMulticaster)  --&gt;  \nApplicationListener\n<\/code><\/pre>\n<h1>4. ApplicationContext \u7684\u91cd\u8981\u7ec4\u4ef6\u53ca\u6269\u5c55\u673a\u5236\uff0c<\/h1>\n<p>\u4e0b\u9762\u662f\u4ece\u8fd0\u884c\u65f6\u7684\u89d2\u5ea6\u770bApplicationContext \u7684\u91cd\u8981\u7ec4\u4ef6\u53ca\u6269\u5c55\u673a\u5236\uff0c\u800c\u975e\u6e90\u7801\u7ec4\u7ec7\u7684\u89d2\u5ea6\u3002<\/p>\n<ul>\n<li>\n<p><code>Environment<\/code>\uff1a\u7531\u4e0b\u9762\u4e24\u4e2a\u7ec4\u6210\u3002<\/p>\n<ul>\n<li>Profiles\uff1abean\u548c\u5c5e\u6027\u7684\u903b\u8f91\u5206\u7ec4\uff0c\u4e00\u822c\u7528\u4e8e\u8868\u793a\u4e0d\u540c\u73af\u5883\u4e0b\u7684\u914d\u7f6e\u3002\u8868\u793a\u914d\u7f6e\u7684\u5206\u7ec4\u4e00\u822c\u662f\u7528\u5728\u914d\u7f6e\u6587\u4ef6\u540d\u4e0a\uff0c\u6bd4\u5982 <code>application-${profile}.properties<\/code>\uff0c\u7528\u5728 Bean \u4e0a\u4e00\u822c\u662f <code>@Profile({\"p1\", \"!p2\"})}<\/code> \u8868\u793a <code>p1<\/code> \u6fc0\u6d3b\u6216 <code>p2<\/code> \u4e0d\u6fc0\u6d3b\u65f6\u542f\u7528\u3002\u4e00\u4e2a Bean \u5982\u679c\u6ca1\u6709\u58f0\u660e profile \u5219\u8868\u793a\u9ed8\u8ba4\u662f\u6fc0\u6d3b\u7684\uff0c\u914d\u7f6e\u6587\u4ef6\u540d\u4e0a\u4e0d\u5e26 profile \u4fe1\u606f\u5219\u8868\u793a\u662f\u9ed8\u8ba4\u7684\u914d\u7f6e\u3002<\/li>\n<li>Properties\uff1a\u914d\u7f6e\u7684\u952e\u503c\u5c5e\u6027\uff0c\u53ef\u4ee5\u4ece\u5f88\u591a\u6765\u6e90\u8fdb\u884c\u521d\u59cb\u5316\u3002\u4e00\u4e2a\u914d\u7f6e\u6587\u4ef6\u7684\u952e\u503c\u5bf9\u88ab\u5c01\u88c5\u5728\u4e00\u4e2a <code>PropertySource<\/code> \u91cc\uff0c<code>PropertySources<\/code> \u6301\u6709\u4e00\u4e2a\u6216\u591a\u4e2a <code>PropertySource<\/code> \u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code>BeanFactory<\/code>\uff1aBean\u5de5\u5382\uff0c\u53ef\u4ee5\u8fdb\u884c Bean\u5b9a\u4e49\u6ce8\u518c\u3001\u5b9e\u4f8b\u5316 Bean\u3001\u5bf9\u5916\u63d0\u4f9b\u83b7\u53d6 Bean \u5b9e\u4f8b\u7684\u529f\u80fd\u3002\u4e00\u822c\u8fd8\u6301\u6709\u4e00\u4e2a\u5bf9\u7236 <code>BeanFactory<\/code> \u7684\u5f15\u7528\u3002\u5f53\u83b7\u53d6\u4e00\u4e2aBean\u65f6\uff0c\u5982\u679c\u5f53\u524d\u5de5\u5382\u4e0d\u5b58\u5728\u7ed9\u5b9aBeanName\u7684Bean\u5b9a\u4e49\uff0c\u5219\u5c1d\u8bd5\u4ece\u7236 <code>BeanFactory<\/code> \u83b7\u53d6\u3002<\/p>\n<\/li>\n<li>\n<p><code>BeanFactoryPostProcessor<\/code>\uff1a\u7528\u4e8e\u5b9a\u5236\u5316\u4fee\u6539\u4e0a\u4e0b\u6587\u5e95\u5c42 BeanFactory \u91cc\u7684 Bean \u5b9a\u4e49\u548c\u9002\u914d Bean \u5c5e\u6027\u7684\u503c\u3002\u8be5\u63a5\u53e3\u53ea\u6709\u4e00\u4e2a\u65b9\u6cd5<code>void postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) throws BeansException;<\/code>\u3002<\/p>\n<ul>\n<li><code>BeanDefinitionRegistryPostProcessor<\/code> \u7ee7\u627f\u81ea<br \/>\n<code>BeanFactoryPostProcessor<\/code>\uff0c\u5e76\u5728 <code>BeanFactoryPostProcessor<\/code> \u88ab\u5e94\u7528\u4e4b\u524d\u5148\u5e94\u7528\uff0c\u7528\u4e8e\u6ce8\u518c\u66f4\u591a\u7684 Bean\u3002\u6709\u4e00\u4e2a\u65b0\u589e\u7684\u65b9\u6cd5 <code>void postProcessBeanDefinitionRegistry(BeanDefinitionRegistry registry) throws BeansException;<\/code>\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code>BeanPostProcessor<\/code>\uff1a\u4e00\u79cd\u6269\u5c55\u673a\u5236\uff0c\u5305\u542b\u4e24\u4e2a\u65b9\u6cd5\uff0c\u7528\u4e8e\u5bf9\u521b\u5efa\u7684 Bean \u8fdb\u884c\u589e\u5f3a\uff0cAOP\u5c31\u662f\u5728\u8fd9\u4e2a\u673a\u5236\u5b9e\u73b0\u7c7b\u91cc\u5b9e\u73b0\u7684\u3002<\/p>\n<\/li>\n<\/ul>\n<pre><code>Object postProcessBeforeInitialization(Object bean, String beanName)\n`Object postProcessAfterInitialization(Object bean, String beanName)\n<\/code><\/pre>\n<ul>\n<li>\n<p><code>EnvironmentPostProcessor<\/code>\uff1a<code>Environment<\/code> \u540e\u7f6e\u5904\u7406\u5668\uff0c\u7531 <code>ConfigFileApplicationListener.onApplicationEnvironmentPreparedEvent<\/code> \u89e6\u53d1\u6267\u884c\uff0c\u5177\u4f53\u7684\u5b9e\u73b0\u7c7b\u6709\uff1a<\/p>\n<ul>\n<li>CloudFoundryVcapEnvironmentPostProcessor<\/li>\n<li>ConfigFileApplicationListener\uff1a\u7528\u4e8e\u52a0\u8f7d PropertySources\uff0c\u8d44\u6e90\u3002<\/li>\n<li>HostInfoEnvironmentPostProcessor<\/li>\n<li>ServoEnvironmentPostProcessor<\/li>\n<li>SpringApplicationJsonEnvironmentPostProcessor<\/li>\n<\/ul>\n<\/li>\n<li>\n<p>\u540c\u4e00\u7c7b\u7ec4\u4ef6\u7684\u4e0d\u540c\u5b9e\u73b0\u7684\u6267\u884c\u987a\u5e8f\u662f\u6709\u4e00\u5b9a\u89c4\u5219\u7684<\/p>\n<ul>\n<li>A. \u4e0d\u540c\u7ec4\u4ef6\u7684\u5b9e\u73b0\u6709\u5982\u4e0b\u4e09\u7c7b\u5206\u7c7b<\/li>\n<li>\n<ul>\n<li>\u5b9e\u73b0 PriorityOrdered \u63a5\u53e3<\/li>\n<\/ul>\n<\/li>\n<li>\n<ul>\n<li>\u5b9e\u73b0 Ordered \u63a5\u53e3<\/li>\n<\/ul>\n<\/li>\n<li>\n<ul>\n<li>\u975e\u7ee7\u627f\u4e0a\u8ff0\u4e24\u4e2a\u63a5\u53e3\u7684<\/li>\n<\/ul>\n<\/li>\n<li>B. \u6267\u884c\u987a\u5e8f\u89c4\u5219<\/li>\n<li>\n<ul>\n<li>PriorityOrdered -> Ordered -> \u975e\u7ee7\u627f\u4e0a\u8ff0\u63a5\u53e3\u7684<\/li>\n<\/ul>\n<\/li>\n<li>\n<ul>\n<li>\u540c\u4e00\u7c7b\u5b9e\u73b0\u7684 order \u503c\u8d8a\u4f4e\u4f18\u5148\u7ea7\u8d8a\u9ad8<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code>ConfigurationClassParser<\/code>\uff1a\u5b83\u7684 <code>processConfigurationClass<\/code> \u65b9\u6cd5\u9012\u5f52\u5730\u89e3\u6790 <code>@Configuration<\/code> \u914d\u7f6e\u7c7b\uff0cSpringBoot \u7684 auto-configure \u673a\u5236\u5c31\u662f\u5728\u8fd9\u4e2a\u9636\u6bb5\u88ab\u89e3\u6790\u5230\u4e0a\u4e0b\u6587\u91cc\u7684\u3002<\/p>\n<ul>\n<li>\u9012\u5f52\u5904\u7406\u6240\u6709\u5d4c\u5957\u7c7b<\/li>\n<li>\u5904\u7406\u6e90\u7c7b\u4e0a <code>@PropertySource<\/code> \u6ce8\u89e3\u6307\u5b9a\u7684\u914d\u7f6e\u6587\u4ef6<\/li>\n<li>\u5904\u7406 <code>@ComponentScan<\/code> \u6ce8\u89e3<\/li>\n<li>\u5904\u7406 <code>@Import<\/code> \u6ce8\u89e3<\/li>\n<li>\u5904\u7406 <code>@ImportResource<\/code> \u6ce8\u89e3<\/li>\n<li>\u5904\u7406\u6240\u6709 <code>@Bean<\/code> \u65b9\u6cd5<\/li>\n<li>\u5904\u7406 interfaces \u4e0a\u7684\u9ed8\u8ba4\u65b9\u6cd5<\/li>\n<li>\u9012\u5f52\u5904\u7406\u7236\u7c7b<\/li>\n<\/ul>\n<\/li>\n<li>\n<p><code>ConfigurationClassBeanDefinitionReader<\/code>\uff1a\u628a <code>ConfigurationClassParser<\/code> \u89e3\u6790\u5f97\u5230\u7684 Bean \u5b9a\u4e49 \u6ce8\u518c\u5230 <code>BeanDefinitionRegistry<\/code> \u3002<\/p>\n<\/li>\n<li>\n<p><code>ConfigurationClassPostProcessor<\/code>\uff1a\u501f\u52a9 <code>ConfigurationClassParser<\/code> \u548c <code>ConfigurationClassParser<\/code> \u9012\u5f52\u5730\u89e3\u6790\u914d\u7f6e\u7c7b\u5e76\u6ce8\u518c\u5230 <code>BeanDefinitionRegistry<\/code> \u3002<\/p>\n<\/li>\n<li>\n<p><code>ConditionEvaluator<\/code>\uff1a\u6839\u636e <code>@Conditional<\/code> \u6ce8\u89e3\u8fdb\u884c\u8bc4\u4f30\u4e00\u4e2a Bean \u5b9a\u4e49\u662f\u5426\u5e94\u8be5\u6ce8\u518c\u3002<\/p>\n<\/li>\n<\/ul>\n<h1>5. SpringBoot \u542f\u52a8\u6d41\u7a0b\u6982\u8981<\/h1>\n<ol>\n<li>\u521b\u5efa\u4e00\u4e2a <code>ConfigurableEnvironment<\/code>\uff0c\u5e7f\u64ad <code>ApplicationEnvironmentPreparedEvent<\/code> \u4e8b\u4ef6\uff0c<code>ConfigFileApplicationListener<\/code> \u6536\u5230\u901a\u77e5\u540e\u5229\u7528 SPI \u673a\u5236\u52a0\u8f7d\u6240\u6709 <code>EnvironmentPostProcessor<\/code> \u7684\u5b9e\u73b0\u7c7b\uff0c\u89e6\u53d1\u5176 <code>postProcessEnvironment<\/code> \u65b9\u6cd5\u3002<code>ConfigFileApplicationListener<\/code> \u81ea\u8eab\u4e5f\u5b9e\u73b0\u4e86 <code>EnvironmentPostProcessor<\/code> \u63a5\u53e3\uff0c\u5728\u5b83\u7684 <code>postProcessEnvironment<\/code> \u91cc\u901a\u8fc7\u5185\u90e8\u7c7b Loader \u52a0\u8f7d\u6240\u6709\u7684\u914d\u7f6e\u6587\u4ef6\uff0c\u5e76\u5904\u7406 profile\uff0c\u6700\u7ec8\u6240\u6709\u952e\u503c\u5bf9\u90fd\u88ab\u6dfb\u52a0\u5230 Environment \u91cc\u3002<\/li>\n<li>\u5b9e\u4f8b\u5316\u4e00\u4e2a <code>AnnotationConfigApplicationContext<\/code>\uff0c\u5b9e\u4f8b\u5316\u7684\u8fc7\u7a0b\u4e2d\u4f1a\u628a \u5e94\u7528\u6307\u5b9a\u7684\u542f\u52a8\u914d\u7f6e\u7c7b\u3001 <code>ConfigurationClassPostProcessor<\/code> \u5b9e\u4f8b\u6ce8\u518c\u5230\u5e95\u5c42\u7684 BeanFacotry \u5b9e\u4f8b\u91cc\u3002<\/li>\n<li>\u4e0a\u4e0b\u6587 refresh \u8fc7\u7a0b\u4f1a\u89e6\u53d1\u6267\u884c <code>ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry<\/code> \u6ce8\u518c\u6240\u6709\u7684 Bean \u5b9a\u4e49\u3002<\/li>\n<li>\u627e\u51fa\u4e0a\u4e0b\u6587\u91cc\u6240\u6709\u975e\u5ef6\u8fdf\u52a0\u8f7d\u7684\u5355\u4f8b\u7684 BeanName\uff0c\u9010\u4e2a\u5b9e\u4f8b\u5316\uff0c\u5b9e\u4f8b\u5316\u8fc7\u7a0b\u4e2d\u5e94\u7528 <code>BeanPostProcessor<\/code> \u8fdb\u884c\u52a0\u5de5\u589e\u5f3a\uff0c\u5f97\u5230\u6700\u7ec8\u7684 Bean object \u7ed9\u5e94\u7528\u4f7f\u7528\u3002<\/li>\n<\/ol>\n<hr \/>\n<p>\u6b22\u8fce\u5173\u6ce8\u6211\u7684\u5fae\u4fe1\u516c\u4f17\u53f7: <strong>coderbee\u7b14\u8bb0<\/strong>\uff0c\u53ef\u4ee5\u66f4\u53ca\u65f6\u56de\u590d\u4f60\u7684\u8ba8\u8bba\u3002<br \/>\n<img loading=\"lazy\" decoding=\"async\" width=\"258\" height=\"258\" src=\"https:\/\/coderbee.net\/wp-content\/uploads\/2019\/01\/coderbee-note.jpg\" class=\"alignnone size-full wp-image-1707\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>SpringBoot \u542f\u52a8\u5206\u6790 \u5e8f\u5217\u6587\u7ae0\u57fa\u4e8e spring-boot-start &hellip; <a href=\"https:\/\/coderbee.net\/index.php\/framework\/20190610\/1865\">\u7ee7\u7eed\u9605\u8bfb <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[255],"tags":[172,308],"_links":{"self":[{"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/posts\/1865"}],"collection":[{"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/comments?post=1865"}],"version-history":[{"count":15,"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/posts\/1865\/revisions"}],"predecessor-version":[{"id":1880,"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/posts\/1865\/revisions\/1880"}],"wp:attachment":[{"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/media?parent=1865"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/categories?post=1865"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/coderbee.net\/index.php\/wp-json\/wp\/v2\/tags?post=1865"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}