de.unihalle.informatik.Alida.dataio.provider.swing
Class ALDNativeArray1DDataIOSwing.ArrayConfigButton

java.lang.Object
  extended by de.unihalle.informatik.Alida.dataio.provider.swing.events.ALDSwingValueChangeReporter
      extended by de.unihalle.informatik.Alida.dataio.provider.swing.components.ALDSwingComponent
          extended by de.unihalle.informatik.Alida.dataio.provider.swing.ALDNativeArray1DDataIOSwing.ArrayConfigButton
All Implemented Interfaces:
ALDSwingValueChangeListener, java.util.EventListener
Enclosing class:
ALDNativeArray1DDataIOSwing

private class ALDNativeArray1DDataIOSwing.ArrayConfigButton
extends ALDSwingComponent
implements ALDSwingValueChangeListener

GUI element for configuring 1D arrays of native data types and wrapper.

This button has an array configuration window attached to it where specific data is stored and accessable.

Author:
moeller

Field Summary
private  javax.swing.JButton confButton
          GUI component associated with this Swing component.
private  ALDNativeArray1DDataIOSwing.ArrayConfigWindow confWin
          Array configuration window.
 
Fields inherited from class de.unihalle.informatik.Alida.dataio.provider.swing.events.ALDSwingValueChangeReporter
listenerList
 
Constructor Summary
ALDNativeArray1DDataIOSwing.ArrayConfigButton(java.lang.reflect.Field field, java.lang.Class<?> cl, java.lang.Object obj, ALDParameterDescriptor descr)
          Constructor.
 
Method Summary
 void disableComponent()
          Method to disable the component, i.e. all graphical elements, to prohibit parameter changes.
 void enableComponent()
          Method to enable the component with all graphical elements again.
 javax.swing.JComponent getJComponent()
          Method to request the provider's GUI element.
 void handleValueChangeEvent(ALDSwingValueChangeEvent event)
          Method which is called on event occurence.
 java.lang.Object readData(java.lang.reflect.Field field, java.lang.Class<?> cl)
          Gets the data from the configuration window.
 void setValue(java.lang.reflect.Field field, java.lang.Class<?> cl, java.lang.Object value)
          Gets the data from the configuration window.
 
Methods inherited from class de.unihalle.informatik.Alida.dataio.provider.swing.events.ALDSwingValueChangeReporter
addValueChangeEventListener, fireALDSwingValueChangeEvent, removeValueChangeEventListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

confButton

private javax.swing.JButton confButton
GUI component associated with this Swing component.


confWin

private ALDNativeArray1DDataIOSwing.ArrayConfigWindow confWin
Array configuration window.

Constructor Detail

ALDNativeArray1DDataIOSwing.ArrayConfigButton

public ALDNativeArray1DDataIOSwing.ArrayConfigButton(java.lang.reflect.Field field,
                                                     java.lang.Class<?> cl,
                                                     java.lang.Object obj,
                                                     ALDParameterDescriptor descr)
Constructor.

Parameters:
field - Field of collection.
cl - Class of collection.
obj - Default object.
descr - Optional descriptor for additional information.
Method Detail

disableComponent

public void disableComponent()
Description copied from class: ALDSwingComponent
Method to disable the component, i.e. all graphical elements, to prohibit parameter changes.

Specified by:
disableComponent in class ALDSwingComponent

enableComponent

public void enableComponent()
Description copied from class: ALDSwingComponent
Method to enable the component with all graphical elements again.

Specified by:
enableComponent in class ALDSwingComponent

getJComponent

public javax.swing.JComponent getJComponent()
Description copied from class: ALDSwingComponent
Method to request the provider's GUI element.

Specified by:
getJComponent in class ALDSwingComponent
Returns:
Component to be integrated in a graphical user interface.

handleValueChangeEvent

public void handleValueChangeEvent(ALDSwingValueChangeEvent event)
Description copied from interface: ALDSwingValueChangeListener
Method which is called on event occurence.

Specified by:
handleValueChangeEvent in interface ALDSwingValueChangeListener
Parameters:
event - Event to be handled.

readData

public java.lang.Object readData(java.lang.reflect.Field field,
                                 java.lang.Class<?> cl)
                          throws ALDDataIOProviderException
Gets the data from the configuration window.

Parameters:
field - Field of collection.
cl - Class of collection.
obj - Default object.
Returns:
Current data.
Throws:
ALDDataIOProviderException

setValue

public void setValue(java.lang.reflect.Field field,
                     java.lang.Class<?> cl,
                     java.lang.Object value)
Gets the data from the configuration window.

Parameters:
field - Field of collection.
cl - Class of collection.
obj - Default object.