Terminology

attr_accessor <:variable_list> Dynamically defines accessor methods for one or more class properties. In a modal, defines one or more values that you don't want to store in the database directly and that will only exist for the life of the object.

<class>.new Instantiate a class.

def initialize(<variable_list>) Define the constructor for a Ruby class.

def <method_name> Define a method, or the getter of a property.

def <method_name>=(<variable>) Define the setter of a property.

def self.<name>(<variable_list>) Define a class method for a Ruby class.

def to_s Defines the method that returns a string representation of the object.

ObjectSpace.each_object(<class_name>) Iterate through each instance of a Ruby class.

rescue Designates an exception-handling clause.

yield Execute a block.

Facts, Thoughts and Opinions

Images

[[/div]]
  •   Subtopics

  •   Writings

  Sources & Bookmarks

Name/Link Date