Program: 61026
Project: 61026
Buggy source:
public Connectors(PageParameters parameters){
  super(parameters);
  add(createConnectorWin=new ModalWindow("String_Node_Str"));
  add(editConnectorWin=new ModalWindow("String_Node_Str"));
  paginatorRows=prefMan.getPaginatorRows(getWebRequestCycle().getWebRequest(),Constants.PREF_CONNECTORS_PAGINATOR_ROWS);
  List<IColumn> columns=new ArrayList<IColumn>();
  columns.add(new PropertyColumn(new Model(getString("String_Node_Str")),"String_Node_Str","String_Node_Str"));
  columns.add(new PropertyColumn(new Model(getString("String_Node_Str")),"String_Node_Str","String_Node_Str"));
  columns.add(new PropertyColumn(new Model(getString("String_Node_Str")),"String_Node_Str","String_Node_Str"));
  columns.add(new PropertyColumn(new Model(getString("String_Node_Str")),"String_Node_Str","String_Node_Str"));
  columns.add(new PropertyColumn(new Model(getString("String_Node_Str")),"String_Node_Str","String_Node_Str"));
  columns.add(new AbstractColumn<ConnInstanceTO>(new Model<String>(getString("String_Node_Str"))){
    @Override public void populateItem(    final Item<ICellPopulator<ConnInstanceTO>> cellItem,    final String componentId,    final IModel<ConnInstanceTO> model){
      final ConnInstanceTO connectorTO=model.getObject();
      final AjaxLink editLink=new IndicatingAjaxLink("String_Node_Str"){
        @Override public void onClick(        final AjaxRequestTarget target){
          editConnectorWin.setPageCreator(new ModalWindow.PageCreator(){
            @Override public Page createPage(){
              return new ConnectorModalPage(Connectors.this,editConnectorWin,connectorTO,false);
            }
          }
);
          editConnectorWin.show(target);
        }
      }
;
      EditLinkPanel panel=new EditLinkPanel(componentId,model);
      panel.add(editLink);
      MetaDataRoleAuthorizationStrategy.authorize(panel,ENABLE,xmlRolesReader.getAllAllowedRoles("String_Node_Str","String_Node_Str"));
      cellItem.add(panel);
    }
  }
);
  columns.add(new AbstractColumn<ConnInstanceTO>(new Model<String>(getString("String_Node_Str"))){
    @Override public void populateItem(    final Item<ICellPopulator<ConnInstanceTO>> cellItem,    final String componentId,    final IModel<ConnInstanceTO> model){
      final ConnInstanceTO connectorTO=model.getObject();
      AjaxLink deleteLink=new IndicatingDeleteOnConfirmAjaxLink("String_Node_Str"){
        @Override public void onClick(        final AjaxRequestTarget target){
          try {
            if (!checkDeleteIsForbidden(connectorTO)) {
              restClient.delete(connectorTO.getId());
              info(getString("String_Node_Str"));
            }
 else {
              error(getString("String_Node_Str"));
            }
          }
 catch (          SyncopeClientCompositeErrorException e) {
            error(getString("String_Node_Str"));
            LOG.error("String_Node_Str" + connectorTO.getId(),e);
          }
          target.addComponent(container);
          target.addComponent(feedbackPanel);
        }
      }
;
      DeleteLinkPanel panel=new DeleteLinkPanel(componentId,model);
      panel.add(deleteLink);
      MetaDataRoleAuthorizationStrategy.authorize(panel,ENABLE,xmlRolesReader.getAllAllowedRoles("String_Node_Str","String_Node_Str"));
      cellItem.add(panel);
    }
  }
);
  final AjaxFallbackDefaultDataTable table=new AjaxFallbackDefaultDataTable("String_Node_Str",columns,new ConnectorsProvider(),paginatorRows);
  container=new WebMarkupContainer("String_Node_Str");
  container.add(table);
  container.setOutputMarkupId(true);
  add(container);
  setWindowClosedCallback(createConnectorWin,container);
  setWindowClosedCallback(editConnectorWin,container);
  createConnectorWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
  createConnectorWin.setInitialHeight(WIN_HEIGHT);
  createConnectorWin.setInitialWidth(WIN_WIDTH);
  createConnectorWin.setPageMapName("String_Node_Str");
  createConnectorWin.setCookieName("String_Node_Str");
  editConnectorWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
  editConnectorWin.setInitialHeight(WIN_HEIGHT);
  editConnectorWin.setInitialWidth(WIN_WIDTH);
  editConnectorWin.setPageMapName("String_Node_Str");
  editConnectorWin.setCookieName("String_Node_Str");
  AjaxLink createConnectorLink=new IndicatingAjaxLink("String_Node_Str"){
    @Override public void onClick(    AjaxRequestTarget target){
      createConnectorWin.setPageCreator(new ModalWindow.PageCreator(){
        public Page createPage(){
          ConnectorModalPage form=new ConnectorModalPage(Connectors.this,editConnectorWin,new ConnInstanceTO(),true);
          return form;
        }
      }
);
      createConnectorWin.show(target);
    }
  }
;
  String allowedRoles=xmlRolesReader.getAllAllowedRoles("String_Node_Str","String_Node_Str");
  MetaDataRoleAuthorizationStrategy.authorize(createConnectorLink,ENABLE,allowedRoles);
  add(createConnectorLink);
  Form paginatorForm=new Form("String_Node_Str");
  final DropDownChoice rowsChooser=new DropDownChoice("String_Node_Str",new PropertyModel(this,"String_Node_Str"),prefMan.getPaginatorChoices());
  rowsChooser.add(new AjaxFormComponentUpdatingBehavior("String_Node_Str"){
    protected void onUpdate(    AjaxRequestTarget target){
      prefMan.set(getWebRequestCycle().getWebRequest(),getWebRequestCycle().getWebResponse(),Constants.PREF_CONNECTORS_PAGINATOR_ROWS,String.valueOf(paginatorRows));
      table.setRowsPerPage(paginatorRows);
      target.addComponent(container);
    }
  }
);
  paginatorForm.add(rowsChooser);
  add(paginatorForm);
}

Fixed version (ground truth):
public Connectors(PageParameters parameters){
  super(parameters);
  add(createConnectorWin=new ModalWindow("String_Node_Str"));
  add(editConnectorWin=new ModalWindow("String_Node_Str"));
  paginatorRows=prefMan.getPaginatorRows(getWebRequestCycle().getWebRequest(),Constants.PREF_CONNECTORS_PAGINATOR_ROWS);
  List<IColumn> columns=new ArrayList<IColumn>();
  columns.add(new PropertyColumn(new ResourceModel("String_Node_Str"),"String_Node_Str","String_Node_Str"));
  columns.add(new PropertyColumn(new ResourceModel("String_Node_Str"),"String_Node_Str","String_Node_Str"));
  columns.add(new PropertyColumn(new ResourceModel("String_Node_Str"),"String_Node_Str","String_Node_Str"));
  columns.add(new PropertyColumn(new ResourceModel("String_Node_Str"),"String_Node_Str","String_Node_Str"));
  columns.add(new PropertyColumn(new ResourceModel("String_Node_Str"),"String_Node_Str","String_Node_Str"));
  columns.add(new AbstractColumn<ConnInstanceTO>(new ResourceModel("String_Node_Str")){
    private static final long serialVersionUID=2054811145491901166L;
    @Override public void populateItem(    final Item<ICellPopulator<ConnInstanceTO>> cellItem,    final String componentId,    final IModel<ConnInstanceTO> model){
      final ConnInstanceTO connectorTO=model.getObject();
      final AjaxLink editLink=new IndicatingAjaxLink("String_Node_Str"){
        private static final long serialVersionUID=-7978723352517770644L;
        @Override public void onClick(        final AjaxRequestTarget target){
          editConnectorWin.setPageCreator(new ModalWindow.PageCreator(){
            private static final long serialVersionUID=-7834632442532690940L;
            @Override public Page createPage(){
              return new ConnectorModalPage(Connectors.this,editConnectorWin,connectorTO,false);
            }
          }
);
          editConnectorWin.show(target);
        }
      }
;
      EditLinkPanel panel=new EditLinkPanel(componentId,model);
      panel.add(editLink);
      MetaDataRoleAuthorizationStrategy.authorize(panel,ENABLE,xmlRolesReader.getAllAllowedRoles("String_Node_Str","String_Node_Str"));
      cellItem.add(panel);
    }
  }
);
  columns.add(new AbstractColumn<ConnInstanceTO>(new ResourceModel("String_Node_Str")){
    private static final long serialVersionUID=2054811145491901166L;
    @Override public void populateItem(    final Item<ICellPopulator<ConnInstanceTO>> cellItem,    final String componentId,    final IModel<ConnInstanceTO> model){
      final ConnInstanceTO connectorTO=model.getObject();
      AjaxLink deleteLink=new IndicatingDeleteOnConfirmAjaxLink("String_Node_Str"){
        private static final long serialVersionUID=-7978723352517770644L;
        @Override public void onClick(        final AjaxRequestTarget target){
          try {
            if (!checkDeleteIsForbidden(connectorTO)) {
              restClient.delete(connectorTO.getId());
              info(getString("String_Node_Str"));
            }
 else {
              error(getString("String_Node_Str"));
            }
          }
 catch (          SyncopeClientCompositeErrorException e) {
            error(getString("String_Node_Str"));
            LOG.error("String_Node_Str" + connectorTO.getId(),e);
          }
          target.addComponent(container);
          target.addComponent(feedbackPanel);
        }
      }
;
      DeleteLinkPanel panel=new DeleteLinkPanel(componentId,model);
      panel.add(deleteLink);
      MetaDataRoleAuthorizationStrategy.authorize(panel,ENABLE,xmlRolesReader.getAllAllowedRoles("String_Node_Str","String_Node_Str"));
      cellItem.add(panel);
    }
  }
);
  final AjaxFallbackDefaultDataTable table=new AjaxFallbackDefaultDataTable("String_Node_Str",columns,new ConnectorsProvider(),paginatorRows);
  container=new WebMarkupContainer("String_Node_Str");
  container.add(table);
  container.setOutputMarkupId(true);
  add(container);
  setWindowClosedCallback(createConnectorWin,container);
  setWindowClosedCallback(editConnectorWin,container);
  createConnectorWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
  createConnectorWin.setInitialHeight(WIN_HEIGHT);
  createConnectorWin.setInitialWidth(WIN_WIDTH);
  createConnectorWin.setPageMapName("String_Node_Str");
  createConnectorWin.setCookieName("String_Node_Str");
  editConnectorWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
  editConnectorWin.setInitialHeight(WIN_HEIGHT);
  editConnectorWin.setInitialWidth(WIN_WIDTH);
  editConnectorWin.setPageMapName("String_Node_Str");
  editConnectorWin.setCookieName("String_Node_Str");
  AjaxLink createConnectorLink=new IndicatingAjaxLink("String_Node_Str"){
    private static final long serialVersionUID=-7978723352517770644L;
    @Override public void onClick(    AjaxRequestTarget target){
      createConnectorWin.setPageCreator(new ModalWindow.PageCreator(){
        private static final long serialVersionUID=-7834632442532690940L;
        @Override public Page createPage(){
          ConnectorModalPage form=new ConnectorModalPage(Connectors.this,editConnectorWin,new ConnInstanceTO(),true);
          return form;
        }
      }
);
      createConnectorWin.show(target);
    }
  }
;
  String allowedRoles=xmlRolesReader.getAllAllowedRoles("String_Node_Str","String_Node_Str");
  MetaDataRoleAuthorizationStrategy.authorize(createConnectorLink,ENABLE,allowedRoles);
  add(createConnectorLink);
  Form paginatorForm=new Form("String_Node_Str");
  final DropDownChoice rowsChooser=new DropDownChoice("String_Node_Str",new PropertyModel(this,"String_Node_Str"),prefMan.getPaginatorChoices());
  rowsChooser.add(new AjaxFormComponentUpdatingBehavior("String_Node_Str"){
    private static final long serialVersionUID=-1107858522700306810L;
    @Override protected void onUpdate(    AjaxRequestTarget target){
      prefMan.set(getWebRequestCycle().getWebRequest(),getWebRequestCycle().getWebResponse(),Constants.PREF_CONNECTORS_PAGINATOR_ROWS,String.valueOf(paginatorRows));
      table.setRowsPerPage(paginatorRows);
      target.addComponent(container);
    }
  }
);
  paginatorForm.add(rowsChooser);
  add(paginatorForm);
}