Class: RippleRest::Amount
- Inherits:
-
RestObject
- Object
- RestObject
- RippleRest::Amount
- Defined in:
- lib/ripple-rest/generated-schemas.rb,
lib/ripple-rest/schemas.rb,
lib/ripple-rest/generated-schemas.rb
Overview
An Amount on the Ripple Protocol, used also for XRP in the ripple-rest API
Instance Attribute Summary collapse
-
#counterparty ⇒ String
The Ripple account address of the currency’s issuer or gateway, or an empty string if the currency is XRP.
-
#currency ⇒ String<Currency>
The currency expressed as a three-character code.
-
#issuer ⇒ String
The Ripple account address of the currency’s issuer or gateway, or an empty string if the currency is XRP.
-
#value ⇒ String
The quantity of the currency, denoted as a string to retain floating point precision.
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from RestObject
Constructor Details
This class inherits a constructor from RippleRest::RestObject
Instance Attribute Details
#counterparty ⇒ String
The Ripple account address of the currency’s issuer or gateway, or an empty string if the currency is XRP
387 |
# File 'lib/ripple-rest/generated-schemas.rb', line 387 property :counterparty, [:String, "^$|^r[1-9A-HJ-NP-Za-km-z]{25,33}$"] |
#currency ⇒ String<Currency>
The currency expressed as a three-character code
376 |
# File 'lib/ripple-rest/generated-schemas.rb', line 376 property :currency, :Currency |
#issuer ⇒ String
The Ripple account address of the currency’s issuer or gateway, or an empty string if the currency is XRP
382 |
# File 'lib/ripple-rest/generated-schemas.rb', line 382 property :issuer, [:String, "^$|^r[1-9A-HJ-NP-Za-km-z]{25,33}$"] |
#value ⇒ String
The quantity of the currency, denoted as a string to retain floating point precision
370 |
# File 'lib/ripple-rest/generated-schemas.rb', line 370 property :value, :String |
Class Method Details
Instance Method Details
#to_s ⇒ String
26 27 28 |
# File 'lib/ripple-rest/schemas.rb', line 26 def to_s "#{value}+#{currency}#{issuer.to_s.size > 0 ? ("+" + issuer) : ""}" end |