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: AppleScript + Mail (+ Java)



Jeremy Wood wrote:

>If there's not already a set of classes to help me gather this info... and
>if I have a lightweight handy-dandy XML parser... (and my Java is much
>sharper than my C), then it seems more time-efficient (in my case) to parse
>the XML file... unless there are particular hazards/risks involved? 

Just the usual risks of reading a private file not intended for public use.

Calling the native API would isolate you from file-format changes.  You are
correct: there is no Java API for it.


I also suggest a look at:
  a) the 'open' command, passing it a mailto: URL.
  b) Apple's class FileManager.openURL(String)
  <http://developer.apple.com/documentation/Java/Reference/1.4.2/appledoc/api/com/apple/eio/FileManager.html>

However, I suspect that neither of those will give you enough control over the passed-in parameters.  But it's worth taking a look and judging for yourself.

And it definitely won't give you the ability to discover if Mail.app or another email client has been set up.  I know of no other Java API that will provide such a feature: Launch Services is it.

  -- 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.