kaos.kpat.applet
Class QueryTabBuilder

java.lang.Object
  extended by kaos.kpat.applet.QueryTabBuilder

public class QueryTabBuilder
extends java.lang.Object

The QueryTabBuilder helps to build the components of the Tab Query in KPAT.


Field Summary
protected static java.lang.String _configPath
           
protected  javax.swing.JComboBox _connectorComboBox
           
protected  java.lang.String _conValue
           
protected  java.util.Vector _conVector
           
protected  boolean _descComboInUse
           
protected  javax.swing.JTextField _descTextField
           
protected  kaos.kpat.applet.QueryTabBuilder.SubjectButton _e1Button
           
protected  boolean _e1Pressed
           
protected  kaos.kpat.applet.QueryTabBuilder.SubjectButton _e1T2Button
           
protected  boolean _e1T2Pressed
           
protected  javax.swing.JTextField _e1T2TextField
           
protected  javax.swing.JTextField _e1TextField
           
protected  kaos.kpat.applet.QueryTabBuilder.SubjectButton _e2Button
           
protected  boolean _e2Pressed
           
protected  kaos.kpat.applet.QueryTabBuilder.SubjectButton _e2T2Button
           
protected  boolean _e2T2Pressed
           
protected  javax.swing.JTextField _e2T2TextField
           
protected  javax.swing.JTextField _e2TextField
           
protected  kaos.kpat.applet.QueryTabBuilder.SubjectButton _e3Button
           
protected  boolean _e3Pressed
           
protected  kaos.kpat.applet.QueryTabBuilder.SubjectButton _e3T2Button
           
protected  boolean _e3T2Pressed
           
protected  javax.swing.JTextField _e3T2TextField
           
protected  javax.swing.JTextField _e3TextField
           
protected  java.util.Hashtable _infoMenu2Hashtable
           
protected  java.util.Hashtable _infoMenuHashtable
           
protected  java.util.Hashtable _infoMenuRangeHT
           
protected  javax.swing.JButton _loadButton
           
protected  javax.swing.JMenu _namespMenu
           
protected  java.lang.String[] _nsp
           
protected  java.lang.String[] _nsp2
           
protected  java.util.Hashtable _objectTable
           
protected  javax.swing.JTextField _qTempTextField
           
protected  javax.swing.DefaultComboBoxModel _queryComboModel
           
protected  javax.swing.JPanel _queryEditorPanel
           
protected  javax.swing.JPanel _queryTab
           
protected  javax.swing.JPanel _queryTemplateEditorPanel
           
protected  QueryTemplateObject _queryTemplateObj
           
protected  javax.swing.JPanel _queryTemplatePanel
           
protected  boolean _range1Pressed
           
protected  boolean _range2Pressed
           
protected  boolean _range3Pressed
           
protected  boolean _range4Pressed
           
protected  java.util.Vector _rangeClassesVector
           
protected  javax.swing.JLabel _rangeLabel
           
protected  javax.swing.JLabel _rangeLabel2
           
protected  javax.swing.JLabel _rangeLabel3
           
protected  javax.swing.JLabel _rangeLabel4
           
protected  javax.swing.JMenu _rangeMenu
           
protected  kaos.kpat.applet.QueryTabBuilder.RangeButton _rangesBtn
           
protected  kaos.kpat.applet.QueryTabBuilder.RangeButton _rangesBtn2
           
protected  kaos.kpat.applet.QueryTabBuilder.RangeButton _rangesBtn3
           
protected  kaos.kpat.applet.QueryTabBuilder.RangeButton _rangesBtn4
           
protected  javax.swing.JButton _removeButton
           
protected  javax.swing.DefaultListModel _resultsListModel
           
protected  javax.swing.JTextField _sub1TextField
           
protected  javax.swing.JTextField _sub2TextField
           
protected  javax.swing.JPopupMenu _subjectMenu
           
protected  javax.swing.JTextField _t1TextField
           
protected  javax.swing.JTextField _t2TextField
           
protected  javax.swing.JTabbedPane _tabPane
           
protected  javax.swing.JList _templateList
           
protected  javax.swing.DefaultListModel _templateListModel
           
protected  javax.swing.JPopupMenu _tempMenu
           
protected  javax.swing.JPopupMenu _tempMenu2
           
protected  javax.swing.JPopupMenu _tempMenu3
           
protected  javax.swing.JPopupMenu _tempMenu4
           
protected  javax.swing.JTextField _tempTextField
           
protected  javax.swing.JTextField _val1TextField
           
protected  javax.swing.JTextField _val2TextField
           
protected  java.util.Vector _variablesVector
           
protected  javax.swing.JMenu _varMenu
           
protected  javax.swing.JComboBox _varQueryComboBox
           
protected  java.lang.String _varQueryStr
           
 
Constructor Summary
QueryTabBuilder(TunnelClient tunnelClient)
           
 
Method Summary
protected  void buildExecuteQueryTab()
           
protected  QueryTemplateObject buildQueryFromElements()
          Build the query object using the selected elements from the tab
protected  void buildQueryTemplateTab()
           
 void createGui()
           
protected  void displaySelectedQuery()
          Get all the queries previously saved to a file.
protected  java.util.Vector getConVector()
           
protected  java.util.Vector getDataVector()
           
protected  java.lang.String[] getNamespaces()
           
 javax.swing.JPanel getQueryTab()
           
protected  void getRangeMenus(java.lang.String rangeClass, javax.swing.JPopupMenu tempMenu)
          Get the range information from the query template object.
 javax.swing.JPanel getResultsPanel()
           
protected  java.lang.String getShortName(java.lang.String name)
           
protected  java.util.Vector getVarVector()
           
protected  java.util.Vector parseTriple(java.lang.String triple)
          Parse the triple to remove the '?' symbol
protected  java.util.Vector parseTripleForRange(java.lang.String triple)
          Parse the triple to obtain a vector of the triple elemnts
protected  void queryOntology()
          Send the query to Directory Service to get results.
protected  void setInfoMenus()
           
protected  void setInfoMenus2()
           
protected  void setMenus()
           
protected  void setRanges()
          Set the range menu for the selected ranges.
protected  void updateVariablesVector(java.lang.String text)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_descComboInUse

protected boolean _descComboInUse

_e1Pressed

protected boolean _e1Pressed

_e2Pressed

protected boolean _e2Pressed

_e3Pressed

protected boolean _e3Pressed

_e1T2Pressed

protected boolean _e1T2Pressed

_e2T2Pressed

protected boolean _e2T2Pressed

_e3T2Pressed

protected boolean _e3T2Pressed

_range1Pressed

protected boolean _range1Pressed

_range2Pressed

protected boolean _range2Pressed

_range3Pressed

protected boolean _range3Pressed

_range4Pressed

protected boolean _range4Pressed

_objectTable

protected java.util.Hashtable _objectTable

_infoMenuHashtable

protected java.util.Hashtable _infoMenuHashtable

_infoMenu2Hashtable

protected java.util.Hashtable _infoMenu2Hashtable

_infoMenuRangeHT

protected java.util.Hashtable _infoMenuRangeHT

_loadButton

protected javax.swing.JButton _loadButton

_removeButton

protected javax.swing.JButton _removeButton

_connectorComboBox

protected javax.swing.JComboBox _connectorComboBox

_varQueryComboBox

protected javax.swing.JComboBox _varQueryComboBox

_queryComboModel

protected javax.swing.DefaultComboBoxModel _queryComboModel

_resultsListModel

protected javax.swing.DefaultListModel _resultsListModel

_templateListModel

protected javax.swing.DefaultListModel _templateListModel

_rangeLabel

protected javax.swing.JLabel _rangeLabel

_rangeLabel2

protected javax.swing.JLabel _rangeLabel2

_rangeLabel3

protected javax.swing.JLabel _rangeLabel3

_rangeLabel4

protected javax.swing.JLabel _rangeLabel4

_templateList

protected javax.swing.JList _templateList

_varMenu

protected javax.swing.JMenu _varMenu

_namespMenu

protected javax.swing.JMenu _namespMenu

_rangeMenu

protected javax.swing.JMenu _rangeMenu

_queryTab

protected javax.swing.JPanel _queryTab

_queryEditorPanel

protected javax.swing.JPanel _queryEditorPanel

_queryTemplateEditorPanel

protected javax.swing.JPanel _queryTemplateEditorPanel

_queryTemplatePanel

protected javax.swing.JPanel _queryTemplatePanel

_subjectMenu

protected javax.swing.JPopupMenu _subjectMenu

_tempMenu

protected javax.swing.JPopupMenu _tempMenu

_tempMenu2

protected javax.swing.JPopupMenu _tempMenu2

_tempMenu3

protected javax.swing.JPopupMenu _tempMenu3

_tempMenu4

protected javax.swing.JPopupMenu _tempMenu4

_tabPane

protected javax.swing.JTabbedPane _tabPane

_descTextField

protected javax.swing.JTextField _descTextField

_e1TextField

protected javax.swing.JTextField _e1TextField

_e2TextField

protected javax.swing.JTextField _e2TextField

_e3TextField

protected javax.swing.JTextField _e3TextField

_e1T2TextField

protected javax.swing.JTextField _e1T2TextField

_e2T2TextField

protected javax.swing.JTextField _e2T2TextField

_e3T2TextField

protected javax.swing.JTextField _e3T2TextField

_qTempTextField

protected javax.swing.JTextField _qTempTextField

_sub1TextField

protected javax.swing.JTextField _sub1TextField

_sub2TextField

protected javax.swing.JTextField _sub2TextField

_t1TextField

protected javax.swing.JTextField _t1TextField

_t2TextField

protected javax.swing.JTextField _t2TextField

_tempTextField

protected javax.swing.JTextField _tempTextField

_val1TextField

protected javax.swing.JTextField _val1TextField

_val2TextField

protected javax.swing.JTextField _val2TextField

_queryTemplateObj

protected QueryTemplateObject _queryTemplateObj

_rangesBtn

protected kaos.kpat.applet.QueryTabBuilder.RangeButton _rangesBtn

_rangesBtn2

protected kaos.kpat.applet.QueryTabBuilder.RangeButton _rangesBtn2

_rangesBtn3

protected kaos.kpat.applet.QueryTabBuilder.RangeButton _rangesBtn3

_rangesBtn4

protected kaos.kpat.applet.QueryTabBuilder.RangeButton _rangesBtn4

_conValue

protected java.lang.String _conValue

_varQueryStr

protected java.lang.String _varQueryStr

_nsp

protected java.lang.String[] _nsp

_nsp2

protected java.lang.String[] _nsp2

_e1Button

protected kaos.kpat.applet.QueryTabBuilder.SubjectButton _e1Button

_e2Button

protected kaos.kpat.applet.QueryTabBuilder.SubjectButton _e2Button

_e3Button

protected kaos.kpat.applet.QueryTabBuilder.SubjectButton _e3Button

_e1T2Button

protected kaos.kpat.applet.QueryTabBuilder.SubjectButton _e1T2Button

_e2T2Button

protected kaos.kpat.applet.QueryTabBuilder.SubjectButton _e2T2Button

_e3T2Button

protected kaos.kpat.applet.QueryTabBuilder.SubjectButton _e3T2Button

_conVector

protected java.util.Vector _conVector

_rangeClassesVector

protected java.util.Vector _rangeClassesVector

_variablesVector

protected java.util.Vector _variablesVector

_configPath

protected static java.lang.String _configPath
Constructor Detail

QueryTabBuilder

public QueryTabBuilder(TunnelClient tunnelClient)
Method Detail

createGui

public void createGui()

buildQueryTemplateTab

protected void buildQueryTemplateTab()

buildExecuteQueryTab

protected void buildExecuteQueryTab()

displaySelectedQuery

protected void displaySelectedQuery()
Get all the queries previously saved to a file.


setMenus

protected void setMenus()

setInfoMenus

protected void setInfoMenus()
                     throws java.lang.Exception
Throws:
java.lang.Exception

setInfoMenus2

protected void setInfoMenus2()
                      throws java.lang.Exception
Throws:
java.lang.Exception

getVarVector

protected java.util.Vector getVarVector()

getConVector

protected java.util.Vector getConVector()

getDataVector

protected java.util.Vector getDataVector()

updateVariablesVector

protected void updateVariablesVector(java.lang.String text)

setRanges

protected void setRanges()
Set the range menu for the selected ranges.


getRangeMenus

protected void getRangeMenus(java.lang.String rangeClass,
                             javax.swing.JPopupMenu tempMenu)
Get the range information from the query template object.


queryOntology

protected void queryOntology()
Send the query to Directory Service to get results.


getQueryTab

public javax.swing.JPanel getQueryTab()

getResultsPanel

public javax.swing.JPanel getResultsPanel()

getNamespaces

protected java.lang.String[] getNamespaces()

getShortName

protected java.lang.String getShortName(java.lang.String name)

buildQueryFromElements

protected QueryTemplateObject buildQueryFromElements()
Build the query object using the selected elements from the tab


parseTriple

protected java.util.Vector parseTriple(java.lang.String triple)
Parse the triple to remove the '?' symbol


parseTripleForRange

protected java.util.Vector parseTripleForRange(java.lang.String triple)
Parse the triple to obtain a vector of the triple elemnts