別のキーワード
クラス
-
ARGF
. class (36) - Array (2156)
- Binding (47)
- Complex (12)
- Data (6)
- Encoding (12)
-
Encoding
:: Converter (84) -
Encoding
:: InvalidByteSequenceError (24) - Enumerator (132)
-
Enumerator
:: Lazy (386) -
Enumerator
:: Yielder (30) -
File
:: Stat (48) - Hash (535)
- IO (102)
- Integer (8)
- MatchData (36)
- Method (70)
- Module (220)
- Mutex (4)
- NilClass (12)
- Numeric (86)
- Object (136)
-
ObjectSpace
:: WeakMap (12) - Proc (66)
- Random (36)
- Range (50)
- Rational (12)
-
RubyVM
:: AbstractSyntaxTree :: Node (49) -
RubyVM
:: InstructionSequence (130) - Set (9)
- String (211)
- Struct (28)
- Symbol (71)
- Thread (48)
-
Thread
:: Mutex (20) -
Thread
:: Queue (10) - Time (212)
- TracePoint (43)
- UnboundMethod (36)
モジュール
- Enumerable (526)
キーワード
- & (12)
- * (24)
- + (12)
- - (12)
- << (24)
- <=> (24)
- == (12)
- [] (48)
- []= (60)
-
absolute
_ path (12) -
alias
_ method (4) - all? (21)
- any? (62)
- anybits? (8)
- append (8)
-
append
_ as _ bytes (1) - argv (12)
- arity (36)
- assoc (24)
- at (12)
- attr (12)
-
attr
_ accessor (4) -
attr
_ reader (4) -
attr
_ writer (4) -
base
_ label (12) - bsearch (48)
-
bsearch
_ index (20) - bytebegin (2)
- byteend (2)
- byteindex (3)
- byteoffset (6)
- byterindex (3)
- bytes (36)
- bytesize (12)
- byteslice (36)
-
callee
_ id (12) - casecmp (12)
- casecmp? (9)
- children (7)
- chunk (24)
-
class
_ variables (12) - classify (3)
- clear (12)
- clone (12)
- coerce (24)
- collect (36)
- collect! (24)
-
collect
_ concat (24) - combination (24)
- compact (16)
- compact! (12)
-
compare
_ by _ identity (12) -
compare
_ by _ identity? (12) - concat (21)
- constants (12)
- convpath (12)
- count (36)
- crypt (12)
- curry (46)
- cycle (48)
- day (12)
-
deconstruct
_ keys (13) - default (12)
-
define
_ method (24) -
define
_ singleton _ method (24) - delete (48)
-
delete
_ at (12) -
delete
_ if (36) - difference (7)
- dig (30)
- directory? (12)
- disasm (12)
- disassemble (12)
- display (12)
- drop (36)
-
drop
_ while (48) - dummy? (12)
- dup (12)
- each (84)
-
each
_ byte (48) -
each
_ entry (24) -
each
_ index (24) -
each
_ key (24) -
each
_ pair (12) - eager (6)
- empty? (49)
-
end
_ with? (6) - entries (7)
-
enum
_ for (24) - eql? (12)
-
error
_ bytes (12) - eval (12)
- event (12)
- except (4)
- fdatasync (12)
- fetch (72)
-
fetch
_ values (22) - fill (72)
- filter (28)
- filter! (21)
-
filter
_ map (6) -
find
_ all (12) -
find
_ index (36) - first (36)
-
first
_ column (7) -
first
_ lineno (19) -
flat
_ map (24) - flatten (24)
- flatten! (12)
- force (12)
- friday? (12)
- ftype (12)
- getbyte (24)
- getgm (12)
- getutc (12)
- grep (12)
-
grep
_ v (10) -
group
_ by (24) -
has
_ key? (12) - hash (12)
- imaginary (24)
- include? (24)
-
incomplete
_ input? (12) - index (36)
-
initialize
_ copy (12) - inject (24)
- insert (12)
- inspect (37)
-
instance
_ methods (12) -
instance
_ variables (12) -
instruction
_ sequence (7) - intern (12)
- intersect? (4)
- intersection (6)
- isatty (12)
- join (12)
-
keep
_ if (36) - key (12)
- key? (24)
- keys (12)
- label (12)
- last (24)
-
last
_ column (7) -
last
_ lineno (7) - lazy (24)
- length (12)
-
local
_ variable _ defined? (12) -
local
_ variable _ get (12) -
local
_ variable _ set (12) -
local
_ variables (11) - map (36)
- map! (24)
-
marshal
_ dump (12) -
marshal
_ load (12) - match? (9)
- max (84)
-
max
_ by (48) - mday (12)
- member? (12)
- members (15)
- merge (12)
- merge! (12)
-
method
_ id (12) - methods (12)
- min (84)
-
min
_ by (48) - minmax (12)
-
minmax
_ by (24) -
module
_ function (24) - monday? (12)
- name (29)
-
named
_ captures (12) - names (12)
-
next
_ values (12) - none? (21)
- one? (21)
-
original
_ name (24) - pack (21)
- parameters (24)
- path (12)
-
peek
_ values (12) - permutation (24)
- pop (24)
- prepend (20)
-
primitive
_ convert (48) -
primitive
_ errinfo (12) - priority (12)
- priority= (12)
- private (36)
-
private
_ instance _ methods (12) - product (24)
- public (36)
- push (12)
- putback (12)
- rassoc (24)
- readbyte (24)
- reduce (24)
- reject (48)
- reject! (36)
-
repeated
_ combination (24) -
repeated
_ permutation (24) - replace (12)
-
respond
_ to _ missing? (12) - reverse (12)
- reverse! (12)
-
reverse
_ each (24) - rindex (36)
- rotate (12)
- rotate! (12)
-
ruby2
_ keywords (18) - sample (48)
- saturday? (12)
- scrub (12)
- scrub! (12)
- select (48)
- select! (36)
-
set
_ encoding _ by _ bom (6) - setbyte (12)
- shift (24)
- shuffle (24)
- shuffle! (24)
-
singleton
_ methods (12) - size (36)
- slice (44)
- slice! (36)
-
slice
_ after (22) -
slice
_ before (36) -
slice
_ when (11) - sort (24)
- sort! (24)
-
sort
_ by (24) -
sort
_ by! (24) -
start
_ with? (6) - step (62)
- sticky? (12)
- store (12)
- strftime (12)
- sum (18)
- sunday? (12)
- symlink? (12)
- sync (12)
- synchronize (12)
- syswrite (12)
- take (36)
-
take
_ while (60) - tally (10)
-
thread
_ variable _ set (12) - thursday? (12)
-
to
_ a (82) -
to
_ ary (24) -
to
_ binary (10) -
to
_ enum (24) -
to
_ h (26) -
to
_ proc (18) -
to
_ s (24) -
to
_ sym (12) -
transform
_ keys (20) -
transform
_ keys! (20) - transpose (12)
-
try
_ lock (12) - tty? (12)
- tuesday? (12)
- type (7)
- union (7)
- uniq (48)
- uniq! (24)
- unpack (12)
- unshift (12)
- update (12)
-
values
_ at (24) - wday (12)
- wednesday? (12)
-
with
_ index (36) -
with
_ object (24) - yday (12)
- year (12)
- yield (24)
-
yield
_ self (16) - zip (48)
- | (12)
検索結果
先頭5件
-
Module
# ruby2 _ keywords(method _ name , . . . ) -> nil (18365.0) -
For the given method names, marks the method as passing keywords through a normal argument splat. This should only be called on methods that accept an argument splat (`*args`) but not explicit keywords or a keyword splat. It marks the method such that if the method is called with keyword arguments, the final hash argument is marked with a special flag such that if it is the final element of a normal argument splat to another method call, and that method call does not include explicit keywords or a keyword splat, the final element is interpreted as keywords. In other words, keywords will be passed through the method to other methods.
...ames, marks the method as passing keywords through
a normal argument splat. This should only be called on methods that
accept an argument splat (`*args`) but not explicit keywords or a
keyword splat. It marks the method such that if the method is called
with keyword arguments, the final hash argum......explicit
keywords or a keyword splat, the final element is interpreted as
keywords. In other words, keywords will be passed through the method to
other methods.
This should only be used for methods that delegate keywords to another
method, and only for backwards compatibility with Ruby versions be......fore
2.7.
This method will probably be removed at some point, as it exists only
for backwards compatibility. As it does not exist in Ruby versions
before 2.7, check that the module responds to this method before calling
it. Also, be aware that if this method is removed, the behavior of the
method w... -
Proc
# ruby2 _ keywords -> proc (18365.0) -
Marks the proc as passing keywords through a normal argument splat. This should only be called on procs that accept an argument splat (`*args`) but not explicit keywords or a keyword splat. It marks the proc such that if the proc is called with keyword arguments, the final hash argument is marked with a special flag such that if it is the final element of a normal argument splat to another method call, and that method call does not include explicit keywords or a keyword splat, the final element is interpreted as keywords. In other words, keywords will be passed through the proc to other methods.
...Marks the proc as passing keywords through a normal argument splat. This
should only be called on procs that accept an argument splat (`*args`)
but not explicit keywords or a keyword splat. It marks the proc such
that if the proc is called with keyword arguments, the final hash
argument is marked......de explicit keywords or a keyword splat, the
final element is interpreted as keywords. In other words, keywords will
be passed through the proc to other methods.
This should only be used for procs that delegate keywords to another
method, and only for backwards compatibility with Ruby versions bef......ore
2.7.
This method will probably be removed at some point, as it exists only
for backwards compatibility. As it does not exist in Ruby versions
before 2.7, check that the proc responds to this method before calling
it. Also, be aware that if this method is removed, the behavior of the
proc will c... -
RubyVM
:: InstructionSequence # to _ binary(extra _ data = nil) -> String (12133.0) -
バイナリフォーマットでシリアライズされたiseqのデータを文字列として返します。 RubyVM::InstructionSequence.load_from_binary メソッドでバイナリデータに対応するiseqオブジェクトを作れます。
...して返します。
RubyVM::InstructionSequence.load_from_binary メソッドでバイナリデータに対応するiseqオブジェクトを作れます。
引数の extra_data はバイナリデータと共に保存されます。
RubyVM::InstructionSequence.load_from_binary_extra_data メソ......inary で得たバイナリデータは他のマシンに移動できません。他のバージョンや他のアーキテクチャのRubyで作られたバイナリデータは使用できません。
//emlist[例][ruby]{
iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
iseq.to_binary("e......xtra_data")
# ※表示の都合上改行しているが実際は改行はない
# => "YARB\x02\x00\x00\x00\x03\x00\x00\x00\x16\x02\x00\x00\n\x00\x00\x00\x01
# \x00\x00\x00\x03\x00\x00\x00\x05\x00\x00\x00\x84\x01\x00\x00\x88\x01\x00
# \x00\x02\x02\x00\x00x86_64-darwin15\x00*\x00\x00\x00\x00\x00\x00... -
RubyVM
:: AbstractSyntaxTree :: Node # type -> Symbol (12115.0) -
self の種類を Symbol で返します。
...self の種類を Symbol で返します。
//emlist[][ruby]{
node = RubyVM::AbstractSyntaxTree.parse('1 + 1')
p node.type # => :SCOPE
//}... -
Enumerator
:: Yielder # yield(*object) -> () (9139.0) -
Enumerator.new で使うメソッドです。
...Yielder オブジェクトが渡されたブロックが実行され、
ブロック内の yield メソッドが呼ばれるたびに each に渡された
ブロックが yield メソッドに渡された値とともに繰り返されます。
//emlist[例][ruby]{
enum = Enumerator.new do |y|
y.y......ield 1, 2, 3
end
enum.each do |x, y, z|
p [x, y, z]
end
# => [1, 2, 3]
//}... -
RubyVM
:: InstructionSequence # to _ a -> Array (9127.0) -
self の情報を 14 要素の配列にして返します。
...ォーマットを示す文字列。常に
"YARVInstructionSequence/SimpleDataFormat"。
: major_version
命令シーケンスのメジャーバージョン。
: minor_version
命令シーケンスのマイナーバージョン。
: format_type
データフォーマットを示す数......取る引数の総数(1 つもない場合は 0)。
:local_size: ローカル変数の総数 + 1。
:stack_max: スタックの深さ。(SystemStackError を検出するために使用)
: #label
メソッド名、クラス名、モジュール名などで構成される命令シーケ......ンスの 1 行目の行番号。
: type
命令シーケンスの種別。
:top、:method、:block、:class、:rescue、:ensure、:eval、:main、
:defined_guard のいずれか。
: locals
全ての引数名、ローカル変数名からなる Symbol の配列。
: args
引数の指... -
Encoding
:: InvalidByteSequenceError # error _ bytes -> String (9115.0) -
エラー発生時に捨てられたバイト列を返します。
...][ruby]{
ec = Encoding::Converter.new("EUC-JP", "ISO-8859-1")
begin
ec.convert("abc\xA1\xFFdef")
rescue Encoding::InvalidByteSequenceError
p $!
#=> #<Encoding::InvalidByteSequenceError: "\xA1" followed by "\xFF" on EUC-JP>
puts $!.error_bytes.dump #=> "\xA1"
puts $!.readagain_byte......s.dump #=> "\xFF"
end
//}
@see Encoding::InvalidByteSequenceError#readagain_bytes... -
RubyVM
:: AbstractSyntaxTree :: Node # children -> Array (9115.0) -
self の子ノードを配列で返します。
...そのノードの type によって異なります。
戻り値は、ほかの RubyVM::AbstractSyntaxTree::Node のインスタンスや nil を含みます。
//emlist[][ruby]{
node = RubyVM::AbstractSyntaxTree.parse('1 + 2')
p node.children
# => [[], nil, #<RubyVM::AbstractSyntaxTree::Node:OPCA... -
RubyVM
:: AbstractSyntaxTree :: Node # first _ column -> Integer (9015.0) -
ソースコード中で、self を表すテキストが最初に現れる列番号を返します。
...ソースコード中で、self を表すテキストが最初に現れる列番号を返します。
列番号は0-originで、バイト単位で表されます。
//emlist[][ruby]{
node = RubyVM::AbstractSyntaxTree.parse('1 + 2')
p node.first_column # => 0
//}... -
RubyVM
:: AbstractSyntaxTree :: Node # first _ lineno -> Integer (9015.0) -
ソースコード中で、self を表すテキストが最初に現れる行番号を返します。
...ソースコード中で、self を表すテキストが最初に現れる行番号を返します。
行番号は1-originです。
//emlist[][ruby]{
node = RubyVM::AbstractSyntaxTree.parse('1 + 2')
p node.first_lineno # => 1
//}... -
RubyVM
:: AbstractSyntaxTree :: Node # inspect -> String (9015.0) -
self のデバッグ用の情報を含んだ文字列を返します。
...self のデバッグ用の情報を含んだ文字列を返します。
//emlist[][ruby]{
node = RubyVM::AbstractSyntaxTree.parse('1 + 1')
puts node.inspect
# => #<RubyVM::AbstractSyntaxTree::Node:SCOPE@1:0-1:5>
//}... -
RubyVM
:: AbstractSyntaxTree :: Node # last _ column -> Integer (9015.0) -
ソースコード中で、self を表すテキストが最後に現れる列番号を返します。
...ソースコード中で、self を表すテキストが最後に現れる列番号を返します。
列番号は0-originで、バイト単位で表されます。
//emlist[][ruby]{
node = RubyVM::AbstractSyntaxTree.parse('1 + 1')
p node.last_column # => 5
//}...