Class: FbGraph::AdKeyword
- Inherits:
-
Node
- Object
- Node
- FbGraph::AdKeyword
- Extended by:
- Searchable
- Defined in:
- lib/fb_graph/ad_keyword.rb
Direct Known Subclasses
Instance Attribute Summary (collapse)
-
- (Object) description
Returns the value of attribute description.
-
- (Object) name
Returns the value of attribute name.
Attributes inherited from Node
#access_token, #endpoint, #identifier, #raw_attributes
Instance Method Summary (collapse)
-
- (AdKeyword) initialize(identifier, attributes = {})
constructor
A new instance of AdKeyword.
- - (Boolean) topic_keyword?
Methods included from Searchable
search, search, search_query_param
Methods inherited from Node
#connection, #destroy, fetch, #fetch, #update
Methods included from Comparison
Constructor Details
- (AdKeyword) initialize(identifier, attributes = {})
A new instance of AdKeyword
7 8 9 10 11 12 13 |
# File 'lib/fb_graph/ad_keyword.rb', line 7 def initialize(identifier, attributes = {}) super %w(name description).each do |field| self.send("#{field}=", attributes[field.to_sym]) end end |
Instance Attribute Details
- (Object) description
Returns the value of attribute description
5 6 7 |
# File 'lib/fb_graph/ad_keyword.rb', line 5 def description @description end |
- (Object) name
Returns the value of attribute name
5 6 7 |
# File 'lib/fb_graph/ad_keyword.rb', line 5 def name @name end |
Instance Method Details
- (Boolean) topic_keyword?
15 16 17 |
# File 'lib/fb_graph/ad_keyword.rb', line 15 def topic_keyword? (name =~ /^#/) == 0 end |