/** * <p> * Returns a new (non-singleton) instance of the ConnectionHub which uses the given executor * service. * </p> * <p> * 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. * </p> */ public synchronized static ConnectionHub getNewInstance(HapiContext context) { return new ConnectionHub(context); }
/** * <p> * Returns a new (non-singleton) instance of the ConnectionHub which uses the given executor * service. * </p> * <p> * 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. * </p> */ public synchronized static ConnectionHub getNewInstance(HapiContext context) { return new ConnectionHub(context); }
/** * 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 synchronized static ConnectionHub getInstance(ExecutorService service) { if (instance == null || service.isShutdown()) { instance = new ConnectionHub(service); } return instance; }
/** * 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 synchronized static ConnectionHub getInstance(ExecutorService service) { if (instance == null || service.isShutdown()) { instance = new ConnectionHub(service); } return instance; }
/** * 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(HapiContext context) { if (instance == null || context.getExecutorService().isShutdown()) { instance = new ConnectionHub(context); } return instance; }
/** * 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(HapiContext context) { if (instance == null || context.getExecutorService().isShutdown()) { instance = new ConnectionHub(context); } return instance; }