Java工程里的常量类

    /**
     *     系统名
     */
    public static final String OS_NAME = System.getProperty("os.name");
    
    /**
     * Java版本
     */
    public static final String JAVA_VERSION = System.getProperty("java.version");
    
    /**
     * 系统相关的换行符
     */
    public static final String LINE_SEPARATOR = System.getProperty("line.separator");
    
    /**
     *     系统相关的文件路径分隔符 \或/
     */
    public static final String FILE_SEPARATOR = File.separator;

评论

暂无评论