>>5
Not to my knowledge. It would be odd for something as platform-specific as application preferences to be included in the Java framework, given Java's emphasis on portability, but it might be in there somewhere. There's probably third-party library that wraps the relevant parts of the Windows API, but I have no idea.
A kinda lousy alternative that should work is using the ftype
and assoc
command-line utilites via java.lang.Runtime.exec()
. You can use assoc
to get the filetype for a given extension and ftype
to get the application associated with the filetype. Pick some common filetypes, get the associations, and use them to create the shortcuts.
If you can get with just opening the files -- if you don't to know the actual apps -- I think you can just 'execute' a file and Windows will open it in the associated program.