private class ALDNativeArray2DDataIOSwing.ArrayConfigPanel extends ALDSwingComponent implements ALDSwingValueChangeListener, ActionListener
This button has a collection configuration window attached to it where specific data is stored and accessable.
Modifier and Type | Field and Description |
---|---|
private Class<?> |
arrayClass
Class of array to configure.
|
private ALDParameterDescriptor |
arrayDescriptor
Descriptor of parameter linked to array.
|
private Field |
arrayField
Parameter field of array to configure.
|
private JButton |
confButton
Button to open configuration window.
|
private JPanel |
configPanel
GUI component associated with this Swing component.
|
private ALDNativeArray2DDataIOSwing.ArrayConfigWindow |
confWin
Collection configuration window.
|
private JButton |
resetButton
Button to reset array.
|
listenerList
Constructor and Description |
---|
ArrayConfigPanel(Field field,
Class<?> cl,
Object obj,
ALDParameterDescriptor descr)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
actionPerformed(ActionEvent e) |
void |
disableComponent()
Method to disable the component, i.e. all graphical elements, to
prohibit parameter changes.
|
void |
dispose()
Disposes all resources of this window.
|
void |
enableComponent()
Method to enable the component with all graphical elements again.
|
JComponent |
getJComponent()
Method to request the provider's GUI element.
|
void |
handleValueChangeEvent(ALDSwingValueChangeEvent event)
Method which is called on event occurence.
|
Object |
readData(Field field,
Class<?> cl)
Gets the data from the configuration window.
|
void |
setValue(Field field,
Class<?> cl,
Object value)
Gets the data from the configuration window.
|
addValueChangeEventListener, fireALDSwingValueChangeEvent, removeValueChangeEventListener
private JPanel configPanel
private JButton confButton
private JButton resetButton
private ALDNativeArray2DDataIOSwing.ArrayConfigWindow confWin
private Class<?> arrayClass
private Field arrayField
private ALDParameterDescriptor arrayDescriptor
public ArrayConfigPanel(Field field, Class<?> cl, Object obj, ALDParameterDescriptor descr)
field
- Field of collection.cl
- Class of collection.obj
- Default object.descr
- Optional descriptor for additional information.public void setValue(Field field, Class<?> cl, Object value)
field
- Field of collection.cl
- Class of collection.value
- Default object value.public Object readData(Field field, Class<?> cl) throws ALDDataIOProviderException
field
- Field of collection.cl
- Class of collection.ALDDataIOProviderException
- Thrown on read failure.public JComponent getJComponent()
ALDSwingComponent
getJComponent
in class ALDSwingComponent
public void handleValueChangeEvent(ALDSwingValueChangeEvent event)
ALDSwingValueChangeListener
handleValueChangeEvent
in interface ALDSwingValueChangeListener
event
- Event to be handled.public void disableComponent()
ALDSwingComponent
disableComponent
in class ALDSwingComponent
public void enableComponent()
ALDSwingComponent
enableComponent
in class ALDSwingComponent
public void dispose()
dispose
in class ALDSwingComponent
public void actionPerformed(ActionEvent e)
actionPerformed
in interface ActionListener
Copyright © 2010–2021 Martin Luther University Halle-Wittenberg, Institute of Computer Science, Pattern Recognition and Bioinformatics. All rights reserved.