Class: PostProxy::PlatformStats
Instance Attribute Summary collapse
-
#platform ⇒ Object
Returns the value of attribute platform.
-
#profile_id ⇒ Object
Returns the value of attribute profile_id.
-
#records ⇒ Object
Returns the value of attribute records.
Instance Method Summary collapse
-
#initialize(**attrs) ⇒ PlatformStats
constructor
A new instance of PlatformStats.
Methods inherited from Model
Constructor Details
#initialize(**attrs) ⇒ PlatformStats
Returns a new instance of PlatformStats.
205 206 207 208 209 210 211 |
# File 'lib/postproxy/types.rb', line 205 def initialize(**attrs) @records = [] super @records = (@records || []).map do |r| r.is_a?(StatsRecord) ? r : StatsRecord.new(**r.transform_keys(&:to_sym)) end end |
Instance Attribute Details
#platform ⇒ Object
Returns the value of attribute platform.
203 204 205 |
# File 'lib/postproxy/types.rb', line 203 def platform @platform end |
#profile_id ⇒ Object
Returns the value of attribute profile_id.
203 204 205 |
# File 'lib/postproxy/types.rb', line 203 def profile_id @profile_id end |
#records ⇒ Object
Returns the value of attribute records.
203 204 205 |
# File 'lib/postproxy/types.rb', line 203 def records @records end |