setters and getters
This commit is contained in:
parent
fc16d4340d
commit
9e3292af1b
|
|
@ -27,28 +27,57 @@ class earner:
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
return str(self.connector)
|
return str(self.connector)
|
||||||
|
|
||||||
|
|
||||||
def toggle_pause(self):
|
def toggle_pause(self):
|
||||||
self.is_paused = not self.is_paused
|
self.is_paused = not self.is_paused
|
||||||
return self.is_paused
|
return self.is_paused
|
||||||
|
|
||||||
|
def set_step_size(self, step_size):
|
||||||
|
self.step_size = step_size
|
||||||
|
return self.step_size
|
||||||
|
|
||||||
|
def get_step_size(self):
|
||||||
|
return self.step_size
|
||||||
|
|
||||||
|
def set_percentage(self, percentage):
|
||||||
|
self.percentage = percentage
|
||||||
|
return self.percentage
|
||||||
|
|
||||||
|
def get_percentage(self):
|
||||||
|
return self.percentage
|
||||||
|
|
||||||
|
def set_minimum_amount_in_trading_account(self, minimum_amount_in_trading_account):
|
||||||
|
self.minimum_amount_in_trading_account = minimum_amount_in_trading_account
|
||||||
|
return self.minimum_amount_in_trading_account
|
||||||
|
|
||||||
|
def get_minimum_amount_in_trading_account(self):
|
||||||
|
return self.minimum_amount_in_trading_account
|
||||||
|
|
||||||
|
def set_time_between_subscriptions(self, time_between_subscriptions):
|
||||||
|
self.time_between_subscriptions = time_between_subscriptions
|
||||||
|
return self.time_between_subscriptions
|
||||||
|
|
||||||
|
def get_time_between_subscriptions(self):
|
||||||
|
return self.time_between_subscriptions
|
||||||
|
|
||||||
|
def set_time_between_redemptions(self, time_between_redemptions):
|
||||||
|
self.time_between_redemptions = time_between_redemptions
|
||||||
|
return self.time_between_redemptions
|
||||||
|
|
||||||
|
def get_time_between_redemptions(self):
|
||||||
|
return self.time_between_redemptions
|
||||||
|
|
||||||
def get_last_subscription(self):
|
def get_last_subscription(self):
|
||||||
return {str(self.connector): self.last_subscription_time}
|
return {str(self.connector): self.last_subscription_time}
|
||||||
|
|
||||||
|
|
||||||
def get_last_redemption(self):
|
def get_last_redemption(self):
|
||||||
return {str(self.connector): self.last_redemption_time}
|
return {str(self.connector): self.last_redemption_time}
|
||||||
|
|
||||||
|
|
||||||
def get_status_string(self):
|
def get_status_string(self):
|
||||||
return self.status_string
|
return self.status_string
|
||||||
|
|
||||||
|
|
||||||
def get_trading_balance(self):
|
def get_trading_balance(self):
|
||||||
return float(self.trading_balance)
|
return float(self.trading_balance)
|
||||||
|
|
||||||
|
|
||||||
def get_earning_balance(self):
|
def get_earning_balance(self):
|
||||||
return float(self.earning_balance)
|
return float(self.earning_balance)
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue