org.scijava.widget
Interface InputPanel<P,W>

Type Parameters:
P - The type of UI component housing the input panel itself.
W - The type of UI component housing each input widget.
All Superinterfaces:
UIComponent<P>
All Known Implementing Classes:
AbstractInputPanel

public interface InputPanel<P,W>
extends UIComponent<P>

Flexible panel-building interface, for use with UIs that prompt for input values of various types.

Author:
Curtis Rueden

Method Summary
 void addWidget(InputWidget<?,W> widget)
          Adds a widget to the panel.
 Object getValue(String name)
          Returns the value of the given widget's input.
 Class<W> getWidgetComponentType()
          Gets the type of the UI component housing the panel's widgets.
 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).
 boolean supports(InputWidget<?,?> widget)
          Gets whether the given widget would be appropriate for the given panel.
 
Methods inherited from interface org.scijava.widget.UIComponent
getComponent, getComponentType
 

Method Detail

supports

boolean supports(InputWidget<?,?> widget)
Gets whether the given widget would be appropriate for the given panel.


addWidget

void addWidget(InputWidget<?,W> widget)
Adds a widget to the panel.


getValue

Object getValue(String name)
Returns the value of the given widget's input.

Parameters:
name - unique name identifying this field

getWidgetCount

int getWidgetCount()
Gets the number of active widgets in the input panel.


hasWidgets

boolean hasWidgets()
Gets whether the input panel has any active widgets.


isMessageOnly

boolean isMessageOnly()
Returns true if the input panel consists of only messages.


refresh

void refresh()
Updates the widgets to reflect the most recent parameter value(s).


getWidgetComponentType

Class<W> getWidgetComponentType()
Gets the type of the UI component housing the panel's widgets.



Copyright © 2009–2014 SciJava. All rights reserved.