org.bklab.flow.factory.CheckboxGroupFactory Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of fluent-vaadin-flow Show documentation
Show all versions of fluent-vaadin-flow Show documentation
Broderick Labs for fluent vaadin flow. Inherits common Vaadin components.
package org.bklab.flow.factory;
import com.vaadin.flow.component.ItemLabelGenerator;
import com.vaadin.flow.component.checkbox.CheckboxGroup;
import com.vaadin.flow.component.checkbox.dataview.CheckboxGroupDataView;
import com.vaadin.flow.component.checkbox.dataview.CheckboxGroupListDataView;
import com.vaadin.flow.data.provider.DataProvider;
import com.vaadin.flow.data.provider.InMemoryDataProvider;
import com.vaadin.flow.data.provider.ListDataProvider;
import com.vaadin.flow.data.selection.MultiSelectionListener;
import com.vaadin.flow.function.SerializablePredicate;
import org.bklab.flow.FlowFactory;
import org.bklab.flow.base.*;
import java.util.Set;
import java.util.stream.Stream;
public class CheckboxGroupFactory extends FlowFactory, CheckboxGroupFactory> implements
GeneratedVaadinCheckboxGroupFactory, CheckboxGroupFactory>,
HasItemComponentsFactory, CheckboxGroupFactory>,
HasSizeFactory, CheckboxGroupFactory>,
HasValidationFactory, CheckboxGroupFactory>,
MultiSelectFactory, CheckboxGroupFactory>,
HasListDataViewFactory, CheckboxGroup, CheckboxGroupFactory>,
HasDataViewFactory, CheckboxGroup, CheckboxGroupFactory>,
HasHelperFactory, CheckboxGroupFactory> {
public CheckboxGroupFactory() {
this(new CheckboxGroup<>());
}
public CheckboxGroupFactory(CheckboxGroup checkbox) {
super(checkbox);
}
public CheckboxGroupFactory readOnly(boolean readOnly) {
get().setReadOnly(readOnly);
return this;
}
public CheckboxGroupFactory value(Set value) {
get().setValue(value);
return this;
}
public CheckboxGroupFactory items(ListDataProvider items) {
get().setItems(items);
return this;
}
public CheckboxGroupFactory items(InMemoryDataProvider items) {
get().setItems(items);
return this;
}
@Deprecated
public CheckboxGroupFactory items(Stream items) {
get().setItems(items);
return this;
}
@SafeVarargs
public final CheckboxGroupFactory items(T... items) {
get().setItems(items);
return this;
}
public CheckboxGroupFactory label(String label) {
get().setLabel(label);
return this;
}
public CheckboxGroupFactory updateSelection(Set addedItems, Set removedItems) {
get().updateSelection(addedItems, removedItems);
return this;
}
public CheckboxGroupFactory dataProvider(DataProvider dataProvider) {
get().setDataProvider(dataProvider);
return this;
}
public CheckboxGroupFactory invalid(boolean invalid) {
get().setInvalid(invalid);
return this;
}
public CheckboxGroupFactory required(boolean required) {
get().setRequired(required);
return this;
}
public CheckboxGroupFactory errorMessage(String errorMessage) {
get().setErrorMessage(errorMessage);
return this;
}
public CheckboxGroupFactory selectionListener(MultiSelectionListener, T> listener) {
get().addSelectionListener(listener);
return this;
}
public CheckboxGroupFactory itemEnabledProvider(SerializablePredicate itemEnabledProvider) {
get().setItemEnabledProvider(itemEnabledProvider);
return this;
}
public CheckboxGroupFactory itemLabelGenerator(ItemLabelGenerator itemLabelGenerator) {
get().setItemLabelGenerator(itemLabelGenerator);
return this;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy