種類
ライブラリ
- ビルトイン (996)
- forwardable (77)
-
irb
/ context (11) - openssl (33)
- pp (11)
- prettyprint (11)
- psych (44)
-
rdoc
/ context (66) -
rdoc
/ parser / ruby (11) -
rdoc
/ single _ class (11) -
rdoc
/ top _ level (44) - singleton (44)
- tracer (11)
クラス
- BasicObject (33)
- Encoding (886)
- Module (11)
- Object (55)
-
OpenSSL
:: SSL :: SSLContext (11) - PP (11)
- PrettyPrint (11)
-
Psych
:: Handler (11) -
Psych
:: Nodes :: Scalar (22) -
RDoc
:: Context (66) -
RDoc
:: Parser :: Ruby (11) -
RDoc
:: TopLevel (44) - Tracer (11)
モジュール
-
OpenSSL
:: SSL (22) - Process (11)
- SingleForwardable (66)
- Singleton (33)
キーワード
- CP1251 (11)
- CP1256 (11)
- CP1258 (11)
- CP720 (3)
- CP737 (11)
- CP775 (11)
- CP852 (11)
- CP855 (11)
- CP857 (11)
- CP860 (11)
- CP861 (11)
- CP862 (11)
- CP863 (11)
- CP864 (11)
- CP865 (11)
- CP866 (11)
- CP869 (11)
- CP878 (11)
- Context (11)
- Emitter (11)
- IBM720 (3)
- IBM737 (11)
- IBM775 (11)
- IBM852 (11)
- IBM855 (11)
- IBM857 (11)
- IBM860 (11)
- IBM861 (11)
- IBM862 (11)
- IBM863 (11)
- IBM864 (11)
- IBM865 (11)
- IBM866 (11)
- IBM869 (11)
-
ISO8859
_ 10 (11) -
ISO8859
_ 11 (11) -
ISO8859
_ 13 (11) -
ISO8859
_ 14 (11) -
ISO8859
_ 16 (11) -
ISO8859
_ 2 (11) -
ISO8859
_ 3 (11) -
ISO8859
_ 4 (11) -
ISO8859
_ 5 (11) -
ISO8859
_ 6 (11) -
ISO8859
_ 7 (11) -
ISO8859
_ 8 (11) -
ISO8859
_ 9 (11) -
ISO
_ 8859 _ 10 (11) -
ISO
_ 8859 _ 11 (11) -
ISO
_ 8859 _ 13 (11) -
ISO
_ 8859 _ 14 (11) -
ISO
_ 8859 _ 16 (11) -
ISO
_ 8859 _ 2 (11) -
ISO
_ 8859 _ 3 (11) -
ISO
_ 8859 _ 4 (11) -
ISO
_ 8859 _ 5 (11) -
ISO
_ 8859 _ 6 (11) -
ISO
_ 8859 _ 7 (11) -
ISO
_ 8859 _ 8 (11) -
ISO
_ 8859 _ 9 (11) -
KOI8
_ R (11) -
KOI8
_ U (11) - MACCENTEURO (11)
- MACCROATIAN (11)
- MACCYRILLIC (11)
- MACGREEK (11)
- MACICELAND (11)
- MACROMAN (11)
- MACROMANIA (11)
- MACTURKISH (11)
- MacCentEuro (11)
- MacCroatian (11)
- MacCyrillic (11)
- MacGreek (11)
- MacIceland (11)
- MacRoman (11)
- MacRomania (11)
- MacTurkish (11)
-
NEWS for Ruby 2
. 0 . 0 (11) -
NEWS for Ruby 3
. 0 . 0 (4) -
OP
_ SINGLE _ DH _ USE (11) -
OP
_ SINGLE _ ECDH _ USE (11) -
SINGLE
_ QUOTED (11) - Single (11)
- SingleClass (11)
- SingleForwardable (11)
- Singleton (11)
-
WINDOWS
_ 1251 (11) -
WINDOWS
_ 1256 (11) -
WINDOWS
_ 1258 (11) -
Windows
_ 1251 (11) -
Windows
_ 1256 (11) -
Windows
_ 1258 (11) -
add
_ class (11) -
add
_ class _ or _ module (22) -
add
_ module (11) -
all
_ classes _ and _ modules (11) - classes (11)
-
clock
_ gettime (11) - clone (11)
-
def
_ delegator (11) -
def
_ delegators (11) -
def
_ single _ delegator (11) -
def
_ single _ delegators (11) -
define
_ singleton _ method (22) - delegate (11)
- dup (11)
-
each
_ classmodule (11) -
find
_ class _ named (11) -
find
_ local _ symbol (11) - instance (11)
- irb (11)
- new (11)
-
rb
_ define _ singleton _ method (11) -
rb
_ obj _ singleton _ methods (11) -
rb
_ singleton _ class (11) -
rb
_ singleton _ class _ attached (11) -
rb
_ singleton _ class _ clone (11) -
rb
_ singleton _ class _ new (11) -
rdoc
/ single _ class (11) -
run
_ single _ final (11) - scalar (11)
-
set
_ visibility _ for (11) -
single
_ delegate (11) -
singleline
_ format (11) -
singleline
_ pp (11) - singleton (11)
-
singleton
_ class (11) -
singleton
_ class? (11) -
singleton
_ method (11) -
singleton
_ method _ added (11) -
singleton
_ method _ removed (11) -
singleton
_ method _ undefined (11) -
singleton
_ methods (11)
検索結果
先頭5件
-
irb (26096.0)
-
irb は Interactive Ruby の略です。 irb を使うと、Ruby の式を標準入力から簡単に入力・実行することができます。
...irb は Interactive Ruby の略です。
irb を使うと、Ruby の式を標準入力から簡単に入力・実行することができます。
=== irb の使い方
Ruby さえ知っていれば irb を使うのは簡単です。
irb コマンドを実行すると、以下のようなプロン......。
$ irb
irb(main):001:0>
あとは Ruby の式を入力するだけで、その式が実行され、結果が表示されます。
irb(main):001:0> 1+2
3
irb(main):002:0> class Foo
irb(main):003:1> def foo
irb(main):004:2> print 1
irb(main):005:2> end
irb(main):006:1>......る Binding
オブジェクトの作成方法を 0 から 3 で設定する。
(IRB::Context 参照)
--single-irb irb 中で self を実行して得られるオブジェクトをサブ irb と共
有する
--irb_debug n irb の... -
RDoc
:: Parser :: Ruby :: SINGLE -> "<<" (24201.0) -
RDoc::SingleClass type
...RDoc::SingleClass type... -
PrettyPrint
. singleline _ format(output = & # 39;& # 39; , maxwidth = 79 , newline = "\n" , genspace = lambda{|n| & # 39; & # 39; * n}) {|pp| . . . } -> object (21400.0) -
PrettyPrint オブジェクトを生成し、それを引数としてブロックを実行します。 PrettyPrint.format に似ていますが、改行しません。
...PrettyPrint オブジェクトを生成し、それを引数としてブロックを実行します。
PrettyPrint.format に似ていますが、改行しません。
引数 maxwidth, newline と genspace は無視されます。ブロック中の breakable の実行は、
改行せずに text......の実行であるかのように扱います。
@param output 出力先を指定します。output は << メソッドを持っていなければなりません。
@param maxwidth 無視されます。
@param newline 無視されます。
@param genspace 無視されます。... -
Object
# define _ singleton _ method(symbol) { . . . } -> Symbol (18324.0) -
self に特異メソッド name を定義します。
...m symbol メソッド名を String または Symbol で指定します。
@param method Proc、Method あるいは UnboundMethod の
いずれかのインスタンスを指定します。
@return メソッド名を表す Symbol を返します。
//emlist[][ruby]{
class A
class <<......self
def class_name
to_s
end
end
end
A.define_singleton_method(:who_am_i) do
"I am: #{class_name}"
end
A.who_am_i # ==> "I am: A"
guy = "Bob"
guy.define_singleton_method(:hello) { "#{self}: Hello there!" }
guy.hello #=> "Bob: Hello there!"
//}... -
Object
# define _ singleton _ method(symbol , method) -> Symbol (18324.0) -
self に特異メソッド name を定義します。
...m symbol メソッド名を String または Symbol で指定します。
@param method Proc、Method あるいは UnboundMethod の
いずれかのインスタンスを指定します。
@return メソッド名を表す Symbol を返します。
//emlist[][ruby]{
class A
class <<......self
def class_name
to_s
end
end
end
A.define_singleton_method(:who_am_i) do
"I am: #{class_name}"
end
A.who_am_i # ==> "I am: A"
guy = "Bob"
guy.define_singleton_method(:hello) { "#{self}: Hello there!" }
guy.hello #=> "Bob: Hello there!"
//}... -
PP
. singleline _ pp(obj , out= $ >) -> object (18300.0) -
指定されたオブジェクト obj を出力先 out に出力します。 ただし、インデントも改行もしません。 出力先 out を返します。
指定されたオブジェクト obj を出力先 out に出力します。
ただし、インデントも改行もしません。
出力先 out を返します。
@param obj 表示したいオブジェクトを指定します。
@param out 出力先を指定します。<< メソッドが定義されている必要があります。 -
static VALUE run
_ single _ final(VALUE *args) (18200.0) -
-
void rb
_ define _ singleton _ method(VALUE obj , const char *name , VALUE (*func)() , int argc) (18200.0) -
obj に特異メソッド name を定義します。 メソッドの実体を func に関数ポインタで与え、その関数がとる 引数のタイプを argc に渡します。argc のフォーマットに ついては rb_define_method の記述を参照してください。
...obj に特異メソッド name を定義します。
メソッドの実体を func に関数ポインタで与え、その関数がとる
引数のタイプを argc に渡します。argc のフォーマットに
ついては rb_define_method の記述を参照してください。... -
BasicObject
# singleton _ method _ undefined(name) -> object (15300.0) -
特異メソッドが Module#undef_method または undef により未定義にされた時にインタプリタから呼び出されます。
...フックには
Module#method_undefined を使います。
@param name 未定義にされたメソッド名が Symbol で渡されます。
//emlist[例][ruby]{
class Foo
def singleton_method_undefined(name)
puts "singleton method \"#{name}\" was undefined"
end
end
obj = Foo.new
def obj.f......oo
end
def obj.bar
end
class << obj
undef_method :foo
end
obj.instance_eval {undef bar}
#=> singleton method "foo" was undefined
# singleton method "bar" was undefined
//}
@see Module#method_undefined,BasicObject#singleton_method_added,BasicObject#singleton_method_removed , d:spec/def#undef... -
Psych
:: Nodes :: Scalar :: SINGLE _ QUOTED -> Integer (12317.0) -
single quoted style を表します。
...single quoted style を表します。
@see Psych::Nodes::Scalar.new,
Psych::Nodes::Scalar#style,
Psych::Handler#scalar...