/**
   * Gets the type of link types are: <br>
   *
   * <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>
   *
   * maps from ShellLink-types to Shortcut-types.
   */
  public int getLinkType() {
    int typ = shortcut.getLinkType();
    Debug.log(CLASS + myClass + ".getLinkType() '" + typ + "'");
    switch (typ) {
      case ShellLink.DESKTOP:
        typ = DESKTOP;
        break;
      case ShellLink.PROGRAM_MENU:
        typ = APPLICATIONS;
        break;
      case ShellLink.START_MENU:
        typ = START_MENU;
        break;
      case ShellLink.STARTUP:
        typ = START_UP;
        break;
      default:
        break;
    }

    return typ;
  }
Example #2
0
  /**
   * Gets the type of link types are: <br>
   *
   * <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>
   *
   * maps from ShellLink-types to Shortcut-types.
   */
  @Override
  public int getLinkType() {
    int typ = shortcut.getLinkType();
    switch (typ) {
      case ShellLink.DESKTOP:
        typ = DESKTOP;
        break;
      case ShellLink.PROGRAM_MENU:
        typ = APPLICATIONS;
        break;
      case ShellLink.START_MENU:
        typ = START_MENU;
        break;
      case ShellLink.STARTUP:
        typ = START_UP;
        break;
      default:
        break;
    }

    return typ;
  }