P
- The type of UI component housing the input panel itself.W
- The type of UI component housing each input widget.public abstract class AbstractInputPanel<P,W> extends Object implements InputPanel<P,W>
InputPanel
implementations.Modifier and Type | Field and Description |
---|---|
protected Map<String,InputWidget<?,W>> |
widgets
Table of widgets.
|
Constructor and Description |
---|
AbstractInputPanel() |
Modifier and Type | Method and Description |
---|---|
void |
addWidget(InputWidget<?,W> widget)
Adds a widget to the panel.
|
Object |
getValue(String name)
Returns the value of the given widget's input.
|
InputWidget<?,W> |
getWidget(String name)
Gets the widget with the provided name.
|
int |
getWidgetCount()
Gets the number of active widgets in the input panel.
|
boolean |
hasWidgets()
Gets whether the input panel has any active widgets.
|
boolean |
isMessageOnly()
Returns true if the input panel consists of only messages.
|
void |
refresh()
Updates the widgets to reflect the most recent parameter value(s).
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getWidgetComponentType, supports
getComponent, getComponentType
protected Map<String,InputWidget<?,W>> widgets
public void addWidget(InputWidget<?,W> widget)
InputPanel
addWidget
in interface InputPanel<P,W>
public InputWidget<?,W> getWidget(String name)
InputPanel
getWidget
in interface InputPanel<P,W>
public Object getValue(String name)
InputPanel
getValue
in interface InputPanel<P,W>
name
- unique name identifying this fieldpublic int getWidgetCount()
InputPanel
getWidgetCount
in interface InputPanel<P,W>
public boolean hasWidgets()
InputPanel
hasWidgets
in interface InputPanel<P,W>
public boolean isMessageOnly()
InputPanel
isMessageOnly
in interface InputPanel<P,W>
public void refresh()
InputPanel
refresh
in interface InputPanel<P,W>
Copyright © 2015–2022 SciJava. All rights reserved.