org.bklab.flow.factory.CustomFieldFactory 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.Key;
import com.vaadin.flow.component.KeyModifier;
import com.vaadin.flow.component.customfield.CustomField;
import org.bklab.flow.FlowFactory;
import org.bklab.flow.base.AbstractFieldFactory;
import org.bklab.flow.base.HasSizeFactory;
import org.bklab.flow.base.HasValidationFactory;
public class CustomFieldFactory extends FlowFactory, CustomFieldFactory> implements
AbstractFieldFactory, CustomFieldFactory>,
HasSizeFactory, CustomFieldFactory>,
HasValidationFactory, CustomFieldFactory> {
public CustomFieldFactory(CustomField component) {
super(component);
}
public CustomFieldFactory label(String label) {
get().setLabel(label);
return this;
}
public CustomFieldFactory invalid(boolean invalid) {
get().setInvalid(invalid);
return this;
}
public CustomFieldFactory errorMessage(String errorMessage) {
get().setErrorMessage(errorMessage);
return this;
}
public CustomFieldFactory focusShortcut(Key key, KeyModifier... keyModifiers) {
get().addFocusShortcut(key, keyModifiers);
return this;
}
public CustomFieldFactory tabIndex(int tabIndex) {
get().setTabIndex(tabIndex);
return this;
}
public CustomFieldFactory blur() {
get().blur();
return this;
}
public CustomFieldFactory focus() {
get().focus();
return this;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy