April 2019
Intermediate to advanced
426 pages
11h 13m
English
Add a send_market_order() abstract method for the inheriting child classes to implement when sending a market order to your broker:
@abstractmethod
def send_market_order(self, symbol, quantity, is_buy):
raise NotImplementedError('Method is required!')
Using the preceding methods written in our Broker base class, we can now write broker-specific classes in the next section.