Class: FbGraph2::Page

Direct Known Subclasses

Place

Instance Attribute Summary

Attributes inherited from Node

#access_token, #id

Instance Method Summary collapse

Methods included from Searchable

search, search

Methods included from Edge::Videos

#video!, #videos

Methods included from Edge::Tagged

#tagged

Methods included from Edge::Settings

#settings

Methods included from Edge::Roles::PageContext

#roles

Methods included from Edge::Ratings

#ratings

Methods included from Edge::PromotablePosts

#promotable_posts

Methods included from Edge::Posts

#posts

Methods included from Edge::Photos

#photo!, #photos

Methods included from Edge::Picture

#assign, #picture

Methods included from Edge::Offers

#offer!, #offers

Methods included from Edge::Milestones

#milestones

Methods included from Edge::Locations

#locations

Methods included from Edge::Insights

#insights

Methods included from Edge::GlobalBrandChildren

#global_brand_children

Methods included from Edge::Feed

#feed, #feed!

Methods included from Edge::Events

#events

Methods included from Edge::SendApi

#message!

Methods included from Edge::Conversations

#conversations

Methods included from Edge::Blocked

#block!, #blocked, #blocked?, #unblock!

Methods included from Edge::Albums

#album!, #albums

Methods included from Edge::Admins

#admin?, #admins

Methods inherited from Node

#authenticate, #destroy, #edge, #edges, #fetch, #update

Methods included from AttributeAssigner

#assign

Constructor Details

#initialize(id, attributes = {}) ⇒ Page

Returns a new instance of Page.



56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
# File 'lib/fb_graph2/page.rb', line 56

def initialize(id, attributes = {})
  super
  if attributes.include? :category_list
    self.category_list = attributes[:category_list].collect do |page_category|
      PageCategory.new page_category[:id], page_category
    end
  end
  if attributes.include? :context
    self.context = Struct::Context::PageContext.new attributes[:context]
  end
  if attributes.include? :parking
    self.parking = Struct::Parking.new attributes[:parking]
  end
  if attributes.include? :restaurant_services
    self.restaurant_services = Struct::RestaurantServices.new attributes[:restaurant_services]
  end
  if attributes.include? :restaurant_specialties
    self.restaurant_specialties = Struct::RestaurantSpecialties.new attributes[:restaurant_specialties]
  end
  if attributes.include? :payment_options
    self.payment_options = Struct::PaymentOptions.new attributes[:payment_options]
  end
end