📦 SQA::Portfolio::Trade¶
Description
Represents a single trade
🔨 Instance Methods¶
#ticker=(value)¶
Sets the attribute ticker
Parameters
| Name | Type | Description |
|---|---|---|
value |
Object |
the value to set the attribute ticker to. |
Returns
Type: Object
the newly set value
Source Location
#ticker()¶
Returns the value of attribute ticker
Returns
Type: Object
the current value of ticker
Source Location
#action=(value)¶
Sets the attribute action
Parameters
| Name | Type | Description |
|---|---|---|
value |
Object |
the value to set the attribute action to. |
Returns
Type: Object
the newly set value
Source Location
#action()¶
Returns the value of attribute action
Returns
Type: Object
the current value of action
Source Location
#shares=(value)¶
Sets the attribute shares
Parameters
| Name | Type | Description |
|---|---|---|
value |
Object |
the value to set the attribute shares to. |
Returns
Type: Object
the newly set value
Source Location
#shares()¶
Returns the value of attribute shares
Returns
Type: Object
the current value of shares
Source Location
#price=(value)¶
Sets the attribute price
Parameters
| Name | Type | Description |
|---|---|---|
value |
Object |
the value to set the attribute price to. |
Returns
Type: Object
the newly set value
Source Location
#price()¶
Returns the value of attribute price
Returns
Type: Object
the current value of price
Source Location
#date=(value)¶
Sets the attribute date
Parameters
| Name | Type | Description |
|---|---|---|
value |
Object |
the value to set the attribute date to. |
Returns
Type: Object
the newly set value
Source Location
#date()¶
Returns the value of attribute date
Returns
Type: Object
the current value of date
Source Location
#total=(value)¶
Sets the attribute total
Parameters
| Name | Type | Description |
|---|---|---|
value |
Object |
the value to set the attribute total to. |
Returns
Type: Object
the newly set value
Source Location
#total()¶
Returns the value of attribute total
Returns
Type: Object
the current value of total
Source Location
#commission=(value)¶
Sets the attribute commission
Parameters
| Name | Type | Description |
|---|---|---|
value |
Object |
the value to set the attribute commission to. |
Returns
Type: Object
the newly set value
Source Location
#commission()¶
Returns the value of attribute commission
Returns
Type: Object
the current value of commission
Source Location
#to_h()¶
Source Location
📝 Attributes¶
🔄 ticker read/write¶
Returns the value of attribute ticker
🔄 action read/write¶
Returns the value of attribute action
🔄 shares read/write¶
Returns the value of attribute shares
🔄 price read/write¶
Returns the value of attribute price
🔄 date read/write¶
Returns the value of attribute date
🔄 total read/write¶
Returns the value of attribute total
🔄 commission read/write¶
Returns the value of attribute commission