127128129130131132133
return factory; } public static void registerStrategy(final String scheme, final ConnectionStrategy factory) { strategies.register(scheme, factory); Client.fireEvent(new ConnectionStrategyAdded(scheme, factory)); }
134135136137138139140141142143
public static ConnectionStrategy unregisterStrategy(final String scheme) { final ConnectionStrategy strategy = strategies.unregister(scheme); if (strategy != null) { Client.fireEvent(new ConnectionStrategyAdded(scheme, strategy)); } return strategy; }