All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.bklab.flow.base.MultiSelectFactory Maven / Gradle / Ivy

There is a newer version: 22.0.1
Show newest version
package org.bklab.flow.base;

import com.vaadin.flow.component.Component;
import com.vaadin.flow.data.selection.MultiSelect;
import com.vaadin.flow.data.selection.MultiSelectionListener;
import org.bklab.flow.IFluentFlowFactory;

import java.util.Set;

public interface MultiSelectFactory, E extends MultiSelectFactory>
        extends IFluentFlowFactory {

    default E value(Set value) {
        get().setValue(value);
        return thisObject();
    }

    default E updateSelection(Set addedItems, Set removedItems) {
        get().updateSelection(addedItems, removedItems);
        return thisObject();
    }

    default E deselectAll() {
        get().deselectAll();
        return thisObject();
    }

    default E select(T... select) {
        get().select(select);
        return thisObject();
    }

    default E select(Iterable select) {
        get().select(select);
        return thisObject();
    }

    default E deselect(T[] deselect) {
        get().deselect(deselect);
        return thisObject();
    }

    default E deselect(Iterable deselect) {
        get().deselect(deselect);
        return thisObject();
    }

    default E selectionListener(MultiSelectionListener selectionListener) {
        get().addSelectionListener(selectionListener);
        return thisObject();
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy