zeus.generator.agent
Class TaskAttributeListener

java.lang.Object
  extended byzeus.generator.agent.TaskAttributeListener
All Implemented Interfaces:
java.util.EventListener, javax.swing.event.ListSelectionListener

public class TaskAttributeListener
extends java.lang.Object
implements javax.swing.event.ListSelectionListener

Handle all events arising from the TaskAttributePanel, pricipally selecting a different task or fact row.


Field Summary
private  AttributeModel attModel
           
private  javax.swing.JTable attTable
           
private  java.lang.String currentTask
           
private  FactModel factModel
           
private  javax.swing.JTable factTable
           
private  GeneratorModel genModel
           
private  java.util.List restrictions
           
private  TaskModel taskModel
           
private  javax.swing.JTable taskTable
           
 
Constructor Summary
TaskAttributeListener(javax.swing.JTable taskTable, TaskModel taskModel, javax.swing.JTable factTable, FactModel factModel, javax.swing.JTable attTable, AttributeModel attModel, GeneratorModel genModel, AgentDescription agent)
           
 
Method Summary
private  void factSelected()
          Fired when a fact row is selected.
 java.util.List getRestrictions()
          Retrieve the list of restrictions.
private  void loadAttributeRestrictions()
          Restore and restrictions that are associated with the current attribute table.
private  void saveAttributeRestrictions()
          Save any attribute restrictions in the current attribute table.
private  void taskSelected()
          Fired when a task row is selected.
 void valueChanged(javax.swing.event.ListSelectionEvent e)
          Event handling interface.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

taskTable

private javax.swing.JTable taskTable

factTable

private javax.swing.JTable factTable

attTable

private javax.swing.JTable attTable

taskModel

private TaskModel taskModel

factModel

private FactModel factModel

attModel

private AttributeModel attModel

genModel

private GeneratorModel genModel

restrictions

private java.util.List restrictions

currentTask

private java.lang.String currentTask
Constructor Detail

TaskAttributeListener

public TaskAttributeListener(javax.swing.JTable taskTable,
                             TaskModel taskModel,
                             javax.swing.JTable factTable,
                             FactModel factModel,
                             javax.swing.JTable attTable,
                             AttributeModel attModel,
                             GeneratorModel genModel,
                             AgentDescription agent)
Method Detail

valueChanged

public void valueChanged(javax.swing.event.ListSelectionEvent e)
Event handling interface.

Specified by:
valueChanged in interface javax.swing.event.ListSelectionListener

taskSelected

private void taskSelected()
Fired when a task row is selected. Saves the attribute restrictions currently active, then loads the new fact table associated with this task.


factSelected

private void factSelected()
Fired when a fact row is selected. Saves current attribute restrictions, loads the attribute table associated with the new fact, and loads the restrictions into it.


saveAttributeRestrictions

private void saveAttributeRestrictions()
Save any attribute restrictions in the current attribute table. Existing design of AttributeModel made it a serious problem to save the restriction information in there, so it is extracted and saved here.


loadAttributeRestrictions

private void loadAttributeRestrictions()
Restore and restrictions that are associated with the current attribute table.


getRestrictions

public java.util.List getRestrictions()
Retrieve the list of restrictions. Pricipally used for saving them.



Copyright © 2000-2003 BT Exact Technologies. All Rights Reserved.