public static void main(String[] args) throws IOException, InterruptedException {
					
		try {	
			/* 
			 * We have some other function wire the ChatClient 
			 * to the communication platform
			 */
			ChatClient client = wireClient();
			
	        System.out.println("Starting ChatClient...");
	        
	        CLI cli = new CLI(client);
	        int val;
	        
	        cli.displayMenu();
	        while((val = cli.readInt("CLI: >")) != 4) {
	     
	        	switch(val) {
	        	default:
	        		System.out.println("Please enter a valid option!");
	        		break;
	        	case 1:
	        		if(cli.login())
	        			if(!cli.lobby())
	        				break;
	        		break;
	        	case 2:
	        		cli.register();
	        		break;
	        	case 3:
	        		cli.displayMenu();
	        		break;
	        	}      
	        }
	        
			System.out.println("Exiting...");	
	        System.exit(0);
		} catch (JMSException e) {
			e.printStackTrace();
		} catch (URISyntaxException e) {
			e.printStackTrace();
		}
		

	}