Class: Io::Flow::V0::Models::RepeatDaily
- Inherits:
-
RepeatSchedule
- Object
- RepeatSchedule
- Io::Flow::V0::Models::RepeatDaily
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#interval ⇒ Object
readonly
Returns the value of attribute interval.
Attributes inherited from RepeatSchedule
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ RepeatDaily
constructor
A new instance of RepeatDaily.
- #subtype_to_hash ⇒ Object
- #to_json ⇒ Object
Methods inherited from RepeatSchedule
Constructor Details
#initialize(incoming = {}) ⇒ RepeatDaily
Returns a new instance of RepeatDaily.
47646 47647 47648 47649 47650 47651 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 47646 def initialize(incoming={}) super(:discriminator => RepeatSchedule::Types::REPEAT_DAILY) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:interval], 'RepeatDaily') @interval = HttpClient::Preconditions.assert_class('interval', opts.delete(:interval), Integer) end |
Instance Attribute Details
#interval ⇒ Object (readonly)
Returns the value of attribute interval.
47644 47645 47646 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 47644 def interval @interval end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
47657 47658 47659 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 47657 def copy(incoming={}) RepeatDaily.new(subtype_to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#subtype_to_hash ⇒ Object
47661 47662 47663 47664 47665 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 47661 def subtype_to_hash { :interval => interval } end |
#to_json ⇒ Object
47653 47654 47655 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 47653 def to_json JSON.dump(to_hash) end |