Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
250 views
in Technique[技术] by (71.8m points)

java - com.apple.eawt - what exactly I should install

I'm using Max OS X Mountain Lion, java -version returns "1.6.0_37". But I cannot compile project with com.apple.eawt.* classes imported.

What I have to install to have Apple Java Extensions on my system?

Any help would be appreciated!

Update:

I receive following error from compiler:

java: package com.apple.eawt does not exist

Update-2:

XCode version 4.5.2 is installed

Update-3:

The reason of my problem was missed ui.jar in classpath. Thanks to @Ian Roberts

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

There is no JAR to download or anything extra to install, the classes are part of the JDK on Mac OS X. In Apple Java 6 JDKs they live in Contents/Classes/ui.jar under the JDK bundle (e.g. /System/Library/Java/JavaVirtualMachines/1.6.0.jdk or /Library/Java/JavaVirtualMachines/1.6.0_37-b06-434.jdk), on Oracle Java 7 they are in lib/rt.jar under the JRE home directory (/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home or /Library/Java/JavaVirtualMachines/jdk1.7.0*.jdk/Contents/Home/jre).


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...