@Test public void testOnValueRestricted() { final String value = "col1"; presenter.restrictedColumns.clear(); presenter.onValueRestricted(value); assertEquals(1, presenter.restrictedColumns.size()); assertEquals("col1", presenter.restrictedColumns.get(0)); verify(dataColumnDefEditor, times(1)).isEditMode(false); verify(view, times(1)).insert(anyInt(), any(DataColumnDefEditor.View.class), anyBoolean(), anyBoolean(), anyString()); verify(view, times(1)).remove(anyInt()); verify(view, times(0)).init(presenter); verify(view, times(0)).clear(); }
@Override public void onValueRestricted(final String value) { this.restrictedColumns.add(value); setEditorEnabled(value, false, DataSetEditorConstants.INSTANCE.columnIsUsedInFilter()); }
ColumnListEditor implements IsWidget, org.dashbuilder.dataset.client.editor.ColumnListEditor { @Override public void onValueRestricted(final String value) { this.restrictedColumns.add(value); setEditorEnabled(value, false, DataSetEditorConstants.INSTANCE.columnIsUsedInFilter()); } }
ColumnListEditor implements IsWidget, org.dashbuilder.dataset.client.editor.ColumnListEditor { @Override public void onValueRestricted(final String value) { this.restrictedColumns.add(value); setEditorEnabled(value, false, DataSetEditorConstants.INSTANCE.columnIsUsedInFilter()); } @Inject  ColumnListEditor(final SyncBeanManager beanManager,
                            final DataColumnDefDriver dataColumnDefDriver,
                            final Event<ColumnsChangedEvent> columnsChangedEvent,
                            final View view); }
ColumnListEditor implements IsWidget, org.dashbuilder.dataset.client.editor.ColumnListEditor { @Override public void onValueRestricted(final String value) { this.restrictedColumns.add(value); setEditorEnabled(value, false, DataSetEditorConstants.INSTANCE.columnIsUsedInFilter()); } @Inject  ColumnListEditor(final SyncBeanManager beanManager,
                            final DataColumnDefDriver dataColumnDefDriver,
                            final Event<ColumnsChangedEvent> columnsChangedEvent,
                            final View view); @PostConstruct void init(); @Override Widget asWidget(); @Override void setAcceptableValues(final List<DataColumnDef> acceptableValues); @Override void onValueRestricted(final String value); @Override void onValueUnRestricted(final String value); @Override void setProviderType(final DataSetProviderType type); void clear(); @Override DataColumnDefEditor createEditorForTraversal(); @Override String getPathElement(final DataColumnDefEditor subEditor); @Override void setEditorChain(final EditorChain<DataColumnDef, DataColumnDefEditor> chain); @Override void setDelegate(final EditorDelegate<List<DataColumnDef>> delegate); @Override void showErrors(final List<EditorError> errors); @Override void flush(); @Override void onPropertyChange(final String... paths); @Override void setValue(final List<DataColumnDef> value); }
ColumnListEditor implements IsWidget, org.dashbuilder.dataset.client.editor.ColumnListEditor { @Override public void onValueRestricted(final String value) { this.restrictedColumns.add(value); setEditorEnabled(value, false, DataSetEditorConstants.INSTANCE.columnIsUsedInFilter()); } @Inject  ColumnListEditor(final SyncBeanManager beanManager,
                            final DataColumnDefDriver dataColumnDefDriver,
                            final Event<ColumnsChangedEvent> columnsChangedEvent,
                            final View view); @PostConstruct void init(); @Override Widget asWidget(); @Override void setAcceptableValues(final List<DataColumnDef> acceptableValues); @Override void onValueRestricted(final String value); @Override void onValueUnRestricted(final String value); @Override void setProviderType(final DataSetProviderType type); void clear(); @Override DataColumnDefEditor createEditorForTraversal(); @Override String getPathElement(final DataColumnDefEditor subEditor); @Override void setEditorChain(final EditorChain<DataColumnDef, DataColumnDefEditor> chain); @Override void setDelegate(final EditorDelegate<List<DataColumnDef>> delegate); @Override void showErrors(final List<EditorError> errors); @Override void flush(); @Override void onPropertyChange(final String... paths); @Override void setValue(final List<DataColumnDef> value); public View view; }