クラスについての解説です。こちらの内容を解説してみました。 https://www.ruby-lang.org/ja/documentation/quickstart/3/
http://www.nicovideo.jp/watch/sm38589979