jdk新特性

jdk13新特性

2019-11-27  本文已影响0人  时空的朋友

要点

2019-09-17发布

新特性

350: Dynamic CDS Archives:改进跨JVM的类内存共享

351: ZGC: Uncommit Unused Memory:未使用的堆内存返回给操作系统

353: Reimplement the Legacy Socket API

354: Switch Expressions (Preview)

int n = switch (type) {
    case "a" -> 1;
    default -> {
        yield -1;
    }
};

355: Text Blocks (Preview)

String sql = """
        select * from table
        where a=? and b=?
        order by id
        limit 10
        """;

参考

jdk13

上一篇 下一篇

猜你喜欢

热点阅读