別のキーワード
種類
- インスタンスメソッド (1004)
- 特異メソッド (441)
- モジュール関数 (252)
- 文書 (74)
ライブラリ
クラス
- Array (231)
- CSV (11)
- Dir (22)
- Enumerator (33)
- Fiber (37)
- GDBM (11)
- Hash (66)
- IO (209)
- Integer (3)
- Matrix (22)
- Module (60)
-
Net
:: FTP (22) -
Net
:: HTTP (22) -
Net
:: POP3 (22) -
Net
:: POPMail (99) -
Net
:: SMTP (56) - Object (56)
-
OpenSSL
:: X509 :: Name (11) - PStore (11)
- Range (139)
- SDBM (11)
- Socket (11)
- Thread (18)
- WIN32OLE (44)
-
WIN32OLE
_ TYPELIB (11) -
YAML
:: DBM (11)
モジュール
- Comparable (10)
- Enumerable (132)
- JSON (33)
- Kernel (164)
- Marshal (22)
-
MiniTest
:: Assertions (7) - ObjectSpace (33)
- Psych (33)
- URI (14)
キーワード
-
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (11) - < (11)
- <= (11)
- > (11)
- >= (11)
- Array (11)
- Float (11)
- Integer (11)
-
NEWS for Ruby 2
. 0 . 0 (11) -
NEWS for Ruby 2
. 1 . 0 (11) -
NEWS for Ruby 2
. 5 . 0 (7) -
NEWS for Ruby 2
. 7 . 0 (5) -
NEWS for Ruby 3
. 0 . 0 (4) - Rational (11)
- Rubyの起動 (3)
- [] (33)
-
_ invoke (11) -
add
_ entry (11) - all (33)
-
assert
_ empty (1) -
assert
_ equal (1) -
assert
_ includes (1) -
assert
_ instance _ of (1) -
assert
_ nil (1) -
assert
_ respond _ to (1) -
assert
_ same (1) - at (11)
- begin (11)
- bsearch (44)
- clamp (10)
-
cofactor
_ expansion (11) -
connect
_ nonblock (11) -
count
_ nodes (11) -
count
_ objects _ size (11) -
count
_ tdata _ objects (11) - delete (22)
-
delete
_ at (11) - detect (22)
- dump (11)
-
enum
_ for (22) - eval (22)
- feed (11)
- fetch (62)
- find (22)
- first (44)
-
for
_ fd (11) - generate (11)
- gets (11)
- invoke (11)
- lambda (13)
-
laplace
_ expansion (11) - last (22)
- load (22)
-
load
_ stream (22) - loop (22)
- mail (33)
- max (86)
-
method
_ missing (11) - min (86)
- mktmpdir (22)
-
must
_ be _ nil (1) - new (66)
-
next
_ values (11) - open (74)
-
peek
_ values (11) -
pending
_ interrupt? (11) - pop (55)
- popen (154)
- proc (14)
- public (16)
-
read
_ nonblock (11) - readline (11)
- rehash (11)
- restore (11)
- resume (11)
-
ruby 1
. 6 feature (11) -
ruby 1
. 8 . 4 feature (11) - sample (44)
- shift (22)
-
singleton
_ class (11) - start (100)
- throw (11)
-
to
_ enum (22) -
try
_ convert (3) - unparse (11)
- yield (11)
- zip (22)
検索結果
先頭5件
-
Fiber
# raise(exception , message = nil , backtrace = nil) -> object (18420.0) -
selfが表すファイバーが最後に Fiber.yield を呼んだ場所で例外を発生させます。
...ew { Fiber.yield }
f.resume
f.raise "Error!" # => Error! (RuntimeError)
//}
//emlist[ファイバー内のイテレーションを終了させる例][ruby]{
f = Fiber.new do
loop do
Fiber.yield(:loop)
end
:exit
end
p f.resume # => :loop
p f.raise StopIteration # => :exit
//}... -
Fiber
# raise -> object (18220.0) -
selfが表すファイバーが最後に Fiber.yield を呼んだ場所で例外を発生させます。
...ew { Fiber.yield }
f.resume
f.raise "Error!" # => Error! (RuntimeError)
//}
//emlist[ファイバー内のイテレーションを終了させる例][ruby]{
f = Fiber.new do
loop do
Fiber.yield(:loop)
end
:exit
end
p f.resume # => :loop
p f.raise StopIteration # => :exit
//}... -
Fiber
# raise(message) -> object (18220.0) -
selfが表すファイバーが最後に Fiber.yield を呼んだ場所で例外を発生させます。
...ew { Fiber.yield }
f.resume
f.raise "Error!" # => Error! (RuntimeError)
//}
//emlist[ファイバー内のイテレーションを終了させる例][ruby]{
f = Fiber.new do
loop do
Fiber.yield(:loop)
end
:exit
end
p f.resume # => :loop
p f.raise StopIteration # => :exit
//}... -
Object
# must _ be _ nil -> true (15135.0) -
自身が nil である場合、検査にパスしたことになります。
...自身が nil である場合、検査にパスしたことになります。
@raise MiniTest::Assertion 自身が nil でない場合に発生します。
@see MiniTest::Assertions#assert_nil... -
ObjectSpace
. # count _ objects _ size(result _ hash = nil) -> Hash (9207.0) -
型ごとのオブジェクトサイズをバイト単位で格納したハッシュを返します。
...す。特に T_DATA の合計値は正しくないでしょう。
//emlist[例][ruby]{
ObjectSpace.count_objects_size
# => {:TOTAL=>1461154, :T_CLASS=>158280, :T_MODULE=>20672, :T_STRING=>527249, ...}
//}
@raise TypeError result_hash にハッシュ以外を指定した時に発生します。... -
ObjectSpace
. # count _ tdata _ objects(result _ hash = nil) -> Hash (9207.0) -
T_DATA の種類ごとにオブジェクトの数を格納したハッシュを返します。
...@raise TypeError result_hash にハッシュ以外を指定した時に発生します。
本メソッドは普通の Ruby プログラマ向けのメソッドではありません。パフォー
マンスに興味のある C Ruby の開発者向けのものです。
//emlist[例][ruby]{
ObjectSp......ace.count_tdata_objects
# => {RubyVM::InstructionSequence=>504, :parser=>5, :barrier=>6,
# :mutex=>6, Proc=>60, RubyVM::Env=>57, Mutex=>1, Encoding=>99,
# ThreadGroup=>1, Binding=>1, Thread=>1, RubyVM=>1, :iseq=>1,
# Random=>1, ARGF.class=>1, Data=>1, :autoload=>3, Time=>2}
//}
現在... -
Object
# singleton _ class -> Class (9036.0) -
レシーバの特異クラスを返します。 まだ特異クラスがなければ、新しく作成します。
...す。
レシーバが nil か true か false なら、それぞれ NilClass, TrueClass,
FalseClass を返します。
@raise TypeError レシーバが Integer、Float、Symbol の場合に発生します。
//emlist[][ruby]{
Object.new.singleton_class #=> #<Class:#<Object:0xb7ce1e24>>
String.si......ngleton_class #=> #<Class:String>
nil.singleton_class #=> NilClass
//}
@see Object#class... -
Object
# enum _ for(method = :each , *args) -> Enumerator (9012.0) -
Enumerator.new(self, method, *args) を返します。
...る場合)][ruby]{
module Enumerable
def repeat(n)
raise ArgumentError, "#{n} is negative!" if n < 0
unless block_given?
# __method__ はここでは :repeat
return to_enum(__method__, n) do
# size メソッドが nil でなければ size * n を返す。
sz = s... -
Object
# enum _ for(method = :each , *args) {|*args| . . . } -> Enumerator (9012.0) -
Enumerator.new(self, method, *args) を返します。
...る場合)][ruby]{
module Enumerable
def repeat(n)
raise ArgumentError, "#{n} is negative!" if n < 0
unless block_given?
# __method__ はここでは :repeat
return to_enum(__method__, n) do
# size メソッドが nil でなければ size * n を返す。
sz = s... -
Object
# to _ enum(method = :each , *args) -> Enumerator (9012.0) -
Enumerator.new(self, method, *args) を返します。
...る場合)][ruby]{
module Enumerable
def repeat(n)
raise ArgumentError, "#{n} is negative!" if n < 0
unless block_given?
# __method__ はここでは :repeat
return to_enum(__method__, n) do
# size メソッドが nil でなければ size * n を返す。
sz = s... -
Object
# to _ enum(method = :each , *args) {|*args| . . . } -> Enumerator (9012.0) -
Enumerator.new(self, method, *args) を返します。
...る場合)][ruby]{
module Enumerable
def repeat(n)
raise ArgumentError, "#{n} is negative!" if n < 0
unless block_given?
# __method__ はここでは :repeat
return to_enum(__method__, n) do
# size メソッドが nil でなければ size * n を返す。
sz = s... -
MiniTest
:: Assertions # assert _ nil(object , message = nil) -> true (6337.0) -
与えられたオブジェクトが nil である場合、検査にパスしたことになります。
...与えられたオブジェクトが nil である場合、検査にパスしたことになります。
@param object 任意のオブジェクトを指定します。
@param message 検査に失敗した場合に表示するメッセージを指定します。
文字列か Proc......を指定します。Proc である場合は Proc#call した
結果を使用します。
@raise MiniTest::Assertion 与えられたオブジェクトが nil でない場合に発生します。... -
ObjectSpace
. # count _ nodes(result _ hash = nil) -> Hash (3107.0) -
ノードの種類ごとの数を格納したハッシュを返します。
...作成します。result_hash の内容は上書き
されます。プローブ効果を避けるために使用します。
@raise TypeError result_hash にハッシュ以外を指定した時に発生します。
本メソッドは普通の Ruby プログラマ向けのメソ......はありません。パフォー
マンスやメモリ管理に興味のある C Ruby の開発者向けのものです。
//emlist[例][ruby]{
ObjectSpace.count_nodes
# => {:NODE_METHOD=>2027, :NODE_FBODY=>1927, :NODE_CFUNC=>1798, ...}
//}
戻り値のハッシュは処理系に依存します...