quoggles
Class QAuxiliary

java.lang.Object
  |
  +--quoggles.QAuxiliary

public class QAuxiliary
extends java.lang.Object


Field Summary
static javax.swing.JFileChooser fChooser
          FileChooser for saving / loading queries
static ListenerManager listenerManager
          The ListenerManager used to process representation change events from IBoxRepresentations.
private  QMain qMain
           
 
Constructor Summary
QAuxiliary(QMain q)
           
 
Method Summary
 void addBoxIcon(IBoxIcon boxIcon, javax.swing.JPanel iconPanel, java.lang.String name, java.lang.String description, java.lang.String version, java.awt.event.MouseListener ml, boolean firstAux)
          Adds a new IBoxIcon to the icon panel.
private  IBoxIcon checkBox(java.lang.String main)
          Checks whether or not the main class and the representation class can be loaded and returns the iconicPanel gotten from the representation.
 void loadIconsInto(javax.swing.JPanel panel, java.awt.event.MouseListener ml)
          Read the file containing descriptions of boxes and load them into the system.
 org.graffiti.graph.Graph loadQuery()
          Load a query from a file.
 void reset()
           
 void saveQuery(org.graffiti.graph.Graph queryGraph)
          Save the active query into a file chosen by the user.
 void saveSubQuery(org.graffiti.graph.Graph markedSubGraph)
          Save the active SUB query into a file chosen by the user.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

fChooser

public static final javax.swing.JFileChooser fChooser
FileChooser for saving / loading queries


listenerManager

public static final ListenerManager listenerManager
The ListenerManager used to process representation change events from IBoxRepresentations.


qMain

private QMain qMain
Constructor Detail

QAuxiliary

public QAuxiliary(QMain q)
Method Detail

loadIconsInto

public void loadIconsInto(javax.swing.JPanel panel,
                          java.awt.event.MouseListener ml)
                   throws BoxCreationFailedException
Read the file containing descriptions of boxes and load them into the system.

Parameters:
panel - the panel to which the icons are added
Throws:
BoxCreationFailedException

checkBox

private IBoxIcon checkBox(java.lang.String main)
                   throws BoxCreationFailedException
Checks whether or not the main class and the representation class can be loaded and returns the iconicPanel gotten from the representation.

Parameters:
main -
Returns:
BoxCreationFailedException

addBoxIcon

public void addBoxIcon(IBoxIcon boxIcon,
                       javax.swing.JPanel iconPanel,
                       java.lang.String name,
                       java.lang.String description,
                       java.lang.String version,
                       java.awt.event.MouseListener ml,
                       boolean firstAux)
Adds a new IBoxIcon to the icon panel.

Parameters:
boxIcon -

loadQuery

public org.graffiti.graph.Graph loadQuery()
                                   throws LoadFailedException
Load a query from a file. Discards active query.

LoadFailedException

saveQuery

public void saveQuery(org.graffiti.graph.Graph queryGraph)
               throws java.io.IOException
Save the active query into a file chosen by the user.

java.io.IOException

saveSubQuery

public void saveSubQuery(org.graffiti.graph.Graph markedSubGraph)
                  throws QueryExecutionException,
                         java.io.IOException
Save the active SUB query into a file chosen by the user.

QueryExecutionException
java.io.IOException

reset

public void reset()