Class: GetStream::Generated::Models::RepliesMeta

Inherits:
BaseModel
  • Object
show all
Defined in:
lib/getstream_ruby/generated/models/replies_meta.rb

Overview

Cursor & depth information for a comment’s direct replies. Mirrors Reddit’s ‘load more replies’ semantics.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from BaseModel

#==, #inspect, omit_empty_fields, #to_h, #to_json

Constructor Details

#initialize(attributes = {}) ⇒ RepliesMeta

Initialize with attributes



26
27
28
29
30
31
32
# File 'lib/getstream_ruby/generated/models/replies_meta.rb', line 26

def initialize(attributes = {})
  super(attributes)
  @depth_truncated = attributes[:depth_truncated] || attributes['depth_truncated']
  @has_more = attributes[:has_more] || attributes['has_more']
  @remaining = attributes[:remaining] || attributes['remaining']
  @next_cursor = attributes[:next_cursor] || attributes['next_cursor'] || nil
end

Instance Attribute Details

#depth_truncatedBoolean



14
15
16
# File 'lib/getstream_ruby/generated/models/replies_meta.rb', line 14

def depth_truncated
  @depth_truncated
end

#has_moreBoolean



17
18
19
# File 'lib/getstream_ruby/generated/models/replies_meta.rb', line 17

def has_more
  @has_more
end

#next_cursorString



23
24
25
# File 'lib/getstream_ruby/generated/models/replies_meta.rb', line 23

def next_cursor
  @next_cursor
end

#remainingInteger



20
21
22
# File 'lib/getstream_ruby/generated/models/replies_meta.rb', line 20

def remaining
  @remaining
end

Class Method Details

.json_field_mappingsObject

Override field mappings for JSON serialization



35
36
37
38
39
40
41
42
# File 'lib/getstream_ruby/generated/models/replies_meta.rb', line 35

def self.json_field_mappings
  {
    depth_truncated: 'depth_truncated',
    has_more: 'has_more',
    remaining: 'remaining',
    next_cursor: 'next_cursor'
  }
end