Class: GetStream::Generated::Models::EnrichedReaction

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

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 = {}) ⇒ EnrichedReaction

Initialize with attributes



53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 53

def initialize(attributes = {})
  super(attributes)
  @activity_id = attributes[:activity_id] || attributes['activity_id']
  @kind = attributes[:kind] || attributes['kind']
  @user_id = attributes[:user_id] || attributes['user_id']
  @id = attributes[:id] || attributes['id'] || nil
  @parent = attributes[:parent] || attributes['parent'] || nil
  @target_feeds = attributes[:target_feeds] || attributes['target_feeds'] || nil
  @children_counts = attributes[:children_counts] || attributes['children_counts'] || nil
  @created_at = attributes[:created_at] || attributes['created_at'] || nil
  @data = attributes[:data] || attributes['data'] || nil
  @latest_children = attributes[:latest_children] || attributes['latest_children'] || nil
  @own_children = attributes[:own_children] || attributes['own_children'] || nil
  @updated_at = attributes[:updated_at] || attributes['updated_at'] || nil
  @user = attributes[:user] || attributes['user'] || nil
end

Instance Attribute Details

#activity_idString

Returns:

  • (String)


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

def activity_id
  @activity_id
end

#children_countsHash<String, Integer>

Returns:

  • (Hash<String, Integer>)


32
33
34
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 32

def children_counts
  @children_counts
end

#created_atTime

Returns:



35
36
37
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 35

def created_at
  @created_at
end

#dataObject

Returns:

  • (Object)


38
39
40
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 38

def data
  @data
end

#idString

Returns:

  • (String)


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

def id
  @id
end

#kindString

Returns:

  • (String)


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

def kind
  @kind
end

#latest_childrenHash<String, Array<EnrichedReaction>>

Returns:



41
42
43
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 41

def latest_children
  @latest_children
end

#own_childrenHash<String, Array<EnrichedReaction>>

Returns:



44
45
46
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 44

def own_children
  @own_children
end

#parentString

Returns:

  • (String)


26
27
28
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 26

def parent
  @parent
end

#target_feedsArray<String>

Returns:

  • (Array<String>)


29
30
31
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 29

def target_feeds
  @target_feeds
end

#updated_atTime

Returns:



47
48
49
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 47

def updated_at
  @updated_at
end

#userData

Returns:



50
51
52
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 50

def user
  @user
end

#user_idString

Returns:

  • (String)


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

def user_id
  @user_id
end

Class Method Details

.json_field_mappingsObject

Override field mappings for JSON serialization



71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
# File 'lib/getstream_ruby/generated/models/enriched_reaction.rb', line 71

def self.json_field_mappings
  {
    activity_id: 'activity_id',
    kind: 'kind',
    user_id: 'user_id',
    id: 'id',
    parent: 'parent',
    target_feeds: 'target_feeds',
    children_counts: 'children_counts',
    created_at: 'created_at',
    data: 'data',
    latest_children: 'latest_children',
    own_children: 'own_children',
    updated_at: 'updated_at',
    user: 'user'
  }
end