Skip to content

Commit

Permalink
clean up. Final commit of v1.
Browse files Browse the repository at this point in the history
  • Loading branch information
Luke Neville committed Sep 19, 2018
1 parent 559aad2 commit b09c340
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 8 deletions.
8 changes: 7 additions & 1 deletion src/edu/uct/ibr/IBR.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,12 @@ public static void main(String[] args) {
}

public static void help(){
System.out.println("There will be some help info here at some point");
System.out.println(" ~~ IBRJ ~~\n"+
"The ./ibr script can be run with two flags:\n"+
"* -cli to run the program in CLI mode\n"+
"* -gui to run the program in GUI mode\n"+
"Alternatively, run the program with no flags\n"+
"and enter 'g' to run the GUI or 'c' to run \n"+
"the CLI.");
}
}
7 changes: 1 addition & 6 deletions src/edu/uct/ibr/cli/IBRCLI.java
Original file line number Diff line number Diff line change
Expand Up @@ -88,12 +88,7 @@ else if (userInput.equals("q") || userInput.equals("quit")){
* Load a graph from a given input file
*/
private static void load(){
String userInput = io.input(message.INPUT_FILE_PATH);

//NOTE: The following is for ease of use during development
String filePath = "";
if (userInput.equals("a")) filePath = "./examples/asia/asia.bif";
else filePath = userInput;
String filePath = io.input(message.INPUT_FILE_PATH);

try{
graph = new BNGraph(filePath);
Expand Down
6 changes: 5 additions & 1 deletion src/edu/uct/ibr/util/message.java
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,12 @@ public class message{
public static final String INPUT_IMPLICATION_TYPE = "(c)lassical or (d)efeasible implication?";
public static final String INPUT_OBSERVED_VALUE = "Enter observed value";
public static final String CLI_OBSERVATION_TYPE ="(l)ogical or (p)robabilistic observation?";
public static final String GUI_HELP = "Click \"Load Network\" to load a network\n click draw inference to draw inference";
public static final String OUTPUT_FILE_PATH = "Enter the output file name";
public static final String GUI_HELP = ""+
"Use the top panel buttons to perform actions on the network.\n"+
"The right side panels show information about the network such\n"+
"as implications added and observations made.\n"+
"Network nodes can be moved by clicking and dragging them.";
/**
* Get the menu instruction text
*/
Expand Down

0 comments on commit b09c340

Please sign in to comment.