@Override
public synchronized TradingAgentBindingHandle createBinding(TradingAgentConfigurationHandle tradingAgentConfigurationHandle, Map<String, ServiceHandle<IStockDatabaseHost>> inputSeriesHandles, String name) {
Map<String, IStockDatabase> inputStockDatabases = new HashMap<String, IStockDatabase>();
for (Map.Entry<String, ServiceHandle<IStockDatabaseHost>> entry : inputSeriesHandles.entrySet()) {
IStockDatabase stockDb = stockDatabaseHost.getStockDatabase(entry.getValue());
inputStockDatabases.put(entry.getKey(), stockDb);
}
TradingAgentBindingHandle bindingHandle = tradingManager.createBinding(tradingAgentConfigurationHandle, inputStockDatabases, name);
stockDbHandlesByBindingHandle.put(bindingHandle, inputSeriesHandles);
return bindingHandle;