public static void main(String[] args) {
		Provider provider = ProviderService.getProvider();

		//Print all the available addresses of the system.
		try {
			Address[] addresses = provider.getAddresses();
                        System.out.println("Avaialable Addresses : ");
			for (int i = 0; i < addresses.length; i++) {
				System.out.println("Address : "
                                        +addresses[i].getName());
			}
		} catch (ResourceUnavailableException e) {
			e.printStackTrace();
		}
		//Print all the available terminals of the system.
		try {
			Terminal[] terminals = provider.getTerminals();
                        System.out.println("Avaialable Terminals : ");
			for (int i = 0; i < terminals.length; i++) {
				System.out.println("Terminal : "
                                        +terminals[i].getName());
			}
		} catch (ResourceUnavailableException e) {
			e.printStackTrace();
		}
		//Always remember to shutdown the provider,
		//otherwise the application won't return.
		provider.shutdown();
	}