Create a New Session
Example 4-1 illustrates typical usage of the ServiceLocator. The ServiceLocator is configured by creating a Properties class and configuring the JNDI and HDR client mode properties. The application then calls the login method that establishes a session between client and server. The application retrieves a service from the service locator by calling getRimService().
Example 4-1 Outline of Service Locator Usage for a New Session
Properties properties = ...; ServiceLocator serviceLocator = ServiceLocator.getInstance(properties); serviceLocator.login(username, password); RimService rimService = serviceLocator.getRimService(); ...