官术网_书友最值得收藏!

Installation on MAC OS X

In this section, we will take look at how to install Java step-by-step on an OS X platform. I will describe the installation process for the released version available at the time of writing this book. As for now, the Java 9 early access version is a bit tricky to install. It is probable that version Java 9 will have similar or the same install steps as Java 8 update 92 has.

The OS X version of Java comes in the form of a .dmg file. This is a packaging format of OS X. To open it, simply double click on the file in the Download folder where the browser saves it and the operating system will mount the file as a read-only disk image.

There is only one file on this disk: the installation image. Double click on the file name or icon in the Finder application and the installation process will start.

The first screen opening is a welcome screen. Click Continue and you will see the Summary page that displays what will be installed.

It is not a surprise that you will see a standard Java installation. This time, the button is called Install. Click on it and you will see the following:

This is the time when you have to provide the login parameters for the administrative user—a username and password. When provided, installation starts and, in a few seconds, you will see a Summary page.

Click Close and you are ready. You have Java installed on your Mac. Optionally, you can dismount the installation disk and, sometime later, you can also delete the .dmg file. You will not need that, and in case you do, you can download it any time from Oracle.

The last thing is to check whether the installation was okay. Proof of the pudding is eating it. Start a Terminal window and type java -version at the prompt and Java will tell you the version installed.

On the next screenshot you can see the output on my workstation and also the Mac OS commands that are handy to switch between the different versions of Java:

On the screenshot, you can see that I have installed the Java JDK 1.8u92 version and, at the same time, I also have a Java 9 early release installation, which I will use to test the new features of Java for this book.

主站蜘蛛池模板: 梓潼县| 三台县| 裕民县| 阿拉善右旗| 延津县| 海宁市| 朝阳区| 东兴市| 正蓝旗| 丹江口市| 娱乐| 诸暨市| 泗水县| 霍城县| 当涂县| 斗六市| 盐边县| 河曲县| 阿巴嘎旗| 保靖县| 洛浦县| 隆尧县| 东平县| 巢湖市| 庐江县| 玉龙| 同仁县| 禄丰县| 上栗县| 浦城县| 林西县| 个旧市| 明光市| 运城市| 南和县| 平昌县| 勃利县| 漾濞| 蒙山县| 尚义县| 西安市|