def __configure_default(self, behaviour_config): """Configures and returns the default behaviour class. Args: behaviour_config (dict): A dictionary of configuration values pertaining to the behaviour. Returns: DefaultBehaviour: A class of functionality for the default behaviour. """ exchange_interface = ExchangeInterface(self.config.exchanges) strategy_analyzer = StrategyAnalyzer() notifier = Notifier(self.config.notifiers) behaviour = DefaultBehaviour( behaviour_config, exchange_interface, strategy_analyzer, notifier ) return behaviour
def configure_default(self, behaviour_config): exchange_interface = ExchangeInterface( self.config.fetch_exchange_config()) strategy_analyzer = StrategyAnalyzer(exchange_interface) notifier = Notifier(self.config.fetch_notifier_config()) behaviour = DefaultBehaviour(behaviour_config, exchange_interface, strategy_analyzer, notifier) return behaviour
def get_behaviour(self, selected_behaviour): if selected_behaviour == 'default': behaviour = DefaultBehaviour() return behaviour