Class: Simplepay::Support::SubscriptionPeriod
- Defined in:
- lib/simplepay/support/subscription_period.rb
Constant Summary collapse
- ALLOWED_INTERVALS =
Simplepay::Intervals + ['forever']
- ALLOWED_QUANTITY_RANGE =
Limited to 3 digits.
(1...1000)
Constants inherited from Interval
Interval::DEFAULT_INTERVAL, Interval::DEFAULT_QUANTITY
Instance Attribute Summary
Attributes inherited from Interval
Instance Method Summary collapse
-
#to_s ⇒ Object
See Simplepay::Support::Interval.to_s for more information.
Methods inherited from Interval
allowed_intervals, #allowed_intervals, allowed_quantity_range, #allowed_quantity_range, default_interval, #default_interval, default_quantity, #default_quantity, #initialize
Constructor Details
This class inherits a constructor from Simplepay::Support::Interval
Instance Method Details
#to_s ⇒ Object
See Simplepay::Support::Interval.to_s for more information.
If the subscription lasts “forever” then Amazon does not need an interval string.
18 19 20 |
# File 'lib/simplepay/support/subscription_period.rb', line 18 def to_s super unless interval == 'forever' end |