public GeneratorWebClient() {		
		
		isRunning = false;	
		
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		setBounds(100, 100, 800, 600);
		contentPane = new JPanel();
		contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
		contentPane.setLayout(new BorderLayout(0, 0));
		setContentPane(contentPane);
		
		JPanel panel = new JPanel();
		panel.setBackground(Color.LIGHT_GRAY);
		contentPane.add(panel, BorderLayout.CENTER);
		panel.setLayout(null);
		
		JLabel lblMinimumSupportLevel = new JLabel("Minimum Support Level");
		lblMinimumSupportLevel.setBounds(10, 11, 202, 43);
		lblMinimumSupportLevel.setFont(new Font("Tahoma", Font.PLAIN, 18));
		panel.add(lblMinimumSupportLevel);
		
		JLabel lblNewLabel = new JLabel("Minimum Confidence Level");
		lblNewLabel.setBounds(10, 60, 232, 41);
		lblNewLabel.setFont(new Font("Tahoma", Font.PLAIN, 18));
		panel.add(lblNewLabel);
		
		mslTextField = new JTextField();
		mslTextField.setText("0.0");
		mslTextField.setFont(new Font("Tahoma", Font.PLAIN, 18));
		mslTextField.setBounds(270, 23, 86, 31);
		panel.add(mslTextField);
		mslTextField.setColumns(10);
		
		mclTextField = new JTextField();
		mclTextField.setText("0.0");
		mclTextField.setFont(new Font("Tahoma", Font.PLAIN, 18));
		mclTextField.setBounds(270, 72, 86, 29);
		panel.add(mclTextField);
		mclTextField.setColumns(10);
		
		JScrollPane scrollPane = new JScrollPane();
		scrollPane.setBounds(10, 296, 370, 245);
		panel.add(scrollPane);
		
		final JTextPane textPane = new JTextPane();
		scrollPane.setViewportView(textPane);
		textPane.setEditable(false);
		
		JScrollPane scrollPane_1 = new JScrollPane();
		scrollPane_1.setBounds(394, 296, 370, 245);
		panel.add(scrollPane_1);
		
		final JTextPane textErrorPane = new JTextPane();
		scrollPane_1.setViewportView(textErrorPane);
		textErrorPane.setEditable(false);
		
		JLabel lblInputFile = new JLabel("Input Transaction File");
		lblInputFile.setFont(new Font("Tahoma", Font.PLAIN, 18));
		lblInputFile.setBounds(10, 109, 202, 36);
		panel.add(lblInputFile);
		
		JLabel lblOutputRuleFile = new JLabel("Output Rule File");
		lblOutputRuleFile.setFont(new Font("Tahoma", Font.PLAIN, 18));
		lblOutputRuleFile.setBounds(10, 151, 157, 32);
		panel.add(lblOutputRuleFile);
		
		inputText = new JTextField();
		lblInputFile.setLabelFor(inputText);
		inputText.setFont(new Font("Tahoma", Font.PLAIN, 18));
		inputText.setBounds(270, 112, 327, 33);
		panel.add(inputText);
		inputText.setColumns(10);
		
		outputRuleText = new JTextField();
		lblOutputRuleFile.setLabelFor(outputRuleText);
		outputRuleText.setFont(new Font("Tahoma", Font.PLAIN, 18));
		outputRuleText.setBounds(270, 154, 327, 29);
		panel.add(outputRuleText);
		outputRuleText.setColumns(10);
		
		JButton btnPressMe = new JButton("Perform Apriori");
		JButton btnReset = new JButton("Reset");
		
		btnReset.addMouseListener(new MouseAdapter() {
			
			public void mouseClicked(MouseEvent arg0) {
				inputText.setText("");
				outputRuleText.setText("");
				outputErrorText.setText("");
				mslTextField.setText("0.0");
				mclTextField.setText("0.0");
				textPane.setText("");
				textErrorPane.setText("");
				textPane.repaint();
				textErrorPane.repaint();
				//outputDialog(textPane);
				//outputErrorDialog(textErrorPane);
				
			}
		});
		
		
		
		btnPressMe.addMouseListener(new MouseAdapter() {
			
			public void mouseClicked(MouseEvent arg0) {
				inputFilePath = inputText.getText();
				outputErrorFilePath = outputErrorText.getText();
				outputRuleFilePath = outputRuleText.getText();
				msl = Double.parseDouble(mslTextField.getText());
				mcl = Double.parseDouble(mclTextField.getText());				
						
				//ClientResource clientResource = new ClientResource("http://localhost:8111/");
		        
				//TransactionSetResource proxy = clientResource.wrap(TransactionSetResource.class);

				///proxy.store(transSet);
				//newTransSet = proxy.retrieve();
				
				
				if(isRunning == false){
					isRunning = true;
					
					thread = new Thread() {
					    public void run() {
					    	//Function for what happens after mouse click
					    	
					    	if(formatFilePaths()){
					    		ClientResource clientResource = new ClientResource("http://localhost:8111/");
						        
								GeneratorResource proxy = clientResource.wrap(GeneratorResource.class);
					    		System.out.println("IN IF of format file paths");
					    		System.out.println(inputFilePath);
					    		System.out.println(outputErrorFilePath);
					    		System.out.println(outputRuleFilePath);
					    		runTest(inputFilePath, outputRuleFilePath, msl, mcl, clientResource, proxy);
						    	outputDialog(textPane);
						    	//outputRuleDialog(textPane);
						    	outputErrorDialog(textErrorPane);
								isRunning = false;
					    	}
							
					    }
					};
					
					thread.start();
					
				}
							
			}
		});
		
		btnPressMe.setBounds(100, 251, 139, 33);
		btnReset.setBounds(500, 251, 139, 33);
		panel.add(btnPressMe);
		panel.add(btnReset);
		
		JLabel lblOutputErrorFile = new JLabel("Output Error File");
		lblOutputErrorFile.setFont(new Font("Tahoma", Font.PLAIN, 18));
		lblOutputErrorFile.setBounds(10, 197, 157, 32);
		panel.add(lblOutputErrorFile);
		
		outputErrorText = new JTextField();
		lblOutputErrorFile.setLabelFor(outputErrorText);
		outputErrorText.setFont(new Font("Tahoma", Font.PLAIN, 18));
		outputErrorText.setColumns(10);
		outputErrorText.setBounds(270, 200, 327, 29);
		panel.add(outputErrorText);
		
		
	}