Class: FbGraph::Targeting
- Inherits:
-
Object
- Object
- FbGraph::Targeting
- Includes:
- Comparison
- Defined in:
- lib/fb_graph/targeting.rb
Instance Attribute Summary (collapse)
-
- (Object) city
Returns the value of attribute city.
-
- (Object) country
Returns the value of attribute country.
-
- (Object) locale
Returns the value of attribute locale.
-
- (Object) region
Returns the value of attribute region.
Instance Method Summary (collapse)
-
- (Targeting) initialize(attributes = {})
constructor
A new instance of Targeting.
- - (Object) to_hash(options = {})
Methods included from Comparison
Constructor Details
- (Targeting) initialize(attributes = {})
A new instance of Targeting
7 8 9 10 11 12 |
# File 'lib/fb_graph/targeting.rb', line 7 def initialize(attributes = {}) @country = attributes[:country] @city = attributes[:city] @region = attributes[:region] @locale = attributes[:locale] end |
Instance Attribute Details
- (Object) city
Returns the value of attribute city
5 6 7 |
# File 'lib/fb_graph/targeting.rb', line 5 def city @city end |
- (Object) country
Returns the value of attribute country
5 6 7 |
# File 'lib/fb_graph/targeting.rb', line 5 def country @country end |
- (Object) locale
Returns the value of attribute locale
5 6 7 |
# File 'lib/fb_graph/targeting.rb', line 5 def locale @locale end |
- (Object) region
Returns the value of attribute region
5 6 7 |
# File 'lib/fb_graph/targeting.rb', line 5 def region @region end |
Instance Method Details
- (Object) to_hash(options = {})
14 15 16 17 18 19 20 21 |
# File 'lib/fb_graph/targeting.rb', line 14 def to_hash( = {}) { :country => self.country, :city => self.city, :region => self.region, :locale => self.locale } end |