Class: PostProxy::ProfileComment
Instance Attribute Summary collapse
-
#author_avatar_url ⇒ Object
Returns the value of attribute author_avatar_url.
-
#author_username ⇒ Object
Returns the value of attribute author_username.
-
#body ⇒ Object
Returns the value of attribute body.
-
#created_at ⇒ Object
Returns the value of attribute created_at.
-
#external_id ⇒ Object
Returns the value of attribute external_id.
-
#id ⇒ Object
Returns the value of attribute id.
-
#parent_external_id ⇒ Object
Returns the value of attribute parent_external_id.
-
#placement_id ⇒ Object
Returns the value of attribute placement_id.
-
#platform_data ⇒ Object
Returns the value of attribute platform_data.
-
#posted_at ⇒ Object
Returns the value of attribute posted_at.
-
#replies ⇒ Object
Returns the value of attribute replies.
-
#status ⇒ Object
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(**attrs) ⇒ ProfileComment
constructor
A new instance of ProfileComment.
Methods inherited from Model
Constructor Details
#initialize(**attrs) ⇒ ProfileComment
Returns a new instance of ProfileComment.
347 348 349 350 351 352 353 354 355 356 357 358 359 |
# File 'lib/postproxy/types.rb', line 347 def initialize(**attrs) @parent_external_id = nil @author_username = nil @author_avatar_url = nil @platform_data = nil @replies = [] super @posted_at = parse_time(@posted_at) @created_at = parse_time(@created_at) @replies = (@replies || []).map do |r| r.is_a?(ProfileComment) ? r : ProfileComment.new(**r.transform_keys(&:to_sym)) end end |
Instance Attribute Details
#author_avatar_url ⇒ Object
Returns the value of attribute author_avatar_url.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def @author_avatar_url end |
#author_username ⇒ Object
Returns the value of attribute author_username.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def @author_username end |
#body ⇒ Object
Returns the value of attribute body.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def body @body end |
#created_at ⇒ Object
Returns the value of attribute created_at.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def created_at @created_at end |
#external_id ⇒ Object
Returns the value of attribute external_id.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def external_id @external_id end |
#id ⇒ Object
Returns the value of attribute id.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def id @id end |
#parent_external_id ⇒ Object
Returns the value of attribute parent_external_id.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def parent_external_id @parent_external_id end |
#placement_id ⇒ Object
Returns the value of attribute placement_id.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def placement_id @placement_id end |
#platform_data ⇒ Object
Returns the value of attribute platform_data.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def platform_data @platform_data end |
#posted_at ⇒ Object
Returns the value of attribute posted_at.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def posted_at @posted_at end |
#replies ⇒ Object
Returns the value of attribute replies.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def replies @replies end |
#status ⇒ Object
Returns the value of attribute status.
343 344 345 |
# File 'lib/postproxy/types.rb', line 343 def status @status end |