Class: Io::Flow::V0::Models::LabelTrackingSummaryUpdate
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::LabelTrackingSummaryUpdate
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#created_at ⇒ Object
readonly
Returns the value of attribute created_at.
-
#timestamp ⇒ Object
readonly
Returns the value of attribute timestamp.
Instance Method Summary collapse
- #copy(incoming = {}) ⇒ Object
-
#initialize(incoming = {}) ⇒ LabelTrackingSummaryUpdate
constructor
A new instance of LabelTrackingSummaryUpdate.
- #to_hash ⇒ Object
- #to_json ⇒ Object
Constructor Details
#initialize(incoming = {}) ⇒ LabelTrackingSummaryUpdate
Returns a new instance of LabelTrackingSummaryUpdate.
48170 48171 48172 48173 48174 48175 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 48170 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:timestamp], 'LabelTrackingSummaryUpdate') @timestamp = HttpClient::Preconditions.assert_class('timestamp', HttpClient::Helper.to_date_time_iso8601(opts.delete(:timestamp)), DateTime) @created_at = (x = opts.delete(:created_at); x.nil? ? nil : HttpClient::Preconditions.assert_class('created_at', HttpClient::Helper.to_date_time_iso8601(x), DateTime)) end |
Instance Attribute Details
#created_at ⇒ Object (readonly)
Returns the value of attribute created_at.
48168 48169 48170 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 48168 def created_at @created_at end |
#timestamp ⇒ Object (readonly)
Returns the value of attribute timestamp.
48168 48169 48170 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 48168 def @timestamp end |
Instance Method Details
#copy(incoming = {}) ⇒ Object
48181 48182 48183 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 48181 def copy(incoming={}) LabelTrackingSummaryUpdate.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end |
#to_hash ⇒ Object
48185 48186 48187 48188 48189 48190 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 48185 def to_hash { :timestamp => , :created_at => created_at } end |
#to_json ⇒ Object
48177 48178 48179 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 48177 def to_json JSON.dump(to_hash) end |