T - The input type of the widget.W - The type of UI component housing the widget.public abstract class AbstractInputWidget<T,W> extends AbstractWrapperPlugin<WidgetModel> implements InputWidget<T,W>
| Constructor and Description |
|---|
AbstractInputWidget() |
| Modifier and Type | Method and Description |
|---|---|
WidgetModel |
get()
Gets the data object currently associated with this plugin.
|
Class<WidgetModel> |
getType()
Gets the type associated with the object.
|
boolean |
isLabeled()
Returns true iff the widget should be labeled with the parameter label.
|
boolean |
isMessage()
Returns true iff the widget should be considered a read-only "message"
rather than a bidirectional input widget.
|
void |
set(WidgetModel model)
Associates the given data object with this plugin.
|
boolean |
supports(WidgetModel model)
Gets whether this object is compatible with the given data object.
|
void |
updateModel()
Updates the model to reflect the latest widget state.
|
compareTo, getInfo, getPriority, setInfo, setPriority, toStringcontext, getContext, setContextclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetValue, refreshWidgetcontext, getContext, setContextgetPriority, setPrioritycompareTogetInfo, setInfogetComponent, getComponentTypepublic void updateModel()
InputWidgetupdateModel in interface InputWidget<T,W>public boolean isLabeled()
InputWidgetMessageWidgets.isLabeled in interface InputWidget<T,W>WidgetModel.getWidgetLabel()public boolean isMessage()
InputWidgetInputPanel.isMessageOnly() method will return true iff this method
returns true for all of its widgets.isMessage in interface InputWidget<T,W>public void set(WidgetModel model)
WrapperPluginTyped.supports(T) must return true).set in interface WrapperPlugin<WidgetModel>set in interface InputWidget<T,W>set in class AbstractWrapperPlugin<WidgetModel>model - The data object to associate with the plugin.public WidgetModel get()
WrapperPluginget in interface WrapperPlugin<WidgetModel>get in interface InputWidget<T,W>get in class AbstractWrapperPlugin<WidgetModel>public boolean supports(WidgetModel model)
Typed
By default, this method will return true always, since the type is
known to be compatible. But individual implementations may have other
requirements beyond class assignability.
supports in interface Typed<WidgetModel>supports in interface InputWidget<T,W>supports in class AbstractTypedPlugin<WidgetModel>public Class<WidgetModel> getType()
TypedgetType in interface Typed<WidgetModel>Copyright © 2009–2016 SciJava. All rights reserved.