AssetΒΆ
-
class
alchemist_lib.database.asset.
Asset
(ticker, instrument_id, name=None)[source] Map class for table asset.
- ticker: String(16), primary_key.
- instrument_id: Integer, primary_key, foreign_key(instrument.instrument_id).
- name: String(150), null.
Relationships:
- exchanges: List of Exchange instances. (Many-to-Many)
- instrument: Instrument instance. (One-to-Many)
-
__eq__
(other)[source] Overrides the default implementation.
-
__gt__
(other)[source] Overrides the default implementation.
-
__hash__
()[source] Overrides the default implementation.
-
__init__
(ticker, instrument_id, name=None) Costructor method.
Parameters:
-
__le__
(other)[source] Overrides the default implementation.
-
__lt__
(other)[source] Overrides the default implementation.
-
__ne__
(other)[source] Overrides the default implementation.
-
to_dict
()[source] As the name tell, it returns attributes in a dict form.
Note
The __dict__ method is not overrideble.