@Test public void reconnect() { this.setup(); this.groupModel.persons.getSelection().setInterval(0, 0); assertEquals("this.table.getSelectedRowCount()", 1, this.table.getSelectedRowCount()); this.provider.setPresentationModel(null); assertEquals("this.table.getSelectedRowCount()", 0, this.table.getSelectedRowCount()); assertEquals("this.groupEd.persons.getSelection().size()", 1, this.groupModel.persons.getSelection().size()); this.provider.setPresentationModel(this.groupModel); assertEquals("this.groupEd.persons.getSelection().size()", 1, this.groupModel.persons.getSelection().size()); assertEquals("this.table.getSelectedRowCount()", 1, this.table.getSelectedRowCount()); }
public void setPresentationModel(IListPM<? extends PresentationModel> newModel) { IListPM<? extends PresentationModel> oldModel = this.presentationModel; if (newModel == oldModel) { return; } disconnect(); this.presentationModel = newModel; connect(); this.firePropertyChange("presentationModel", oldModel, newModel); }
BnTable extends JTable implements View<IListPM<? extends PresentationModel>>, ModelSubscriber { public void setPresentationModel(IListPM<? extends PresentationModel> newModel) { IListPM<? extends PresentationModel> oldModel = this.presentationModel; if (newModel == oldModel) { return; } disconnect(); this.presentationModel = newModel; connect(); this.firePropertyChange("presentationModel", oldModel, newModel); } }
BnTable extends JTable implements View<IListPM<? extends PresentationModel>>, ModelSubscriber { public void setPresentationModel(IListPM<? extends PresentationModel> newModel) { IListPM<? extends PresentationModel> oldModel = this.presentationModel; if (newModel == oldModel) { return; } disconnect(); this.presentationModel = newModel; connect(); this.firePropertyChange("presentationModel", oldModel, newModel); } BnTable(); }
BnTable extends JTable implements View<IListPM<? extends PresentationModel>>, ModelSubscriber { public void setPresentationModel(IListPM<? extends PresentationModel> newModel) { IListPM<? extends PresentationModel> oldModel = this.presentationModel; if (newModel == oldModel) { return; } disconnect(); this.presentationModel = newModel; connect(); this.firePropertyChange("presentationModel", oldModel, newModel); } BnTable(); boolean isCellEditingAllowed(); void setCellEditingAllowed(boolean newValue); boolean isSortable(); void setSortable(boolean newValue); IListPM<? extends PresentationModel> getPresentationModel(); void setPresentationModel(IListPM<? extends PresentationModel> newModel); IModelProvider getModelProvider(); void setModelProvider(IModelProvider provider); Path getPath(); void setPath(Path path); BnColumn[] getColumns(); void addColumn(BnColumn newCol); void setColumns(BnColumn[] newCols); @Override void columnMarginChanged(ChangeEvent e); }
BnTable extends JTable implements View<IListPM<? extends PresentationModel>>, ModelSubscriber { public void setPresentationModel(IListPM<? extends PresentationModel> newModel) { IListPM<? extends PresentationModel> oldModel = this.presentationModel; if (newModel == oldModel) { return; } disconnect(); this.presentationModel = newModel; connect(); this.firePropertyChange("presentationModel", oldModel, newModel); } BnTable(); boolean isCellEditingAllowed(); void setCellEditingAllowed(boolean newValue); boolean isSortable(); void setSortable(boolean newValue); IListPM<? extends PresentationModel> getPresentationModel(); void setPresentationModel(IListPM<? extends PresentationModel> newModel); IModelProvider getModelProvider(); void setModelProvider(IModelProvider provider); Path getPath(); void setPath(Path path); BnColumn[] getColumns(); void addColumn(BnColumn newCol); void setColumns(BnColumn[] newCols); @Override void columnMarginChanged(ChangeEvent e);  }