public void main(IWContext iwc) throws Exception {
    _editPermission = (iwc.hasEditPermission(this) || this.isOwnerOfProject(iwc));
    Text tBreak = (Text) Text.getBreak().clone();
    tBreak.setFontSize(Text.FONT_SIZE_7_HTML_1);
    this.addAtBeginning(tBreak);

    IWBundle iwb = this.getBundle(iwc);
    IWResourceBundle iwrb = iwb.getResourceBundle(iwc);

    // this.addAtBeginning(new Text(this.getGroupName(),true,false,true));
    super.main(iwc);
    if (_editPermission) {
      Table table = new Table(8, 1);
      table.setHorizontalAlignment("left");
      table.setCellpadding(0);
      table.setCellpadding(0);

      table.setWidth(1, "6");
      table.setWidth(3, "6");
      table.setWidth(5, "12");
      table.setWidth(7, "6");

      //      table.add(getAddAndRemoveGroupLinkIcon(iwc, iwb),2,1);
      //      table.add(getAddAndRemoveGroupLink(iwc, iwrb),4,1);
      //
      //      table.add(getAddAndRemoveUserLinkIcon(iwc, iwb),6,1);
      //      table.add(getAddAndRemoveUserLink(iwc, iwrb),8,1);

      table.add(getAddAndRemoveUserLinkIcon(iwc, iwb), 2, 1);
      table.add(getAddAndRemoveUserLink(iwc, iwrb), 4, 1);

      this.add(table);
    }
  }
  public void main(IWContext iwc) throws Exception {
    parseAction(iwc);
    IWResourceBundle resourceBundle = getResourceBundle(iwc);

    // uploading
    Text uploadingText =
        new Text(
            resourceBundle.getLocalizedString(
                "query_uploader_upload_query_headline", "Upload Query"));
    uploadingText.setBold();
    add(uploadingText);
    Form form = new Form();
    addMaintainParametersToForm(form);
    Table table = new Table(2, 4);
    int row = 1;
    String queryInfo =
        resourceBundle.getLocalizedString("query_uploader_replace_query", "Replace query");
    table.add(queryInfo, 1, row);
    PresentationObject queryList = getDropDownOfQueriesForReplacing(resourceBundle, iwc);
    table.add(queryList, 2, row);
    row++;
    String defaultName =
        resourceBundle.getLocalizedString("query_uploader_default_queryname", "My query");
    TextInput textInput = new TextInput(KEY_QUERY_NAME, defaultName);
    Text info =
        new Text(resourceBundle.getLocalizedString("query_uploader_query_name", "set query name"));
    table.add(info, 1, row);
    table.add(textInput, 2, row);
    row++;
    table.add(getPrivatePublicRadioButtons(resourceBundle), 2, row);
    SimpleFileChooser uploader = new SimpleFileChooser(form, KEY_QUERY_FILE_ID);
    row++;
    table.add(uploader, 2, row);

    form.add(table);
    form.addParameter(KEY_QUERY_UPLOAD_IS_SUBMITTED, KEY_QUERY_UPLOAD_IS_SUBMITTED);
    add(form);

    // downloading
    add(Text.getBreak());
    Text downloadingText =
        new Text(
            resourceBundle.getLocalizedString(
                "query_uploader_download_query_headline", "Download Query"));
    downloadingText.setBold();
    add(downloadingText);
    Form downloadForm = new Form();
    row = 1;
    addMaintainParametersToForm(downloadForm);
    Table downloadTable = new Table(2, 3);
    PresentationObject downloadQueryList = getDropDownOfQueriesForDownloading(iwc);
    downloadTable.add(downloadQueryList, 1, row);
    downloadTable.add(getDownloadButton(resourceBundle), 2, row++);
    if (this.downloadUrl != null) {
      String downloadText =
          resourceBundle.getLocalizedString("query_uploader_download_query", "Download");
      downloadTable.add(new Link(downloadText, this.downloadUrl), 1, row++);
    }
    downloadTable.add(getGoBackButton(resourceBundle), 1, row);
    downloadForm.add(downloadTable);
    add(downloadForm);
  }