{"id":10008254,"date":"2023-09-08T15:58:44","date_gmt":"2023-09-08T07:58:44","guid":{"rendered":"https:\/\/blog.itmax.cn\/?p=10008254"},"modified":"2023-09-08T15:58:44","modified_gmt":"2023-09-08T07:58:44","slug":"%e4%b8%ba%e4%bb%80%e4%b9%88-list-sort-%e6%af%94-stream-sorted-%e8%a6%81%e6%9b%b4%e5%bf%ab%ef%bc%9f%e6%b5%8b%e8%af%95%e7%bb%93%e6%9e%9c%e6%8a%8a%e6%88%91%e6%83%8a%e5%91%86%e4%ba%86%ef%bc%81","status":"publish","type":"post","link":"https:\/\/itmax.cn\/?p=10008254","title":{"rendered":"\u4e3a\u4ec0\u4e48 list.sort() \u6bd4 stream().sorted() \u8981\u66f4\u5feb\uff1f\u6d4b\u8bd5\u7ed3\u679c\u628a\u6211\u60ca\u5446\u4e86\uff01"},"content":{"rendered":"<p>\u4f5c\u8005\uff1a\u662f\u5949\u58f9\u5440 \/<br \/>\u6765\u6e90\uff1ajuejin.cn\/post\/7262274383287500860<\/p>\n<p>\u770b\u5230\u4e00\u4e2a\u8bc4\u8bba\uff0c\u91cc\u9762\u63d0\u5230\u4e86list.sort()\u548clist.strem().sorted()\u6392\u5e8f\u7684\u5dee\u5f02\u3002<\/p>\n<p>\u8bf4\u5230list sort()\u6392\u5e8f\u6bd4stream().sorted()\u6392\u5e8f\u6027\u80fd\u66f4\u597d\uff0c\u4f46\u6ca1\u8bf4\u5230\u4e3a\u4ec0\u4e48\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"707\" height=\"140\" referrerpolicy=\"no-referrer\" src=\"https:\/\/segmentfault.com\/img\/bVc9Bxv\" alt=\"\" title=\"\"><\/p>\n<p>\u6709\u670b\u53cb\u4e5f\u63d0\u5230\u4e86\u8fd9\u4e00\u70b9\u3002\u672c\u6587\u91cd\u65b0\u5f00\u59cb\uff0c\u5148\u95ee\u662f\u4e0d\u662f\uff0c\u518d\u95ee\u4e3a\u4ec0\u4e48\u3002<\/p>\n<p>\u63a8\u8350\u4e00\u4e2a\u5f00\u6e90\u514d\u8d39\u7684 Spring Boot \u5b9e\u6218\u9879\u76ee\uff1a<\/p>\n<blockquote><p><a target=\"_blank\" href=\"https:\/\/link.segmentfault.com\/?enc=7ZvfITRWQbOpNwCuEFIbvQ%3D%3D.hQ4ik67QHQre7v%2FfdF8pthc%2ByWxUrntAqmIFzVCvIPXWXpT1D7uJGbs0BTFHmvhcbo9T1Z0wVdE60riYgQmUoQ%3D%3D\" rel=\"noopener noreferrer\">https:\/\/github.com\/javastacks\/spring-boot-best-practice<\/a><\/p><\/blockquote>\n<h2>\u771f\u7684\u66f4\u597d\u5417\uff1f<\/h2>\n<p>\u5148\u7b80\u5355\u5199\u4e2ademo<\/p>\n<pre><code>List&lt;Integer&gt; userList = new ArrayList&lt;&gt;();\n        Random rand = new Random();\n        for (int i = 0; i &lt; 10000 ; i++) {\n            userList.add(rand.nextInt(1000));\n        }\n        List&lt;Integer&gt; userList2 = new ArrayList&lt;&gt;();\n        userList2.addAll(userList);\n\n        Long startTime1 = System.currentTimeMillis();\n        userList2.stream().sorted(Comparator.comparing(Integer::intValue)).collect(Collectors.toList());\n        System.out.println(&quot;stream.sort\u8017\u65f6\uff1a&quot;+(System.currentTimeMillis() - startTime1)+&quot;ms&quot;);\n\n        Long startTime = System.currentTimeMillis();\n        userList.sort(Comparator.comparing(Integer::intValue));\n        System.out.println(&quot;List.sort()\u8017\u65f6\uff1a&quot;+(System.currentTimeMillis()-startTime)+&quot;ms&quot;);<\/code><\/pre>\n<p>\u8f93\u51fa<\/p>\n<pre><code>stream.sort\u8017\u65f6\uff1a62ms\nList.sort()\u8017\u65f6\uff1a7ms<\/code><\/pre>\n<p>\u7531\u6b64\u53ef\u89c1list\u539f\u751f\u6392\u5e8f\u6027\u80fd\u66f4\u597d\u3002<\/p>\n<p>\u80fd\u8bc1\u660e\u5417\uff1f<\/p>\n<p>\u8bc1\u636e\u9519\u4e86\u3002<\/p>\n<p>\u518d\u628ademo\u53d8\u6362\u4e00\u4e0b\uff0c\u5148\u8f93\u51fastream.sort<\/p>\n<pre><code>List&lt;Integer&gt; userList = new ArrayList&lt;&gt;();\n        Random rand = new Random();\n        for (int i = 0; i &lt; 10000 ; i++) {\n            userList.add(rand.nextInt(1000));\n        }\n        List&lt;Integer&gt; userList2 = new ArrayList&lt;&gt;();\n        userList2.addAll(userList);\n\n        Long startTime = System.currentTimeMillis();\n        userList.sort(Comparator.comparing(Integer::intValue));\n        System.out.println(&quot;List.sort()\u8017\u65f6\uff1a&quot;+(System.currentTimeMillis()-startTime)+&quot;ms&quot;);\n\n        Long startTime1 = System.currentTimeMillis();\n        userList2.stream().sorted(Comparator.comparing(Integer::intValue)).collect(Collectors.toList());\n        System.out.println(&quot;stream.sort\u8017\u65f6\uff1a&quot;+(System.currentTimeMillis() - startTime1)+&quot;ms&quot;);<\/code><\/pre>\n<p>\u6b64\u65f6\u8f93\u51fa\u53d8\u6210\u4e86<\/p>\n<pre><code>List.sort()\u8017\u65f6\uff1a68ms\nstream.sort\u8017\u65f6\uff1a13ms<\/code><\/pre>\n<p>\u8fd9\u80fd\u8bc1\u660e\u4e0a\u9762\u7684\u7ed3\u8bba\u9519\u8bef\u4e86\u5417\uff1f<\/p>\n<p>\u90fd\u4e0d\u80fd\u3002<\/p>\n<p>\u4e24\u79cd\u65b9\u5f0f\u90fd\u4e0d\u80fd\u8bc1\u660e\u4ec0\u4e48\u3002<\/p>\n<p>\u4f7f\u7528\u8fd9\u79cd\u65b9\u5f0f\u5728\u5f88\u591a\u573a\u666f\u4e0b\u662f\u4e0d\u591f\u7684\uff0c\u67d0\u4e9b\u573a\u666f\u4e0b\uff0cJVM\u4f1a\u5bf9\u4ee3\u7801\u8fdb\u884cJIT\u7f16\u8bd1\u548c\u5185\u8054\u4f18\u5316\u3002<\/p>\n<pre><code>Long startTime = System.currentTimeMillis();\n...\nSystem.currentTimeMillis() - startTime<\/code><\/pre>\n<p>\u6b64\u65f6\uff0c\u4ee3\u7801\u4f18\u5316\u524d\u540e\u6267\u884c\u7684\u7ed3\u679c\u5c31\u4f1a\u975e\u5e38\u5927\u3002<\/p>\n<pre><code>\u57fa\u51c6\u6d4b\u8bd5\u662f\u6307\u901a\u8fc7\u8bbe\u8ba1\u79d1\u5b66\u7684\u6d4b\u8bd5\u65b9\u6cd5\u3001\u6d4b\u8bd5\u5de5\u5177\u548c\u6d4b\u8bd5\u7cfb\u7edf\uff0c\u5b9e\u73b0\u5bf9\u4e00\u7c7b\u6d4b\u8bd5\u5bf9\u8c61\u7684\u67d0\u9879\u6027\u80fd\u6307\u6807\u8fdb\u884c\u5b9a\u91cf\u7684\u548c\u53ef\u5bf9\u6bd4\u7684\u6d4b\u8bd5\u3002<\/code><\/pre>\n<p>\u57fa\u51c6\u6d4b\u8bd5\u4f7f\u5f97\u88ab\u6d4b\u8bd5\u4ee3\u7801\u83b7\u5f97\u8db3\u591f\u9884\u70ed\uff0c\u8ba9\u88ab\u6d4b\u8bd5\u4ee3\u7801\u5f97\u5230\u5145\u5206\u7684JIT\u7f16\u8bd1\u548c\u4f18\u5316\u3002<\/p>\n<p>\u4e0b\u9762\u662f\u901a\u8fc7JMH\u505a\u4e00\u4e0b\u57fa\u51c6\u6d4b\u8bd5,\u5206\u522b\u6d4b\u8bd5\u96c6\u5408\u5927\u5c0f\u5728100\uff0c10000\uff0c100000\u65f6\u4e24\u79cd\u6392\u5e8f\u65b9\u5f0f\u7684\u6027\u80fd\u5dee\u5f02\u3002<\/p>\n<pre><code>import org.openjdk.jmh.annotations.*;\nimport org.openjdk.jmh.infra.Blackhole;\nimport org.openjdk.jmh.results.format.ResultFormatType;\nimport org.openjdk.jmh.runner.Runner;\nimport org.openjdk.jmh.runner.RunnerException;\nimport org.openjdk.jmh.runner.options.Options;\nimport org.openjdk.jmh.runner.options.OptionsBuilder;\n\nimport java.util.*;\nimport java.util.concurrent.ThreadLocalRandom;\nimport java.util.concurrent.TimeUnit;\nimport java.util.stream.Collectors;\n\n@BenchmarkMode(Mode.AverageTime)\n@OutputTimeUnit(TimeUnit.MICROSECONDS)\n@Warmup(iterations = 2, time = 1)\n@Measurement(iterations = 5, time = 5)\n@Fork(1)\n@State(Scope.Thread)\npublic class SortBenchmark {\n\n    @Param(value = {&quot;100&quot;, &quot;10000&quot;, &quot;100000&quot;})\n    private int operationSize;\n    private static List&lt;Integer&gt; arrayList;\n\n    public static void main(String[] args) throws RunnerException {\n        \/\/ \u542f\u52a8\u57fa\u51c6\u6d4b\u8bd5\n        Options opt = new OptionsBuilder()\n                .include(SortBenchmark.class.getSimpleName())\n                .result(&quot;SortBenchmark.json&quot;)\n                .mode(Mode.All)\n                .resultFormat(ResultFormatType.JSON)\n                .build();\n        new Runner(opt).run();\n    }\n\n    @Setup\n    public void init() {\n        arrayList = new ArrayList&lt;&gt;();\n        Random random = new Random();\n        for (int i = 0; i &lt; operationSize; i++) {\n            arrayList.add(random.nextInt(10000));\n        }\n    }\n    @Benchmark\n    public void sort(Blackhole blackhole) {\n        arrayList.sort(Comparator.comparing(e -&gt; e));\n        blackhole.consume(arrayList);\n    }\n\n    @Benchmark\n    public void streamSorted(Blackhole blackhole) {\n        arrayList = arrayList.stream().sorted(Comparator.comparing(e -&gt; e)).collect(Collectors.toList());\n        blackhole.consume(arrayList);\n    }\n\n}<\/code><\/pre>\n<p>\u6027\u80fd\u6d4b\u8bd5\u7ed3\u679c\uff1a<\/p>\n<p><img decoding=\"async\" width=\"723\" height=\"462\" referrerpolicy=\"no-referrer\" src=\"https:\/\/segmentfault.com\/img\/bVc9Bxw\" alt=\"\" title=\"\" loading=\"lazy\"><\/p>\n<p>\u53ef\u4ee5\u770b\u5230\uff0clist sort()\u6548\u7387\u786e\u5b9e\u6bd4stream().sorted()\u8981\u597d\u3002<\/p>\n<h2>\u4e3a\u4ec0\u4e48\u66f4\u597d\uff1f<\/h2>\n<h4>\u6d41\u672c\u8eab\u7684\u635f\u8017<\/h4>\n<p>java\u7684stream\u8ba9\u6211\u4eec\u53ef\u4ee5\u5728\u5e94\u7528\u5c42\u5c31\u53ef\u4ee5\u9ad8\u6548\u5730\u5b9e\u73b0\u7c7b\u4f3c\u6570\u636e\u5e93SQL\u7684\u805a\u5408\u64cd\u4f5c\u4e86\uff0c\u5b83\u53ef\u4ee5\u8ba9\u4ee3\u7801\u66f4\u52a0\u7b80\u6d01\u4f18\u96c5\u3002<\/p>\n<p>\u4f46\u662f\uff0c\u5047\u8bbe\u6211\u4eec\u8981\u5bf9\u4e00\u4e2alist\u6392\u5e8f\uff0c\u5f97\u5148\u628alist\u8f6c\u6210stream\u6d41\uff0c\u6392\u5e8f\u5b8c\u6210\u540e\u9700\u8981\u5c06\u6570\u636e\u6536\u96c6\u8d77\u6765\u91cd\u65b0\u5f62\u6210list\uff0c\u8fd9\u90e8\u4efd\u989d\u5916\u7684\u5f00\u9500\u6709\u591a\u5927\u5462\uff1f<\/p>\n<p>\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u4ee3\u7801\u6765\u8fdb\u884c\u57fa\u51c6\u6d4b\u8bd5<\/p>\n<pre><code>import org.openjdk.jmh.annotations.*;\nimport org.openjdk.jmh.infra.Blackhole;\nimport org.openjdk.jmh.results.format.ResultFormatType;\nimport org.openjdk.jmh.runner.Runner;\nimport org.openjdk.jmh.runner.RunnerException;\nimport org.openjdk.jmh.runner.options.Options;\nimport org.openjdk.jmh.runner.options.OptionsBuilder;\n\nimport java.util.ArrayList;\nimport java.util.Comparator;\nimport java.util.List;\nimport java.util.Random;\nimport java.util.concurrent.TimeUnit;\nimport java.util.stream.Collectors;\n\n@BenchmarkMode(Mode.AverageTime)\n@OutputTimeUnit(TimeUnit.MICROSECONDS)\n@Warmup(iterations = 2, time = 1)\n@Measurement(iterations = 5, time = 5)\n@Fork(1)\n@State(Scope.Thread)\npublic class SortBenchmark3 {\n\n    @Param(value = {&quot;100&quot;, &quot;10000&quot;})\n    private int operationSize; \/\/ \u64cd\u4f5c\u6b21\u6570\n    private static List&lt;Integer&gt; arrayList;\n\n    public static void main(String[] args) throws RunnerException {\n        \/\/ \u542f\u52a8\u57fa\u51c6\u6d4b\u8bd5\n        Options opt = new OptionsBuilder()\n                .include(SortBenchmark3.class.getSimpleName()) \/\/ \u8981\u5bfc\u5165\u7684\u6d4b\u8bd5\u7c7b\n                .result(&quot;SortBenchmark3.json&quot;)\n                .mode(Mode.All)\n                .resultFormat(ResultFormatType.JSON)\n                .build();\n        new Runner(opt).run(); \/\/ \u6267\u884c\u6d4b\u8bd5\n    }\n\n    @Setup\n    public void init() {\n        \/\/ \u542f\u52a8\u6267\u884c\u4e8b\u4ef6\n        arrayList = new ArrayList&lt;&gt;();\n        Random random = new Random();\n        for (int i = 0; i &lt; operationSize; i++) {\n            arrayList.add(random.nextInt(10000));\n        }\n    }\n\n    @Benchmark\n    public void stream(Blackhole blackhole) {\n        arrayList.stream().collect(Collectors.toList());\n        blackhole.consume(arrayList);\n    }\n\n    @Benchmark\n    public void sort(Blackhole blackhole) {\n        arrayList.stream().sorted(Comparator.comparing(Integer::intValue)).collect(Collectors.toList());\n        blackhole.consume(arrayList);\n    }\n\n}<\/code><\/pre>\n<p>\u65b9\u6cd5stream\u6d4b\u8bd5\u5c06\u4e00\u4e2a\u96c6\u5408\u8f6c\u4e3a\u6d41\u518d\u6536\u96c6\u56de\u6765\u7684\u8017\u65f6\u3002<\/p>\n<p>\u65b9\u6cd5sort\u6d4b\u8bd5\u5c06\u4e00\u4e2a\u96c6\u5408\u8f6c\u4e3a\u6d41\u518d\u6392\u5e8f\u518d\u6536\u96c6\u56de\u6765\u7684\u5168\u8fc7\u7a0b\u8017\u65f6\u3002<\/p>\n<p>\u6d4b\u8bd5\u7ed3\u679c\u5982\u4e0b\uff1a<\/p>\n<p><img decoding=\"async\" width=\"723\" height=\"462\" referrerpolicy=\"no-referrer\" src=\"https:\/\/segmentfault.com\/img\/bVc9Bxx\" alt=\"\" title=\"\" loading=\"lazy\"><\/p>\n<p>\u53ef\u4ee5\u53d1\u73b0\uff0c\u96c6\u5408\u8f6c\u4e3a\u6d41\u518d\u6536\u96c6\u56de\u6765\u7684\u8fc7\u7a0b\uff0c\u80af\u5b9a\u4f1a\u8017\u65f6\uff0c\u4f46\u662f\u5b83\u5360\u5168\u8fc7\u7a0b\u7684\u6bd4\u7387\u5e76\u4e0d\u7b97\u9ad8\u3002<\/p>\n<p>\u56e0\u6b64\uff0c\u8fd9\u90e8\u53ea\u80fd\u8bf4\u662f\u5c0f\u90e8\u4efd\u7684\u539f\u56e0\u3002<\/p>\n<h4>\u6392\u5e8f\u8fc7\u7a0b<\/h4>\n<p>\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u6e90\u7801\u5f88\u76f4\u89c2\u7684\u770b\u5230\u3002<\/p>\n<p><img decoding=\"async\" width=\"723\" height=\"431\" referrerpolicy=\"no-referrer\" src=\"https:\/\/segmentfault.com\/img\/bVc9Bxy\" alt=\"\" title=\"\" loading=\"lazy\"><\/p>\n<ul>\n<li>1 begin\u65b9\u6cd5\u521d\u59cb\u5316\u4e00\u4e2a\u6570\u7ec4\u3002<\/li>\n<li>2 accept \u63a5\u6536\u4e0a\u6e38\u6570\u636e\u3002<\/li>\n<li>3 end \u65b9\u6cd5\u5f00\u59cb\u8fdb\u884c\u6392\u5e8f\u3002<\/li>\n<\/ul>\n<p>\u8fd9\u91cc\u7b2c3\u6b65\u76f4\u63a5\u8c03\u7528\u4e86\u539f\u751f\u7684\u6392\u5e8f\u65b9\u6cd5\uff0c\u5b8c\u6210\u6392\u5e8f\u540e\uff0c\u7b2c4\u6b65\uff0c\u904d\u5386\u5411\u4e0b\u6e38\u53d1\u9001\u6570\u636e\u3002<\/p>\n<p>\u6240\u4ee5\u901a\u8fc7\u6e90\u7801\uff0c\u6211\u4eec\u4e5f\u80fd\u5f88\u660e\u663e\u5730\u770b\u5230\uff0cstream()\u6392\u5e8f\u6240\u9700\u65f6\u95f4\u80af\u5b9a\u662f &gt; \u539f\u751f\u6392\u5e8f\u65f6\u95f4\u3002<\/p>\n<p>\u53ea\u4e0d\u8fc7\uff0c\u8fd9\u91cc\u8981\u91cf\u5316\u5730\u641e\u660e\u767d\uff0c\u5230\u5e95\u591a\u51fa\u4e86\u591a\u5c11\uff0c\u8fd9\u91cc\u5f97\u53bb\u7f16\u8bd1jdk\u6e90\u7801\uff0c\u5728\u7b2c3\u6b65\u524d\u540e\u5c06\u65f6\u95f4\u6253\u5370\u51fa\u6765\u3002<\/p>\n<p>\u8fd9\u4e00\u6b65\u6211\u5c31\u4e0d\u505a\u4e86\u3002<\/p>\n<p>\u611f\u5174\u8da3\u7684\u670b\u53cb\u53ef\u4ee5\u53bb\u6d4b\u4e00\u4e0b\u3002<\/p>\n<p>\u4e0d\u8fc7\u6211\u89c9\u5f97\u8fd9\u4e24\u70b9\u4e5f\u80fd\u5f88\u597d\u5730\u56de\u7b54\uff0c\u4e3a\u4ec0\u4e48list.sort()\u6bd4Stream().sorted()\u66f4\u5feb\u3002<\/p>\n<p>\u8865\u5145\u8bf4\u660e\uff1a<\/p>\n<p><strong>1\u3001<\/strong> \u672c\u6587\u8bf4\u7684stream()\u6d41\u6307\u7684\u662f\u4e32\u884c\u6d41\uff0c\u800c\u4e0d\u662f\u5e76\u884c\u6d41\uff1b<\/p>\n<p><strong>2\u3001<\/strong> \u7edd\u5927\u591a\u6570\u573a\u666f\u4e0b\uff0c\u51e0\u767e\u51e0\u5343\u51e0\u4e07\u7684\u6570\u636e\uff0c\u5f00\u5fc3\u5c31\u597d\uff0c\u600e\u4e48\u65b9\u4fbf\u600e\u4e48\u7528\uff0c\u6ca1\u6709\u5fc5\u8981\u53bb\u8ba1\u8f83\u8fd9\u70b9\u6027\u80fd\u5dee\u5f02\uff1b<\/p>\n<p><strong>\u8fd1\u671f\u70ed\u6587\u63a8\u8350\uff1a<\/strong><\/p>\n<p>1.<a target=\"_blank\" href=\"https:\/\/link.segmentfault.com\/?enc=uLOj%2BPzjVtLTOcw771kq7Q%3D%3D.8OmmqD%2FeeOcTZNFSlW4O9XEuvfxP5HB8MzLdQlj6y5o%3D\" rel=\"noopener noreferrer\">1,000+ \u9053 Java\u9762\u8bd5\u9898\u53ca\u7b54\u6848\u6574\u7406(2022\u6700\u65b0\u7248)<\/a><\/p>\n<p>2.<a target=\"_blank\" href=\"https:\/\/link.segmentfault.com\/?enc=HEPlpiqkH0mg523be7Iypw%3D%3D.GzJoX7oBxRfxqvXCwWcozLUdxSa6eAN1O%2B2cuRrcx0oSJI6aT%2FyqQCQLmLTJR0QJ6kdpwNt7I3F7Lkg2%2F3MSEw%3D%3D\" rel=\"noopener noreferrer\">\u52b2\u7206\uff01Java \u534f\u7a0b\u8981\u6765\u4e86\u3002\u3002\u3002<\/a><\/p>\n<p>3.<a target=\"_blank\" href=\"https:\/\/link.segmentfault.com\/?enc=XIgG3sDIe7iJK5%2FdPfsI5w%3D%3D.vlH89UO%2BdW%2FiLqfvpPcd1M6EL0vOwFlXGo4jxf65x7Iro1dxIZ09Qiu7jCqiCbwh\" rel=\"noopener noreferrer\">Spring Boot 2.x \u6559\u7a0b\uff0c\u592a\u5168\u4e86\uff01<\/a><\/p>\n<p>4.<a target=\"_blank\" href=\"https:\/\/link.segmentfault.com\/?enc=9bloQZRXtPa9M0xrI59AtA%3D%3D.gFmBP%2BIL8rTSXWfJtmdO8Btjb%2B6%2B%2FaCLi1feUTQ6OmN5cLmqvwjjOo2pu955nJrnsbn8nhI3354MyeDZnGVKSg%3D%3D\" rel=\"noopener noreferrer\">\u522b\u518d\u5199\u6ee1\u5c4f\u7684\u7206\u7206\u7206\u70b8\u7c7b\u4e86\uff0c\u8bd5\u8bd5\u88c5\u9970\u5668\u6a21\u5f0f\uff0c\u8fd9\u624d\u662f\u4f18\u96c5\u7684\u65b9\u5f0f\uff01\uff01<\/a><\/p>\n<p>5.<a target=\"_blank\" href=\"https:\/\/link.segmentfault.com\/?enc=CzW7hmAESnjVT1WduH1%2F9g%3D%3D.9wBdsmhZS9Df45Stmp%2FLcGJdbTJ32z7xSmElRmuty5qX7B6ARzqp3PFD%2Fvgqxnmr8p%2B94C3OpKbUADGXbbNMl%2BCq9sk1v7AGGqV0%2FzJ0Tjk%3D\" rel=\"noopener noreferrer\">\u300aJava\u5f00\u53d1\u624b\u518c\uff08\u5d69\u5c71\u7248\uff09\u300b\u6700\u65b0\u53d1\u5e03\uff0c\u901f\u901f\u4e0b\u8f7d\uff01<\/a><\/p>\n<p>\u89c9\u5f97\u4e0d\u9519\uff0c\u522b\u5fd8\u4e86\u968f\u624b\u70b9\u8d5e+\u8f6c\u53d1\u54e6\uff01<\/p>\n<p><a href=\"https:\/\/segmentfault.com\/a\/1190000044195919\">https:\/\/segmentfault.com\/a\/1190000044195919<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4f5c\u8005\uff1a\u662f\u5949\u58f9\u5440 \/\u6765\u6e90\uff1ajuejin.cn\/post\/7262274383287500860 \u770b\u5230\u4e00\u4e2a\u8bc4\u8bba\uff0c\u91cc [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[4],"tags":[],"class_list":["post-10008254","post","type-post","status-publish","format-standard","hentry","category-share"],"jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/itmax.cn\/index.php?rest_route=\/wp\/v2\/posts\/10008254","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/itmax.cn\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/itmax.cn\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/itmax.cn\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/itmax.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=10008254"}],"version-history":[{"count":0,"href":"https:\/\/itmax.cn\/index.php?rest_route=\/wp\/v2\/posts\/10008254\/revisions"}],"wp:attachment":[{"href":"https:\/\/itmax.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=10008254"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/itmax.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=10008254"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/itmax.cn\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=10008254"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}