hutool系统信息

 System.out.println("-------Java Virtual Machine Specification信息----SystemUtil.getJvmSpecInfo()--------");
        JvmSpecInfo jvmSpecInfo = SystemUtil.getJvmSpecInfo();
        System.out.println(jvmSpecInfo);
        System.out.println("-------------------");

        System.out.println("--------Java Virtual Machine Implementation信息----SystemUtil.getJvmInfo()-------");
        JvmInfo jvmInfo = SystemUtil.getJvmInfo();
        System.out.println(jvmInfo);
        System.out.println("-------------------");

        System.out.println("---------Java Specification信息----SystemUtil.getJavaSpecInfo()------");
        JavaSpecInfo javaSpecInfo = SystemUtil.getJavaSpecInfo();
        System.out.println(javaSpecInfo);
        System.out.println("-------------------");

        System.out.println("----------Java Implementation信息----SystemUtil.getJavaInfo()-----");
        JavaInfo javaInfo = SystemUtil.getJavaInfo();
        System.out.println(javaInfo);
        System.out.println("-------------------");

        System.out.println("---------Java运行时信息----SystemUtil.getJavaRuntimeInfo()------");
        JavaRuntimeInfo javaRuntimeInfo = SystemUtil.getJavaRuntimeInfo();
        System.out.println(javaRuntimeInfo);
        System.out.println("-------------------");

        System.out.println("--------系统信息----SystemUtil.getOsInfo()-------");
        OsInfo osInfo = SystemUtil.getOsInfo();
        System.out.println(osInfo);
        System.out.println("-------------------");

        System.out.println("---------当前主机网络地址信息-----SystemUtil.getHostInfo()-----");
        HostInfo hostInfo = SystemUtil.getHostInfo();
        System.out.println(hostInfo);
        System.out.println("-------------------");

        System.out.println("--------运行时信息,包括内存总大小、已用大小、可用大小等----SystemUtil.getRuntimeInfo()-------");
        RuntimeInfo runtimeInfo = SystemUtil.getRuntimeInfo();
        System.out.println(runtimeInfo);
        System.out.println("-------------------");

        System.out.println("--------用户信息----SystemUtil.getUserInfo()-------");
        UserInfo userInfo = SystemUtil.getUserInfo();
        System.out.println(userInfo);
        System.out.println("-------------------");
-------Java Virtual Machine Specification信息----SystemUtil.getJvmSpecInfo()--------
JavaVM Spec. Name:    Java Virtual Machine Specification
JavaVM Spec. Version: 1.8
JavaVM Spec. Vendor:  Oracle Corporation

-------------------
--------Java Virtual Machine Implementation信息----SystemUtil.getJvmInfo()-------
JavaVM Name:    Java HotSpot(TM) 64-Bit Server VM
JavaVM Version: 25.281-b09
JavaVM Vendor:  Oracle Corporation
JavaVM Info:    mixed mode

-------------------
---------Java Specification信息----SystemUtil.getJavaSpecInfo()------
Java Spec. Name:    Java Platform API Specification
Java Spec. Version: 1.8
Java Spec. Vendor:  Oracle Corporation

-------------------
----------Java Implementation信息----SystemUtil.getJavaInfo()-----
Java Version:    1.8.0_281
Java Vendor:     Oracle Corporation
Java Vendor URL: http://java.oracle.com/

-------------------
---------Java运行时信息----SystemUtil.getJavaRuntimeInfo()------
Java Runtime Name:      Java(TM) SE Runtime Environment
Java Runtime Version:   1.8.0_281-b09
Java Home Dir:          D:\soft\java\jdk\jre
Java Extension Dirs:    D:\soft\java\jdk\jre\lib\ext;C:\Windows\Sun\Java\lib\ext
Java Endorsed Dirs:     D:\soft\java\jdk\jre\lib\endorsed
Java Class Path:        C:\Users\28543\AppData\Local\Temp\classpath1252819962.jar;D:\tool\IDEA\IntelliJ IDEA 2021.2.2\lib\idea_rt.jar
Java Class Version:     52.0
Java Library Path:      D:\soft\java\jdk\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:\Python39\Scripts\;C:\Python39\;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;D:\soft\VMware\bin\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files\TortoiseSVN\bin;"D:\soft\java\jdk\bin;D:\soft\java\jdk\jre\bin";D:\database\mysql5.7\bin;D:\soft\nodejs\;C:\ProgramData\chocolatey\bin;D:\tool\apache-maven-3.6.3\bin;C:\Users\28543\AppData\Local\Microsoft\WindowsApps;C:\Users\28543\AppData\Roaming\npm;.
Java Protocol Packages: [n/a]

-------------------
--------系统信息----SystemUtil.getOsInfo()-------
OS Arch:        amd64
OS Name:        Windows 10
OS Version:     10.0
File Separator: \
Line Separator: 

Path Separator: ;

-------------------
---------当前主机网络地址信息-----SystemUtil.getHostInfo()-----
Host Name:    USER42193.fpi-inc.com
Host Address: 192.168.2.1

-------------------
--------运行时信息,包括内存总大小、已用大小、可用大小等----SystemUtil.getRuntimeInfo()-------
Max Memory:    4.42 GB
Total Memory:     892 MB
Free Memory:     751.75 MB
Usable Memory:     4.28 GB

-------------------
--------用户信息----SystemUtil.getUserInfo()-------
User Name:        28543\
User Home Dir:    C:\Users\28543\
User Current Dir: D:\2022\fpi\
User Temp Dir:    C:\Users\28543\AppData\Local\Temp\
User Language:    zh
User Country:     CN

-------------------

posted @ 2021-11-18 14:57  kht  阅读(533)  评论(0编辑  收藏  举报