Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
VRChat.rb_2_Rubyオブジェクトの世界.pdf
Search
ItoJum
May 12, 2026
44
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
VRChat.rb_2_Rubyオブジェクトの世界.pdf
ItoJum
May 12, 2026
More Decks by ItoJum
See All by ItoJum
VRChat.rb_11_メタプログラミングRubyのご紹介.pdf
itojum
0
13
従業員データ基盤でのパターンマッチをご紹介_Roppongi.rb スポンサーLT
itojum
0
65
DXRuby互換のPicoRuby.wasmライブラリを作っている
itojum
1
47
RubyKaigi_2026_follow_up_SmartHRスポンサーLT
itojum
0
22
サマーインターンシップのメン ターをやって得た学び5選_あつまれ!若⼿エンジニアのLT&ゆるっと交流会
itojum
0
270
SmartHRを支える従業員データ基盤とそのインフラ_Innovative Crosstalk Jamboree Geeks '26
itojum
0
400
VRChat.rbの野望.pdf
itojum
0
14
なぜtree-sitter-rubyの日本語シンボルはシンタックスハイライトされないのか
itojum
0
96
Ractorを試してみるぞ!+メタバースにおける地域.rbをやっているぜ
itojum
0
56
Featured
See All Featured
BBQ
matthewcrist
89
10k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
3k
Bash Introduction
62gerente
615
220k
Side Projects
sachag
456
43k
The SEO Collaboration Effect
kristinabergwall1
1
570
How to Ace a Technical Interview
jacobian
281
24k
The #1 spot is gone: here's how to win anyway
tamaranovitovic
4
1.2k
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
6.1k
Dominate Local Search Results - an insider guide to GBP, reviews, and Local SEO
greggifford
PRO
0
340
Practical Orchestrator
shlominoach
192
12k
Darren the Foodie - Storyboard
khoart
PRO
4
3.9k
Transcript
None
Ruby オブジェクトの世界 VRChat.rb #2 いとじゅん
オブジェクトとインスタンスについて オブジェクト = Ruby で扱える全ての値 インスタンス = クラスに対するオブジェクトのこと 本発表では、インスタンス ==
オブジェクトみたい にしゃべります
Rubyのオブジェクトな ものを見ていこう
値 p 168.class # => Integer p "yachi".class # =>
String p true.class # => TrueClass p false.class # => FalseClass p nil.class # => NilClass
値 p 168.class # => Integer p "yachi".class # =>
String p true.class # => TrueClass p false.class # => FalseClass p nil.class # => NilClass みんなクラスのインスタン スファミリー
クラス p Integer.class # => Class p String.class # =>
Class p TrueClass.class # => Class p FalseClass.class # => Class p NilClass.class # => Class
クラス p Integer.class # => Class p String.class # =>
Class p TrueClass.class # => Class p FalseClass.class # => Class p NilClass.class # => Class p Class.class # => Class クラスもClassの インスタンス
演算子 p "超".method("+") # => #<Method: String#+(_)> p "か".method("*") #
=> #<Method: String#*(_)> p "や".method("==") # => #<Method: String#==(_)> p "ぐ".method("!=") # => #<Method: String(BasicObject)#!=(_)> p "姫".method("<") # => #<Method: String(Comparable)#<(_)> p "!".method("&&") # => NameError
演算子 p "超".method("+") # => #<Method: String#+(_)> p "か".method("*") #
=> #<Method: String#*(_)> p "や".method("==") # => #<Method: String#==(_)> p "ぐ".method("!=") # => #<Method: String(BasicObject)#!=(_)> p "姫".method("<") # => #<Method: String(Comparable)#<(_)> p "!".method("&&") # => NameError これはオブジェク トじゃない
継承チェーン クラスやモジュールの継承の連なり p "cpk".class.ancestors # => [String, Comparable, Object, Kernel,
BasicObject] じゃあ、この出てきたやつらはオブジェクト?
継承チェーン p String.class # => Class p Comparable.class # =>
Module p Object.class # => Class p Kernel.class # => Module p BasicObject.class # => Class
継承チェーン p String.class # => Class p Comparable.class # =>
Module p Object.class # => Class p Kernel.class # => Module p BasicObject.class # => Class Classクラスと Moduleクラスのイ ンスタンスファミ リー
おわりに • Rubyはいろいろなものがオブジェクトで構成されている • クラスもオブジェクト、モジュールもオブジェクト • 言語仕様が簡単に可視化できちゃうので、 覗いてみるとたのしいよ