Flowdock
method

instance_variable_names

Importance_1
instance_variable_names() public

Returns an array of instance variable names as strings including “@”.

class C
  def initialize(x, y)
    @x, @y = x, y
  end
end

C.new(0, 1).instance_variable_names # => ["@y", "@x"]
Show source
Register or log in to add new notes.