Class: FbGraph2::Page
- Extended by:
- Searchable
- Includes:
- Edge::Admins, Edge::Albums, Edge::Blocked, Edge::Conversations, Edge::Events, Edge::Feed, Edge::GlobalBrandChildren, Edge::Insights, Edge::Locations, Edge::Milestones, Edge::Offers, Edge::Photos, Edge::Picture, Edge::Posts, Edge::PromotablePosts, Edge::Ratings, Edge::Roles::PageContext, Edge::SendApi, Edge::Settings, Edge::Tagged, Edge::Videos
- Defined in:
- lib/fb_graph2/page.rb
Direct Known Subclasses
Instance Attribute Summary
Attributes inherited from Node
Instance Method Summary collapse
-
#initialize(id, attributes = {}) ⇒ Page
constructor
A new instance of Page.
Methods included from Searchable
Methods included from Edge::Videos
Methods included from Edge::Tagged
Methods included from Edge::Settings
Methods included from Edge::Roles::PageContext
Methods included from Edge::Ratings
Methods included from Edge::PromotablePosts
Methods included from Edge::Posts
Methods included from Edge::Photos
Methods included from Edge::Picture
Methods included from Edge::Offers
Methods included from Edge::Milestones
Methods included from Edge::Locations
Methods included from Edge::Insights
Methods included from Edge::GlobalBrandChildren
Methods included from Edge::Feed
Methods included from Edge::Events
Methods included from Edge::SendApi
Methods included from Edge::Conversations
Methods included from Edge::Blocked
#block!, #blocked, #blocked?, #unblock!
Methods included from Edge::Albums
Methods included from Edge::Admins
Methods inherited from Node
#authenticate, #destroy, #edge, #edges, #fetch, #update
Methods included from AttributeAssigner
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. = Struct::PaymentOptions.new attributes[:payment_options] end end |