Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SVN, XCode, and pre-existing code...



Doug Zwick wrote:

>Note that, if your Mac support code uses Apple-specific classes (e.g.
>ApplicationListener) you will need to provide the stubs JAR file for this
>package so that compilation of the Mac-specific code does not fail on other
>platforms. It *can* be done using reflection, but its rather painful
>(requires the use of a dynamic proxy). Search the archives of this list,
>there may be an implementation you can use and avoid having to do it
>yourself.

The only thing I have to add to the comprehensive advice is:
  Use the stubs jar.  Do not attempt reflection.

The stubs already exist:
  <http://developer.apple.com/samplecode/AppleJavaExtensions/index.html>

It is far, far simpler to use them than it is to develop a comprehensive
set of dynamic proxy interfaces.  "Rather painful" is an understatement.
Like having a red-hot needle pierce your eyeball is a "momentary
inconvenience", because it's only a moment before you pass out.

  -- GG


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Java-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/java-dev/email@hidden

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.