Sha256: 55145856faa93e50ca72a54a6ca73be46874ebd39f546ef11762a7345e80977c

Contents?: true

Size: 299 Bytes

Versions: 1

Compression:

Stored size: 299 Bytes

Contents

class Actor
  
  attr_reader :actor
  
  def initialize(object)
    @actor = { "event[actor][type]" => object.to_s }
  end
  
  def to_json
    @actor = JSON.generate(@actor)
  end
  
  # TODO
  # def to_hash
  #   @actor = JSON.parse(@actor)
  # end
  
  def inspect
    @actor.inspect
  end
  
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
eotb-0.1.5 lib/actor.rb