Package com.vladsch.plugin.util.ui
Class SettingsComponents<T>
- java.lang.Object
-
- com.vladsch.plugin.util.ui.SettingsComponents<T>
-
- All Implemented Interfaces:
com.intellij.openapi.Disposable,SettingsConfigurable<T>
public abstract class SettingsComponents<T> extends java.lang.Object implements SettingsConfigurable<T>, com.intellij.openapi.Disposable
-
-
Nested Class Summary
-
Field Summary
Fields Modifier and Type Field Description protected TmyCachedSettingsprotected @Nullable Settable<T>[]myComponents
-
Constructor Summary
Constructors Constructor Description SettingsComponents()SettingsComponents(T settings)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description Tapply(T i)voidapply(T i, java.lang.Object... targets)@NotNull SettingsComponents.TextFieldWithBrowseButtonSettercomponent(@NotNull com.intellij.openapi.ui.TextFieldWithBrowseButton component, @NotNull Getter<java.lang.String> getter, @NotNull Setter<java.lang.String> setter)@NotNull SettingsComponents.TextFieldWithHistorySettercomponent(@NotNull com.intellij.ui.TextFieldWithHistory component, @NotNull Getter<java.util.List<java.lang.String>> historyGetter, @NotNull Setter<java.util.List<java.lang.String>> historySetter, @NotNull Getter<java.lang.String> getter, @NotNull Setter<java.lang.String> setter)@NotNull SettingsComponents.TextFieldWithHistoryWithBrowseButtonSettercomponent(@NotNull com.intellij.ui.TextFieldWithHistoryWithBrowseButton component, @NotNull Getter<java.util.List<java.lang.String>> historyGetter, @NotNull Setter<java.util.List<java.lang.String>> historySetter, @NotNull Getter<java.lang.String> getter, @NotNull Setter<java.lang.String> setter)@NotNull SettingsComponents.ColorCheckBoxSettercomponent(@NotNull CheckBoxWithColorChooser component, @NotNull Getter<java.awt.Color> getter, @NotNull Setter<java.awt.Color> setter)@NotNull SettingsComponents.ComboBoxSettercomponent(@NotNull ComboBoxAdapter<?> adapter, @NotNull javax.swing.JComboBox<java.lang.String> component, @NotNull Getter<java.lang.Integer> getter, @NotNull Setter<java.lang.Integer> setter)@NotNull SettingsComponents.ComboBoxBooleanSettercomponent(@NotNull ComboBoxBooleanAdapter<?> adapter, @NotNull javax.swing.JComboBox<java.lang.String> component, @NotNull Getter<java.lang.Boolean> getter, @NotNull Setter<java.lang.Boolean> setter)<V extends java.lang.Comparable<V>>
@NotNull SettingsComponents.FieldSetter<V>component(@NotNull Getter<V> fieldGetter, @NotNull Setter<V> fieldSetter, @NotNull Getter<V> getter, @NotNull Setter<V> setter)@NotNull SettingsComponents.JComponentSettableForm<T>component(@NotNull SettableForm<T> component, T settings)@NotNull SettingsComponents.CheckBoxSettercomponent(@NotNull javax.swing.JCheckBox component, @NotNull Getter<java.lang.Boolean> getter, @NotNull Setter<java.lang.Boolean> setter)@NotNull SettingsComponents.RadioButtonSettercomponent(@NotNull javax.swing.JRadioButton component, @NotNull Getter<java.lang.Boolean> getter, @NotNull Setter<java.lang.Boolean> setter)<V> @NotNull SettingsComponents.SpinnerSetter<V>component(@NotNull javax.swing.JSpinner component, @NotNull Getter<V> getter, @NotNull Setter<V> setter)@NotNull SettingsComponents.TextBoxSettercomponent(javax.swing.text.JTextComponent component, Getter<java.lang.String> getter, @NotNull Setter<java.lang.String> setter)<V extends com.intellij.ui.EditorTextField>
@NotNull SettingsComponents.EditorTextFieldSetter<V,java.lang.String>component(V component, @NotNull SettingsComponents.JComponentGetter<V,java.lang.String> componentGetter, @NotNull SettingsComponents.JComponentSetter<V,java.lang.String> componentSetter, @NotNull Getter<java.lang.String> getter, @NotNull Setter<java.lang.String> setter)<V extends com.intellij.ui.EditorTextField>
@NotNull SettingsComponents.EditorTextFieldSetter<V,java.lang.String>component(V component, @NotNull SettingsComponents.JComponentGetter<V,java.lang.String> componentGetter, @NotNull SettingsComponents.JComponentSetter<V,java.lang.String> componentSetter, @NotNull Getter<java.lang.String> getter, @NotNull Setter<java.lang.String> setter, @NotNull java.util.Comparator<java.lang.String> comparator)@NotNull SettingsComponents.ColorCheckBoxEnabledSettercomponentEnabled(@NotNull CheckBoxWithColorChooser component, @NotNull Getter<java.lang.Boolean> getter, @NotNull Setter<java.lang.Boolean> setter)@NotNull SettingsComponents.ComboBoxStringSettercomponentString(@NotNull ComboBoxAdapter<?> adapter, @NotNull javax.swing.JComboBox<java.lang.String> component, @NotNull Getter<java.lang.String> getter, @NotNull Setter<java.lang.String> setter)protected abstract Settable<T>[]createComponents(T i)voiddispose()voidforAllComponents(T i, @NotNull java.util.function.Consumer<Settable<T>> runnable)voidforAllTargets(T i, @NotNull java.lang.Object[] targets, @NotNull java.util.function.Consumer<Settable<T>> runnable)Settable<T>[]getComponents(T i)java.util.Set<Settable<T>>getComponentSet(T i)booleanisModified(T i)<C> Cnotrace(@NotNull java.lang.String name, C component)voidreset(T i)voidreset(T i, java.lang.Object... targets)@NotNull com.vladsch.plugin.util.ui.SettingsComponents.TraceComponenttrace(@NotNull java.lang.String name, @NotNull Settable component)
-
-
-
Constructor Detail
-
SettingsComponents
public SettingsComponents()
-
SettingsComponents
public SettingsComponents(@Nullable T settings)
-
-
Method Detail
-
dispose
public void dispose()
- Specified by:
disposein interfacecom.intellij.openapi.Disposable
-
forAllComponents
public void forAllComponents(@NotNull T i, @NotNull @NotNull java.util.function.Consumer<Settable<T>> runnable)
-
forAllTargets
public void forAllTargets(@NotNull T i, @NotNull @NotNull java.lang.Object[] targets, @NotNull @NotNull java.util.function.Consumer<Settable<T>> runnable)
-
reset
public void reset(@NotNull T i)- Specified by:
resetin interfaceSettingsConfigurable<T>
-
apply
@NotNull public T apply(@NotNull T i)
- Specified by:
applyin interfaceSettingsConfigurable<T>
-
isModified
public boolean isModified(@NotNull T i)- Specified by:
isModifiedin interfaceSettingsConfigurable<T>
-
apply
public void apply(@NotNull T i, java.lang.Object... targets)
-
reset
public void reset(@NotNull T i, java.lang.Object... targets)
-
trace
@NotNull public @NotNull com.vladsch.plugin.util.ui.SettingsComponents.TraceComponent trace(@NotNull @NotNull java.lang.String name, @NotNull @NotNull Settable component)
-
notrace
public <C> C notrace(@NotNull @NotNull java.lang.String name, @NotNull C component)
-
component
@NotNull public @NotNull SettingsComponents.CheckBoxSetter component(@NotNull @NotNull javax.swing.JCheckBox component, @NotNull @NotNull Getter<java.lang.Boolean> getter, @NotNull @NotNull Setter<java.lang.Boolean> setter)
-
component
@NotNull public @NotNull SettingsComponents.RadioButtonSetter component(@NotNull @NotNull javax.swing.JRadioButton component, @NotNull @NotNull Getter<java.lang.Boolean> getter, @NotNull @NotNull Setter<java.lang.Boolean> setter)
-
component
@NotNull public <V extends java.lang.Comparable<V>> @NotNull SettingsComponents.FieldSetter<V> component(@NotNull @NotNull Getter<V> fieldGetter, @NotNull @NotNull Setter<V> fieldSetter, @NotNull @NotNull Getter<V> getter, @NotNull @NotNull Setter<V> setter)
-
component
@NotNull public <V> @NotNull SettingsComponents.SpinnerSetter<V> component(@NotNull @NotNull javax.swing.JSpinner component, @NotNull @NotNull Getter<V> getter, @NotNull @NotNull Setter<V> setter)
-
component
@NotNull public @NotNull SettingsComponents.TextBoxSetter component(javax.swing.text.JTextComponent component, Getter<java.lang.String> getter, @NotNull @NotNull Setter<java.lang.String> setter)
-
component
@NotNull public @NotNull SettingsComponents.ColorCheckBoxSetter component(@NotNull @NotNull CheckBoxWithColorChooser component, @NotNull @NotNull Getter<java.awt.Color> getter, @NotNull @NotNull Setter<java.awt.Color> setter)
-
componentEnabled
@NotNull public @NotNull SettingsComponents.ColorCheckBoxEnabledSetter componentEnabled(@NotNull @NotNull CheckBoxWithColorChooser component, @NotNull @NotNull Getter<java.lang.Boolean> getter, @NotNull @NotNull Setter<java.lang.Boolean> setter)
-
component
@NotNull public @NotNull SettingsComponents.TextFieldWithHistorySetter component(@NotNull @NotNull com.intellij.ui.TextFieldWithHistory component, @NotNull @NotNull Getter<java.util.List<java.lang.String>> historyGetter, @NotNull @NotNull Setter<java.util.List<java.lang.String>> historySetter, @NotNull @NotNull Getter<java.lang.String> getter, @NotNull @NotNull Setter<java.lang.String> setter)
-
component
@NotNull public @NotNull SettingsComponents.TextFieldWithBrowseButtonSetter component(@NotNull @NotNull com.intellij.openapi.ui.TextFieldWithBrowseButton component, @NotNull @NotNull Getter<java.lang.String> getter, @NotNull @NotNull Setter<java.lang.String> setter)
-
component
@NotNull public @NotNull SettingsComponents.TextFieldWithHistoryWithBrowseButtonSetter component(@NotNull @NotNull com.intellij.ui.TextFieldWithHistoryWithBrowseButton component, @NotNull @NotNull Getter<java.util.List<java.lang.String>> historyGetter, @NotNull @NotNull Setter<java.util.List<java.lang.String>> historySetter, @NotNull @NotNull Getter<java.lang.String> getter, @NotNull @NotNull Setter<java.lang.String> setter)
-
component
@NotNull public <V extends com.intellij.ui.EditorTextField> @NotNull SettingsComponents.EditorTextFieldSetter<V,java.lang.String> component(@NotNull V component, @NotNull @NotNull SettingsComponents.JComponentGetter<V,java.lang.String> componentGetter, @NotNull @NotNull SettingsComponents.JComponentSetter<V,java.lang.String> componentSetter, @NotNull @NotNull Getter<java.lang.String> getter, @NotNull @NotNull Setter<java.lang.String> setter, @NotNull @NotNull java.util.Comparator<java.lang.String> comparator)
-
component
@NotNull public <V extends com.intellij.ui.EditorTextField> @NotNull SettingsComponents.EditorTextFieldSetter<V,java.lang.String> component(@NotNull V component, @NotNull @NotNull SettingsComponents.JComponentGetter<V,java.lang.String> componentGetter, @NotNull @NotNull SettingsComponents.JComponentSetter<V,java.lang.String> componentSetter, @NotNull @NotNull Getter<java.lang.String> getter, @NotNull @NotNull Setter<java.lang.String> setter)
-
component
@NotNull public @NotNull SettingsComponents.ComboBoxBooleanSetter component(@NotNull @NotNull ComboBoxBooleanAdapter<?> adapter, @NotNull @NotNull javax.swing.JComboBox<java.lang.String> component, @NotNull @NotNull Getter<java.lang.Boolean> getter, @NotNull @NotNull Setter<java.lang.Boolean> setter)
-
component
@NotNull public @NotNull SettingsComponents.ComboBoxSetter component(@NotNull @NotNull ComboBoxAdapter<?> adapter, @NotNull @NotNull javax.swing.JComboBox<java.lang.String> component, @NotNull @NotNull Getter<java.lang.Integer> getter, @NotNull @NotNull Setter<java.lang.Integer> setter)
-
componentString
@NotNull public @NotNull SettingsComponents.ComboBoxStringSetter componentString(@NotNull @NotNull ComboBoxAdapter<?> adapter, @NotNull @NotNull javax.swing.JComboBox<java.lang.String> component, @NotNull @NotNull Getter<java.lang.String> getter, @NotNull @NotNull Setter<java.lang.String> setter)
-
component
@NotNull public @NotNull SettingsComponents.JComponentSettableForm<T> component(@NotNull @NotNull SettableForm<T> component, @NotNull T settings)
-
-