Sha256: 7acf091bd8fca072bfd75f97b4f2bd77d36c70968a5d490e77df82242e4ebb7d
Contents?: true
Size: 618 Bytes
Versions: 10
Compression:
Stored size: 618 Bytes
Contents
module FbGraph class TaggedObject < Node attr_accessor :name, :offset, :length def initialize(identifier, attributes = {}) super [:name, :offset, :length].each do |key| self.send("#{key}=", attributes[key]) end end def fetch_with_class_determination attributes = fetch_without_class_determination.raw_attributes klass = if attributes[:namespace] Application elsif attributes[:category] Page else User end klass.new attributes[:id], attributes end alias_method_chain :fetch, :class_determination end end
Version data entries
10 entries across 10 versions & 1 rubygems