Sha256: e057e59cafebc6d743c8e5124c185755215a93fdd8b22e7fb5c83f083a68ce53

Contents?: true

Size: 553 Bytes

Versions: 1

Compression:

Stored size: 553 Bytes

Contents

module FbGraph
  class Status < Node
    include Connections::Comments

    attr_accessor :from, :message, :updated_time

    def initialize(identifier, options = {})
      super
      if (from = options[:from])
        @from = if from[:category]
          FbGraph::Page.new(from.delete(:id), from)
        else
          FbGraph::User.new(from.delete(:id), from)
        end
      end
      @message = options[:message]
      if (updated_time = options.delete(:updated_time))
        @updated_time = Time.parse(updated_time)
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
fb_graph-0.0.8 lib/fb_graph/status.rb