|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.kpro.ui.UserIO
com.kpro.ui.PrivacyAdvisorGUI
public class PrivacyAdvisorGUI
Privacy Advisor GUI to run on top of
Nested Class Summary | |
---|---|
(package private) class |
PrivacyAdvisorGUI.pAdvisorButtonListener
Listens on GUI buttons. |
private class |
PrivacyAdvisorGUI.PrivacyAdvisorConfigEditor
|
private class |
PrivacyAdvisorGUI.TListener
Implements the TreeSelectionListener interface. |
Field Summary | |
---|---|
private javax.swing.JTree |
dataBaseTree
|
private javax.swing.tree.DefaultMutableTreeNode |
dataBaseTreeRoot
|
private javax.swing.JScrollPane |
dataBaseTreeScrollPane
|
private javax.swing.JMenuItem |
exitMenuItem
|
private javax.swing.JFrame |
frame
|
private Gio |
gio
|
private javax.swing.JMenuItem |
loadConfigMenuItem
|
private javax.swing.JMenuItem |
loadDBMenuItem
|
private javax.swing.JMenu |
menu
|
private javax.swing.JMenuBar |
menuBar
|
private javax.swing.JTextArea |
outputArea
|
private javax.swing.JScrollPane |
outputAreaScrollPane
|
private javax.swing.JTree |
policyTree
|
private javax.swing.tree.DefaultMutableTreeNode |
policyTreeRoot
|
private javax.swing.JScrollPane |
policyTreeScrollPane
|
private javax.swing.JMenuItem |
runMenuItem
|
Constructor Summary | |
---|---|
PrivacyAdvisorGUI()
Default no-arg constructor |
Method Summary | |
---|---|
private void |
buildTree(javax.swing.tree.DefaultMutableTreeNode root,
PolicyDatabase pdb)
Builds the tree view of the knowledge base (ie. |
private void |
buildTree(javax.swing.tree.DefaultMutableTreeNode root,
PolicyObject po)
Builds the tree view of the policy to be classified. |
void |
closeResources()
closes all resources used by UserIO - windows, files, streams, etc |
private void |
initialize()
GUI initializer: Initialize the contents of the frame. |
private void |
loadConfig()
|
private void |
loadDB()
|
java.util.ArrayList<PolicyObject> |
loadHistory()
gets any policies not already provided for the history |
static void |
main(java.lang.String[] args)
Launch the application. |
private void |
println(java.lang.String str)
Write to PrivacyAdvisorGUI output textarea. |
private void |
run()
Runs the CBR algorithm to classify the input P3P. |
void |
showDatabase(PolicyDatabase pdb)
display the contents of the database |
void |
user_init(java.util.Properties genProps)
Called from GIO. |
PolicyObject |
userResponse(PolicyObject n)
Shows recommendation and prompts for user action Needs improvement to allow for giving reasons as for why recommendation is not accepted. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private javax.swing.JFrame frame
private Gio gio
private javax.swing.JTextArea outputArea
private javax.swing.JTree dataBaseTree
private javax.swing.JTree policyTree
private javax.swing.tree.DefaultMutableTreeNode dataBaseTreeRoot
private javax.swing.tree.DefaultMutableTreeNode policyTreeRoot
private javax.swing.JMenuBar menuBar
private javax.swing.JMenu menu
private javax.swing.JMenuItem loadConfigMenuItem
private javax.swing.JMenuItem loadDBMenuItem
private javax.swing.JMenuItem runMenuItem
private javax.swing.JMenuItem exitMenuItem
private javax.swing.JScrollPane outputAreaScrollPane
private javax.swing.JScrollPane dataBaseTreeScrollPane
private javax.swing.JScrollPane policyTreeScrollPane
Constructor Detail |
---|
public PrivacyAdvisorGUI()
Method Detail |
---|
public static void main(java.lang.String[] args)
private void initialize()
public void user_init(java.util.Properties genProps)
user_init
in class UserIO
genProps
- the default values for all commandline argumentsprivate void loadConfig()
public java.util.ArrayList<PolicyObject> loadHistory()
UserIO
loadHistory
in class UserIO
public PolicyObject userResponse(PolicyObject n)
userResponse
in class UserIO
n
- the policy display
public void closeResources()
UserIO
closeResources
in class UserIO
private void loadDB()
private void run()
private void println(java.lang.String str)
public void showDatabase(PolicyDatabase pdb)
UserIO
showDatabase
in class UserIO
pdb
- the database to displayprivate void buildTree(javax.swing.tree.DefaultMutableTreeNode root, PolicyDatabase pdb)
root
- pdb
- private void buildTree(javax.swing.tree.DefaultMutableTreeNode root, PolicyObject po)
root
- po
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |