Class: Oksky::Chat::Object::MasterKeywordsResource
- Inherits:
-
Base
- Object
- Base
- Oksky::Chat::Object::MasterKeywordsResource
show all
- Defined in:
- lib/oksky/chat/object/master_keywords_resource.rb
Instance Method Summary
collapse
Methods inherited from Base
#[], #initialize
Instance Method Details
6
7
8
|
# File 'lib/oksky/chat/object/master_keywords_resource.rb', line 6
def id
@src.dig("id")
end
|
18
19
20
|
# File 'lib/oksky/chat/object/master_keywords_resource.rb', line 18
def key_name
content_value.dig("key_name")
end
|
#key_title ⇒ Object
22
23
24
|
# File 'lib/oksky/chat/object/master_keywords_resource.rb', line 22
def key_title
content_value.dig("key_title")
end
|
#master_keyword ⇒ Object
10
11
12
13
14
15
16
|
# File 'lib/oksky/chat/object/master_keywords_resource.rb', line 10
def master_keyword
if @src.has_key?('attributes')
@src['attributes']
else
@src
end
end
|
#relationships ⇒ Object
31
32
33
34
35
36
37
|
# File 'lib/oksky/chat/object/master_keywords_resource.rb', line 31
def relationships
if exist_relationships?
return @src['relationships']
else
{}
end
end
|
#suggestions ⇒ Array
27
28
29
|
# File 'lib/oksky/chat/object/master_keywords_resource.rb', line 27
def suggestions
content_value.dig("suggestions")
end
|
#user_infos ⇒ Array
40
41
42
|
# File 'lib/oksky/chat/object/master_keywords_resource.rb', line 40
def user_infos
relationships.dig("user_infos", "data")
end
|