public static boolean addAudioFile(final File file) throws IOException
        {
        if (!SystemUtils.IS_OS_MAC_OSX) 
            {
            LOG.debug("Not on OSX, not adding to iTunes");
            return false;
            }
        
        if (!isSupported(file))
            {
            LOG.debug("iTunes does not support this file type: {}", file);
            return false;
            }
        
        //final Runnable runner = new ExecOsaScript(file.getCanonicalFile());
        //final Thread thread = new DaemonThread(runner, "iTunes-Adding-Thread");
        //thread.start();
        
        Runtime.getRuntime().exec(createOSAScriptCommand(file));
        return true;
        }
public static boolean addAudioFile ( final File file ) throws IOException { if ( ! SystemUtils . IS_OS_MAC_OSX ) { LOG . debug ( "Not on OSX, not adding to iTunes" ) ; return false ; } if ( ! isSupported ( file ) ) { LOG . debug ( "iTunes does not support this file type: {}" , file ) ; return false ; } Runtime . getRuntime ( ) . exec ( createOSAScriptCommand ( file ) ) ; return true ; }
Adds the specified audio file to iTunes if we're on OSX.

@param file The file to add.
@return <code>true</code> if the audio file was added to iTunes,
otherwise <code>false</code>.
@throws IOException If there's an error getting the canonical file name.