The compiler compliance setting tells the compiler to pretend it's a different version of Java.

The Java 8 compiler will produce class files in the Java 8 version of the class file format, and accept Java 8 source files. JRE 6 can't load this version, because it was created after JRE 6 was.

If you set the compliance level to "JRE 6", it will instead compile Java 6 source files into Java 6 class files.

It's like saving a Word document as "Word 97-2003 format" - so that Word 97-2003 can read your document. You're saving the class files in Java 6 format so that Java 6 can read them.

我的理解就是 虽然eclipse使用的是jdk 8,但是通过设置 complier compliance setting 我们可以在jdk 6 (或其他) 环境中进行编译。 好比在word2010中将word文件保存为word2003的格式。

eclipse中的 Compiler compliance level含义的更多相关文章

  1. Eclipse工程中Java Build Path中的JDK版本和Java Compiler Compiler compliance level的区别(转)

    在这里记录一下在eclipse中比较容易搞混淆和设置错误的地方.如下图所示的功能: 最精准的解释如下: Build Path是运行时环境  Compiler是编译时环境  假设,你的代码用到泛型,Bu ...

  2. MyEclipse工程中Java Build Path中的JDK版本和Java Compiler Compiler compliance level的区别

    感谢大佬:https://blog.csdn.net/shan9liang/article/details/17266519 问题起源: 今天再在ESB调用WebService测试,需要在jboss上 ...

  3. Eclipse编译Android项目时出现的问题:Android requires compiler compliance level 5.0 or 6.0. Found '1.8' instead.

    Consle: Android requires compiler compliance level 5.0 or 6.0. Found '1.8' instead. Please use Andro ...

  4. Android requires compiler compliance level 5.0 or 6.0. Found '1.4' instead的解决办法

    今天在导入工程进Eclipse的时候竟然出错了,控制台输出的是: [2013-02-04 22:17:13 - takepicture] Android requires compiler compl ...

  5. Android requires compiler compliance level 5.0 or 6.0. Found '1.7' instead. Please use Android Tool

    重装操作系统后,要重新配置Android开发环境.配置成功后,添加原本项目时却出现了错误! Android requires compiler compliance level 5.0 or 6.0. ...

  6. Android requires compiler compliance level 5.0 or 6.0. Found '1.4' instead.解决方法

    今天在eclipse里报这个错误: Android requires compiler compliance level 5.0 or 6.0. Found '1.4' instead. Please ...

  7. Android requires compiler compliance level 5.0 or 6.0. Found '1.4' instead的解决的方法

    今天在eclipse里报这个错误:   Android requires compiler compliance level 5.0 or 6.0. Found '1.4' instead. Plea ...

  8. Android requires compiler compliance level 5.0 or 6.0. Found '1.8' instead. Please use Android Tools>Fix project Properties.

    重装操作系统之后,或者破坏了Android的开发环境之后,需要重新配置好Android的开发环境.但是配置好后,导入原有的项目时,报错: Android requires compiler compl ...

  9. Android requires compiler compliance level 5.0 or 6.0. Found '1.7' instead

    Android requires compiler compliance level 5.0 or 6.0. Found '1.7' instead 在解决问题Underscores can only ...

随机推荐

  1. CentOS7 配置阿里云yum源

    1)下载repo文件 wget http://mirrors.aliyun.com/repo/Centos-7.repo 2)备份并替换系统的repo文件 cp Centos-7.repo /etc/ ...

  2. [AS3.0] Error #1069: Property onBWDone not found on flash.net.NetConnection and there is no default value.解决办法

    在运用FMS录制视频时,假如出现这个错误,最直接的解决办法如下: _netConnection.client = { onBWDone: function():void{ trace("on ...

  3. Java 反射 getDeclareFields getModifiers setAccessible(true)

    示例代码: public static Map<String, Object> dtoToMap(Object obj, String pre,            String las ...

  4. linux 网卡启动方法

    CentOS 7默认的网卡名称是eno16777736 一般人的是 eth0 编辑配置文件 vi /etc/sysconfig/network-scripts/ifcfg-eno16777736把 O ...

  5. 【转】el表达式的判断符

    el表达式一般不直接用==判断是否相等 != > < >= <=之类的表示不等于 大于 小于 大于等于 小于等于,而是使用字母表示的表达式,他们的表示如下: == eq 等于 ...

  6. linux下的gcc编译器

    1. 编译单个文件成可执行文件 gcc hello.c 生成默认的可执行文件a.out 2. 编译单个文件为指定名字的可执行文件,使用-o选项指定文件名字 gcc -o test main.c 生成文 ...

  7. 关于IE下用HTTPS无法下载/打开文件

    关于IE下用HTTPS无法下载/打开文件(ie8兼容模式下,ie7/ie6下有些问题.) http协议下运行正常,可以下载文件但放到https协议下就不好用一保存,IE提示:ie无法下载,请求站点不可 ...

  8. declaration expected but identifier 'firedac' found

    老是出现这种错误,原来是//注解时出来标点错误!

  9. sql评估期已过如何解决该问题

    点击开始-所有程序-Microsoft SQL Server 2008-配置工具-SQL Server 安装中心然后点击左侧的维护,在点击右侧的版本升级,接着按照提示一直点下一步,到产品密钥的时候输入 ...

  10. R&Rstudio安装各种包

    安装rCharts的方法 install.packages('devtools') library(devtools) require(devtools) install_github('ramnat ...