Class: GetStream::Generated::Models::ChannelStateResponseFields
- Inherits:
-
BaseModel
- Object
- BaseModel
- GetStream::Generated::Models::ChannelStateResponseFields
- Defined in:
- lib/getstream_ruby/generated/models/channel_state_response_fields.rb
Instance Attribute Summary collapse
-
#active_live_locations ⇒ Array<SharedLocationResponseData>
Active live locations in the channel.
- #channel ⇒ ChannelResponse
- #draft ⇒ DraftResponse
-
#hidden ⇒ Boolean
Whether this channel is hidden or not.
-
#hide_messages_before ⇒ DateTime
Messages before this date are hidden from the user.
-
#members ⇒ Array<ChannelMemberResponse>
List of channel members.
- #membership ⇒ ChannelMemberResponse
-
#messages ⇒ Array<MessageResponse>
List of channel messages.
-
#pending_messages ⇒ Array<PendingMessageResponse>
Pending messages that this user has sent.
-
#pinned_messages ⇒ Array<MessageResponse>
List of pinned messages in the channel.
- #push_preferences ⇒ ChannelPushPreferencesResponse
-
#read ⇒ Array<ReadStateResponse>
List of read states.
- #threads ⇒ Array<ThreadStateResponse>
-
#watcher_count ⇒ Integer
Number of channel watchers.
-
#watchers ⇒ Array<UserResponse>
List of user who is watching the channel.
Class Method Summary collapse
-
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization.
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ ChannelStateResponseFields
constructor
Initialize with attributes.
Methods inherited from BaseModel
#==, #inspect, omit_empty_fields, #to_h, #to_json
Constructor Details
#initialize(attributes = {}) ⇒ ChannelStateResponseFields
Initialize with attributes
59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 59 def initialize(attributes = {}) super(attributes) @members = attributes[:members] || attributes['members'] = attributes[:messages] || attributes['messages'] = attributes[:pinned_messages] || attributes['pinned_messages'] @threads = attributes[:threads] || attributes['threads'] @hidden = attributes[:hidden] || attributes['hidden'] || nil = attributes[:hide_messages_before] || attributes['hide_messages_before'] || nil @watcher_count = attributes[:watcher_count] || attributes['watcher_count'] || nil @active_live_locations = attributes[:active_live_locations] || attributes['active_live_locations'] || nil = attributes[:pending_messages] || attributes['pending_messages'] || nil @read = attributes[:read] || attributes['read'] || nil @watchers = attributes[:watchers] || attributes['watchers'] || nil @channel = attributes[:channel] || attributes['channel'] || nil @draft = attributes[:draft] || attributes['draft'] || nil @membership = attributes[:membership] || attributes['membership'] || nil @push_preferences = attributes[:push_preferences] || attributes['push_preferences'] || nil end |
Instance Attribute Details
#active_live_locations ⇒ Array<SharedLocationResponseData>
35 36 37 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 35 def active_live_locations @active_live_locations end |
#channel ⇒ ChannelResponse
47 48 49 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 47 def channel @channel end |
#draft ⇒ DraftResponse
50 51 52 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 50 def draft @draft end |
#hidden ⇒ Boolean
26 27 28 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 26 def hidden @hidden end |
#hide_messages_before ⇒ DateTime
29 30 31 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 29 def end |
#members ⇒ Array<ChannelMemberResponse>
14 15 16 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 14 def members @members end |
#membership ⇒ ChannelMemberResponse
53 54 55 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 53 def membership @membership end |
#messages ⇒ Array<MessageResponse>
17 18 19 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 17 def end |
#pending_messages ⇒ Array<PendingMessageResponse>
38 39 40 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 38 def end |
#pinned_messages ⇒ Array<MessageResponse>
20 21 22 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 20 def end |
#push_preferences ⇒ ChannelPushPreferencesResponse
56 57 58 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 56 def push_preferences @push_preferences end |
#read ⇒ Array<ReadStateResponse>
41 42 43 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 41 def read @read end |
#threads ⇒ Array<ThreadStateResponse>
23 24 25 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 23 def threads @threads end |
#watcher_count ⇒ Integer
32 33 34 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 32 def watcher_count @watcher_count end |
#watchers ⇒ Array<UserResponse>
44 45 46 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 44 def watchers @watchers end |
Class Method Details
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 |
# File 'lib/getstream_ruby/generated/models/channel_state_response_fields.rb', line 79 def self.json_field_mappings { members: 'members', messages: 'messages', pinned_messages: 'pinned_messages', threads: 'threads', hidden: 'hidden', hide_messages_before: 'hide_messages_before', watcher_count: 'watcher_count', active_live_locations: 'active_live_locations', pending_messages: 'pending_messages', read: 'read', watchers: 'watchers', channel: 'channel', draft: 'draft', membership: 'membership', push_preferences: 'push_preferences' } end |