Class: SpApiHelpers::MoneyType
- Inherits:
-
Object
- Object
- SpApiHelpers::MoneyType
- Defined in:
- lib/sp_api_helpers.rb
Constant Summary collapse
- USD =
"USD"- EUR =
"EUR"- GBP =
"GBP"- RMB =
"RMB"- INR =
"INR"- JPY =
"JPY"- CAD =
"CAD"- MXN =
"MXN"
Instance Attribute Summary collapse
-
#amount ⇒ Object
Returns the value of attribute amount.
-
#currency_code ⇒ Object
Returns the value of attribute currency_code.
Instance Method Summary collapse
-
#initialize(amount, currency_code = USD) ⇒ MoneyType
constructor
A new instance of MoneyType.
- #to_camelize ⇒ Object
Constructor Details
Instance Attribute Details
#amount ⇒ Object
Returns the value of attribute amount.
80 81 82 |
# File 'lib/sp_api_helpers.rb', line 80 def amount @amount end |
#currency_code ⇒ Object
Returns the value of attribute currency_code.
80 81 82 |
# File 'lib/sp_api_helpers.rb', line 80 def currency_code @currency_code end |
Instance Method Details
#to_camelize ⇒ Object
87 88 89 90 91 92 |
# File 'lib/sp_api_helpers.rb', line 87 def to_camelize { "Amount" => amount, "CurrencyCode" => currency_code } end |