/** * Returns the singleton instance of ConnectionHub * * @deprecated Use {@link HapiContext#getConnectionHub()} to get an instance of ConnectionHub. * See <a href="http://hl7api.sourceforge.net/xref/ca/uhn/hl7v2/examples/SendAndReceiveAMessage.html">this example page</a> for an example of how to use ConnectionHub. */ public static ConnectionHub getInstance() { return getInstance(DefaultExecutorService.getDefaultService()); }
/** * Returns the singleton instance of ConnectionHub * * @deprecated Use {@link HapiContext#getConnectionHub()} to get an instance of ConnectionHub. * See <a href="http://hl7api.sourceforge.net/xref/ca/uhn/hl7v2/examples/SendAndReceiveAMessage.html">this example page</a> for an example of how to use ConnectionHub. */ public static ConnectionHub getInstance() { return getInstance(DefaultExecutorService.getDefaultService()); }
/** * @deprecated default executor service is shut down automatically */ public static void shutdown() { ConnectionHub hub = getInstance(); if (DefaultExecutorService.isDefaultService(hub.getHapiContext().getExecutorService())) { hub.getHapiContext().getExecutorService().shutdown(); instance = null; } }
/** * @deprecated default executor service is shut down automatically */ public static void shutdown() { ConnectionHub hub = getInstance(); if (DefaultExecutorService.isDefaultService(hub.getHapiContext().getExecutorService())) { hub.getHapiContext().getExecutorService().shutdown(); instance = null; } }
ConnectionHub connectionHub = ConnectionHub.getInstance();