/**
  * Sets the type of link
  *
  * @param type The type of link desired. The following values can be set: <br>
  *     (note APPLICATION on Windows is 'Start Menu\Programs') APPLICATION is a Mac term.
  *     <ul>
  *       <li>{@link com.izforge.izpack.util.os.Shortcut#DESKTOP}
  *       <li>{@link com.izforge.izpack.util.os.Shortcut#APPLICATIONS}
  *       <li>{@link com.izforge.izpack.util.os.Shortcut#START_MENU}
  *       <li>{@link com.izforge.izpack.util.os.Shortcut#START_UP}
  *     </ul>
  *
  * @exception IllegalArgumentException if an an invalid type is passed
  * @throws UnsupportedEncodingException
  */
 public void setLinkType(int type) throws IllegalArgumentException, UnsupportedEncodingException {
   Debug.log(CLASS + myClass + ".setLinkType() '" + type + "'");
   switch (type) {
     case DESKTOP:
       {
         shortcut.setLinkType(ShellLink.DESKTOP);
         break;
       }
     case APPLICATIONS:
       {
         shortcut.setLinkType(ShellLink.PROGRAM_MENU);
         break;
       }
     case START_MENU:
       {
         shortcut.setLinkType(ShellLink.START_MENU);
         break;
       }
     case START_UP:
       {
         shortcut.setLinkType(ShellLink.STARTUP);
         break;
       }
     default:
       {
         throw (new IllegalArgumentException(type + "is not recognized as a valid link type"));
       }
   }
 }