class PrivateMessage attr_accessor :tweet_id, :sender_id, :raw_text, :sent_at def initialize(options = {}) options.keys.each do |key| send("#{key}=", options[key]) if respond_to?("#{key}=") end end end