public Client(IBrokerageService brokerageService) { if (brokerageService == null) { throw new ArgumentNullException("brokerageService"); } _brokerageService = brokerageService; }
public void Init() { _broker1 = new DigiCoinBroker(0.05m, 1.49m); var broker2Commission = new List <CommissionEntry> { new CommissionEntry(40, 0.03m), new CommissionEntry(80, 0.025m), new CommissionEntry(100, 0.02m), }; _broker2 = new DigiCoinBroker(broker2Commission, 1.52m); _service = new BrokerageService(); _service.RegisterBroker(_broker1); _service.RegisterBroker(_broker2); _clientA = new Client(_service); _clientB = new Client(_service); _clientC = new Client(_service); }
public void Init() { _broker1 = new DigiCoinBroker(0.05m, 1.49m); var broker2Commission = new List<CommissionEntry> { new CommissionEntry(40, 0.03m), new CommissionEntry(80, 0.025m), new CommissionEntry(100, 0.02m), }; _broker2 = new DigiCoinBroker(broker2Commission, 1.52m); _service = new BrokerageService(); _service.RegisterBroker(_broker1); _service.RegisterBroker(_broker2); _clientA = new Client(_service); _clientB = new Client(_service); _clientC = new Client(_service); }
public HostBroker(IBrokerageService broker) { _broker = broker; }