public GUI(Reader myReader)
	{
		//set reader
		reader = myReader;
		
		//create all the GUI objects
		gui = new JFrame();
		gui.setTitle("System Information");
		gui.setSize(WINDOW_WIDTH, WINDOW_HEIGHT);
		gui.setLayout(new BorderLayout());
		gui.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		
		//set the progress bar data
		progress = new JProgressBar(0,totalNumberOfData);
		progress.setValue(0);
		progress.setStringPainted(true);
		progress.setString("");
		
		//set button data as well as button action listeners
		loadContent = new JButton("Load Content");
		loadContent.addActionListener(new buttonListener("Load Content"));
		unloadContent = new JButton("Unload Content");
		unloadContent.addActionListener(new buttonListener("Unload Content"));
		accessEachDataEntryOnce = new JButton("Access Each Data Entry Once");
		accessEachDataEntryOnce.addActionListener(new buttonListener("Access Each Data Entry Once"));
		search = new JButton("Search");
		search.addActionListener(new buttonListener("Search"));
		searchRandomEntry = new JButton("Search For Random Entry");
		searchRandomEntry.addActionListener(new buttonListener("Search For Random Entry"));
		printLogFile = new JButton("Print Log File");
		printLogFile.addActionListener(new buttonListener("Print Log File"));
		
		//set label infromation
		storeinlabel = new JLabel("Store in:");
		searchlabel = new JLabel("Search for specific entry:");
		empty = new JLabel(" ");
		emptytwo = new JLabel(" ");
		emptythree = new JLabel(" ");
		emptyfour = new JLabel(" ");
		emptyfive = new JLabel(" ");
		emptysix = new JLabel(" ");
		emptyseven = new JLabel(" ");
		
		//set text field data
		searchcriteria = new JTextField(20);
	
		//create panel for radio buttons
		radiobuttonpanel = new JPanel(new GridLayout(4, 1));
		
		//set the data structure radio button data and action listeners
		binarytree = new JRadioButton("Binary Tree");
		binarytree.addActionListener(new radioButtonActionListener("BinaryTree"));
		radiobuttonpanel.add(binarytree);
		narytree = new JRadioButton("N-ary Tree");
		narytree.addActionListener(new radioButtonActionListener("NaryTree"));
		radiobuttonpanel.add(narytree);
		hashlist = new JRadioButton("Hashlist");
		hashlist.addActionListener(new radioButtonActionListener("HashList"));
		radiobuttonpanel.add(hashlist);
		hashtable = new JRadioButton("Hashtable");
		hashtable.addActionListener(new radioButtonActionListener("HashTable"));
		radiobuttonpanel.add(hashtable);
		
		//set the log text area data
		logtextarea = new JTextArea();
		logtextarea.setEnabled(false);
		logtextarea.append("=================LOG FILE=================\n\n");		
		scrollpane = new JScrollPane(logtextarea);
		scrollpane.setPreferredSize(new Dimension(450, 180));

		//set teh combo box data and create it's item listener
		String[] options = {"350000.csv", "300000.csv", "128000.csv", "61053.csv" , "31480.csv"};
		fileChooser = new JComboBox<String>(options);
		
		fileChooser.addItemListener(new ItemListener()
		{
			  public void itemStateChanged(ItemEvent ie)
			  {
				  String chosen = (String)fileChooser.getSelectedItem();
				  
				  if(chosen.equals("350000.csv"))
				  {
						totalNumberOfData = 350000;
						fileName = "Test Data/350000.csv";
						progress.setMaximum(totalNumberOfData);
						logtextarea.append(fileName+"\n");
				  }
				  
				  else if(chosen.equals("300000.csv"))
				  {
						totalNumberOfData = 300000;
						fileName = "Test Data/300000.csv";
						progress.setMaximum(totalNumberOfData);
						logtextarea.append(fileName+"\n");
				  }
				  
				  else if(chosen.equals("128000.csv"))
				  {
						totalNumberOfData = 128000;
						fileName = "Test Data/128000.csv";
						progress.setMaximum(totalNumberOfData);
						logtextarea.append(fileName+"\n");
				  }
				  
				  else if(chosen.equals("61053.csv"))
				  {
						totalNumberOfData = 61053;
						fileName = "Test Data/61053.csv";
						progress.setMaximum(totalNumberOfData);
						logtextarea.append(fileName+"\n");
				  }
				  
				  else if(chosen.equals("31480.csv"))
				  {
						totalNumberOfData = 31480;
						fileName = "Test Data/31480.csv";
						progress.setMaximum(totalNumberOfData);
						logtextarea.append(fileName+"\n");
				  }
			  }
		});
		gui.add(fileChooser, BorderLayout.NORTH);
		
		//radio buttons for searching
		searchTypeButtons = new JPanel(new FlowLayout());
		searchAll = new JRadioButton("Search All");
		searchAll.setSelected(true);
		setSearchAllEnabled(true);
		searchAll.addActionListener(new radioButtonActionListener("Search All"));
		searchOne = new JRadioButton("Search One");
		searchOne.addActionListener(new radioButtonActionListener("Search One"));
		searchTypeButtons.add(searchAll);
		searchTypeButtons.add(searchOne);
		
		//create relative panels for GUI elements
		loadingdatapanel = new JPanel(new GridBagLayout());
		searchpanel = new JPanel(new GridBagLayout());
		progresspanel =  new JPanel(new BorderLayout());
		
		//place all the objects in the correct place
		
		//========================================================
		//add the content for the search side of the GUI
		//========================================================		
		GridBagConstraints gc = new GridBagConstraints();
		gc.gridx = 0;
		gc.gridy = 0;
		loadingdatapanel.add(loadContent, gc);
		gc.gridx = 0;
		gc.gridy = 1;
		loadingdatapanel.add(empty, gc);
		gc.gridx = 0;
		gc.gridy = 2;
		loadingdatapanel.add(storeinlabel, gc);		
		gc.gridx = 0;
		gc.gridy = 3;
		loadingdatapanel.add(emptytwo, gc);
		gc.gridx = 0;
		gc.gridy = 4;
		loadingdatapanel.add(radiobuttonpanel, gc);
		gc.gridx = 0;
		gc.gridy = 5;
		loadingdatapanel.add(emptythree, gc);		
		gc.gridx = 0;
		gc.gridy = 6;
		loadingdatapanel.add(unloadContent, gc);
		gui.add(loadingdatapanel, BorderLayout.WEST);
		//========================================================
		
		//========================================================
		//add the progress bar and log file area to the GUI
		//========================================================		
		progresspanel.add(progress, BorderLayout.CENTER);
		progresspanel.add(scrollpane, BorderLayout.SOUTH);
		
		gui.add(progresspanel, BorderLayout.SOUTH);
		//========================================================
		
		//========================================================
		//add the search elements to the GUI
		//========================================================
		String[] searchType = {"First Name","Last Name","Number"};
		searchTypeChooser = new JComboBox<String>(searchType);
		
		gc = new GridBagConstraints();
		gc.gridx = 0;
		gc.gridy = 0;
		searchpanel.add(accessEachDataEntryOnce, gc);
		gc.gridx = 0;
		gc.gridy = 1;
		searchpanel.add(emptyfour, gc);
		gc.gridx = 0;
		gc.gridy = 2;
		searchpanel.add(searchlabel, gc);
		gc.gridx = 0;
		gc.gridy = 3;
		searchpanel.add(searchcriteria, gc);
		gc.gridx = 1;
		gc.gridy = 3;
		searchpanel.add(emptyfive, gc);
		gc.gridx = 2;
		gc.gridy = 3; 
		searchpanel.add(searchTypeChooser, gc);
		gc.gridx = 3;
		gc.gridy = 3;
		searchpanel.add(search, gc);
		gc.gridx = 4;
		gc.gridy = 3;
		searchpanel.add(searchTypeButtons, gc);
		gc.gridx = 0;
		gc.gridy = 4;
		searchpanel.add(emptysix, gc);
		gc.gridx = 0;
		gc.gridy = 5;
		searchpanel.add(searchRandomEntry, gc);
		gc.gridx = 0;
		gc.gridy = 6;
		searchpanel.add(emptyseven, gc);
		gc.gridx = 0;
		gc.gridy = 7;
		searchpanel.add(printLogFile, gc);
		gui.add(searchpanel,  BorderLayout.CENTER);
		//========================================================
		
		//set intial selection data
		binarytree.setSelected(true);
		setBinaryTreeEnabled(true);
		
		//create GUI
		gui.pack();
		gui.setLocationRelativeTo(null);
		gui.setVisible(true);
	}