This post shows how to add Java 8 support to eclipse Kepler. You can following the 3 simple steps to get Java 8 work on your existing Kepler on Mac.
1. Install Java 8
To download Java SE Development Kit 8, select the correct version for Mac here. It is a .dmg file which can be installed by double clicking.
2. Install Java 8 Support for Eclipse Kepler
Use the URL: http://download.eclipse.org/eclipse/updates/4.3-P-builds/ to install Java 8 Support, like the following:
3. Config in Eclipse
Now go to eclipse -> Preference
Click -> Java -> Installed JREs
Select -> Add Standard VM
Here you need to give the home directory of Java 8. You can use the following command to figure out the default location where Java 8 is installed.
/usr/libexec/java_home -v 1.8
In my macbook, it is installed under:
Now the environment is set up, you can read Java 8 Lambdas tutorial series to start programming lambdas.
<pre><code> String foo = "bar"; </code></pre>