るりまサーチ (Ruby 3.3)

最速Rubyリファレンスマニュアル検索!
164件ヒット [1-100件を表示] (0.147秒)
トップページ > クエリ:i[x] > クエリ:A[x] > クエリ:with[x] > バージョン:3.3[x]

別のキーワード

  1. _builtin to_i
  2. fiddle to_i
  3. matrix elements_to_i
  4. csv to_i
  5. matrix i

モジュール

キーワード

検索結果

<< 1 2 > >>

Data#with(**kwargs) -> Data (81940.0)

self をコピーしたオブジェクトを返します。

self をコピーしたオブジェクトを返します。

値オブジェクトのメンバのオブジェクトはコピーされません。つまり参照しているオブジェクトが変わらない「浅い(shallow)」コピーを行います。

キーワード引数が指定された場合、引数に対応するメンバには引数の値が設定されます。存在しないメンバを指定した場合はエラーとなります。

@param kwargs コピーされたオブジェクトに設定されるメンバの値を指定します。

@raise ArgumentError 存在しないメンバを指定した場合に発生します。

//emlist[例][ruby]{
Dog = Data.define(:name,...

Prime::PseudoPrimeGenerator#each_with_index -> Enumerator (63949.0)

与えられたブロックに対して、素数を0起点の連番を渡して評価します。

与えられたブロックに対して、素数を0起点の連番を渡して評価します。

@return ブロックを与えられた場合は self を返します。 ブロックを与えられなかった場合は Enumerator を返します。

//emlist[例][ruby]{
require 'prime'
Prime::EratosthenesGenerator.new(10).each_with_index do |prime, index|
p [prime, index]
end
# [2, 0]
# [3, 1]
# [5, 2]
# [7, 3]
//}

@see Enumerator#with_ind...

Prime::PseudoPrimeGenerator#each_with_index {|prime, index| ... } -> self (63949.0)

与えられたブロックに対して、素数を0起点の連番を渡して評価します。

与えられたブロックに対して、素数を0起点の連番を渡して評価します。

@return ブロックを与えられた場合は self を返します。 ブロックを与えられなかった場合は Enumerator を返します。

//emlist[例][ruby]{
require 'prime'
Prime::EratosthenesGenerator.new(10).each_with_index do |prime, index|
p [prime, index]
end
# [2, 0]
# [3, 1]
# [5, 2]
# [7, 3]
//}

@see Enumerator#with_ind...

st_table * st_init_table_with_size(struct st_hash_type *type, int size) (55549.0)

st_table を作成する。_with_size はサイズを指定して生成する。 struct st_hash_type はハッシュ値を得る関数と、同値判定を行う 関数を持つ。

st_table を作成する。_with_size はサイズを指定して生成する。
struct st_hash_type はハッシュ値を得る関数と、同値判定を行う
関数を持つ。

Gem::SourceInfoCache.search_with_source(*args) -> Array (55540.0)

与えられた条件を満たす Gem::Specification と URL のリストを返します。

与えられた条件を満たす Gem::Specification と URL のリストを返します。

@param args 検索条件を指定します。Gem::SourceInfoCache#search_with_source と引数を合わせてください。

@see Gem::SourceInfoCache#search_with_source

絞り込み条件を変える

st_table * st_init_numtable_with_size(int size) (55501.0)

キーが int 型であるハッシュテーブルを作成する。 st_init_table() に int 用の操作関数を渡しているだけ。

キーが int 型であるハッシュテーブルを作成する。
st_init_table() に int 用の操作関数を渡しているだけ。

st_table * st_init_strtable_with_size(int size) (55501.0)

キーが char* 型であるハッシュテーブルを作成する。 st_init_table に文字列用の操作関数を渡しているだけ。

キーが char* 型であるハッシュテーブルを作成する。
st_init_table に文字列用の操作関数を渡しているだけ。

Enumerable#each_with_index(*args) {|item, index| ... } -> self (55333.0)

要素とそのインデックスをブロックに渡して繰り返します。

要素とそのインデックスをブロックに渡して繰り返します。

ブロックを省略した場合は、
要素とそのインデックスを繰り返すような
Enumerator を返します。

Enumerator#with_index は offset 引数を受け取りますが、
each_with_index は受け取りません (引数はイテレータメソッドにそのまま渡されます)。

@param args イテレータメソッド (each など) にそのまま渡されます。

//emlist[例][ruby]{
[5, 10, 15].each_with_index do |n, idx|
p [n, idx]
end
#...

Rake::TaskArguments#with_defaults(defaults) -> Hash (55222.0)

パラメータにデフォルト値をセットします。

パラメータにデフォルト値をセットします。

@param defaults デフォルト値として使用するキーと値を格納したハッシュを指定します。

//emlist[][ruby]{
# Rakefile での記載例とする

task default: :test_rake_app
task :test_rake_app do
arguments = Rake::TaskArguments.new(["name1", "name2"], ["value1", "value2"])
arguments.to_hash ...

ERB#result_with_hash(hash) -> String (55204.0)

ERB をハッシュオブジェクトで指定されたローカル変数を持つ 新しいトップレベルバインディングで実行し、結果の文字列を返します。

ERB をハッシュオブジェクトで指定されたローカル変数を持つ
新しいトップレベルバインディングで実行し、結果の文字列を返します。

@param hash ローカル変数名をキーにしたハッシュ

@see ERB#result

絞り込み条件を変える

Gem::SourceInfoCache#search_with_source(pattern, only_platform = false, all = false) -> Array (55204.0)

与えられた条件を満たす Gem::Specification と URL のリストを返します。

与えられた条件を満たす Gem::Specification と URL のリストを返します。

@param pattern 検索したい Gem を表す Gem::Dependency のインスタンスを指定します。

@param only_platform 真を指定するとプラットフォームが一致するもののみを返します。デフォルトは偽です。

@param all 真を指定するとキャッシュを更新してから検索を実行します。

@return 第一要素を Gem::Specification、第二要素を取得元の URL とする配列を要素とする配列を返します。

WIN32OLE_EVENT#on_event_with_outargs(event = nil) {|*args| ... } -> () (55204.0)

イベント通知を受けて結果を呼び出し元へ返すブロックを登録します。

イベント通知を受けて結果を呼び出し元へ返すブロックを登録します。

引数にはイベントのメソッド名を指定します。引数を省略した場合は、すべて
のイベントを対象とするブロックの登録となります。

WIN32OLE_EVENT#on_eventと異なり、イベントのブロック変数に戻り値を
設定できます。

@param event イベント名を文字列かシンボルで指定します。イベント名は大文
字小文字を区別します。省略時にはすべてのイベントが対象となります。

@param args サーバがイベント通知時に指定した引数の配列です。
eventパラメータ...

VALUE rb_with_disable_interrupt(VALUE (*proc)(), data) (55201.0)

Symbol#start_with?(*prefixes) -> bool (55048.0)

self の先頭が prefixes のいずれかであるとき true を返します。

self の先頭が prefixes のいずれかであるとき true を返します。

(self.to_s.start_with?と同じです。)

@param prefixes パターンを表す文字列または正規表現 (のリスト)

@see Symbol#end_with?

@see String#start_with?

//emlist[][ruby]{
:hello.start_with?("hell") #=> true
:hello.start_with?(/H/i) #=> true

# returns true i...

Enumerable#each_with_index(*args) -> Enumerator (55033.0)

要素とそのインデックスをブロックに渡して繰り返します。

要素とそのインデックスをブロックに渡して繰り返します。

ブロックを省略した場合は、
要素とそのインデックスを繰り返すような
Enumerator を返します。

Enumerator#with_index は offset 引数を受け取りますが、
each_with_index は受け取りません (引数はイテレータメソッドにそのまま渡されます)。

@param args イテレータメソッド (each など) にそのまま渡されます。

//emlist[例][ruby]{
[5, 10, 15].each_with_index do |n, idx|
p [n, idx]
end
#...

絞り込み条件を変える

Enumerable#each_with_object(obj) -> Enumerator (55015.0)

与えられた任意のオブジェクトと要素をブロックに渡し繰り返し、最初に与えられたオブジェクトを返します。

与えられた任意のオブジェクトと要素をブロックに渡し繰り返し、最初に与えられたオブジェクトを返します。

ブロックを省略した場合は Enumerator を返します。

@param obj 任意のオブジェクトを指定します。

//emlist[例][ruby]{
evens = (1..10).each_with_object([]) {|i, a| a << i*2 }
# => [2, 4, 6, 8, 10, 12, 14, 16, 18, 20]
//}

@see Enumerator#with_object

Enumerable#each_with_object(obj) {|(*args), memo_obj| ... } -> object (55015.0)

与えられた任意のオブジェクトと要素をブロックに渡し繰り返し、最初に与えられたオブジェクトを返します。

与えられた任意のオブジェクトと要素をブロックに渡し繰り返し、最初に与えられたオブジェクトを返します。

ブロックを省略した場合は Enumerator を返します。

@param obj 任意のオブジェクトを指定します。

//emlist[例][ruby]{
evens = (1..10).each_with_object([]) {|i, a| a << i*2 }
# => [2, 4, 6, 8, 10, 12, 14, 16, 18, 20]
//}

@see Enumerator#with_object

REXML::Element#each_element_with_attribute(key, value = nil, max = 0, name = nil) {|element| ... } -> () (55012.0)

特定の属性を持つすべての子要素を引数としてブロックを呼び出します。

特定の属性を持つすべての子要素を引数としてブロックを呼び出します。

key で指定した属性名の属性を持つ要素のみを対象とします。
value を指定すると、keyで指定した属性名を持つ属性の値がvalueである
もののみを対象とします。
maxを指定すると、対象となる子要素の先頭 max 個のみが対象となります。
name を指定すると、それは xpath 文字列と見なされ、
それにマッチするもののみが対象となります。

max に 0 を指定すると、max の指定は無視されます(0個ではありません)。

@param key 属性名(文字列)
@param value 属性値(文字列)
...

REXML::Element#each_element_with_text(text = nil, max = 0, name = nil) {|element| ... } -> () (55012.0)

テキストを子ノードとして 持つすべての子要素を引数としてブロックを呼び出します。

テキストを子ノードとして
持つすべての子要素を引数としてブロックを呼び出します。

text を指定すると、テキストの内容が text であるもののみを対象とします。
maxを指定すると、対象となる子要素の先頭 max 個のみが対象となります。
name を指定すると、それは xpath 文字列と見なされ、
それにマッチするもののみが対象となります。

max に 0 を指定すると、max の指定は無視されます(0個ではありません)。

@param text テキストの中身(文字列)
@param max ブロック呼出の対象とする子要素の最大個数
@param name xpath文字列

...

String#start_with?(*prefixes) -> bool (55012.0)

self の先頭が prefixes のいずれかであるとき true を返します。

self の先頭が prefixes のいずれかであるとき true を返します。

@param prefixes パターンを表す文字列または正規表現 (のリスト)

//emlist[例][ruby]{
"string".start_with?("str") # => true
"string".start_with?("ing") # => false
"string".start_with?("ing", "str") # => true
"string".start_with?(/\w/) # => true
"strin...

絞り込み条件を変える

Prime::PseudoPrimeGenerator#with_index -> Enumerator (54949.0)

与えられたブロックに対して、素数を0起点の連番を渡して評価します。

与えられたブロックに対して、素数を0起点の連番を渡して評価します。

@return ブロックを与えられた場合は self を返します。 ブロックを与えられなかった場合は Enumerator を返します。

//emlist[例][ruby]{
require 'prime'
Prime::EratosthenesGenerator.new(10).each_with_index do |prime, index|
p [prime, index]
end
# [2, 0]
# [3, 1]
# [5, 2]
# [7, 3]
//}

@see Enumerator#with_ind...

Matrix#each_with_index(which = :all) -> Enumerator (54925.0)

行列の各要素をその位置とともに引数としてブロックを呼び出します。

行列の各要素をその位置とともに引数としてブロックを呼び出します。

which で処理する要素の範囲を指定することができます。
Matrix#each と同じなのでそちらを参照してください。

ブロックを省略した場合、 Enumerator を返します。

//emlist[例][ruby]{
require 'matrix'
Matrix[ [1,2], [3,4] ].each_with_index do |e, row, col|
puts "#{e} at #{row}, #{col}"
end
# => 1 at 0, 0
# => 2 at 0, 1
# => 3...

Matrix#each_with_index(which = :all) {|e, row, col| ... } -> self (54925.0)

行列の各要素をその位置とともに引数としてブロックを呼び出します。

行列の各要素をその位置とともに引数としてブロックを呼び出します。

which で処理する要素の範囲を指定することができます。
Matrix#each と同じなのでそちらを参照してください。

ブロックを省略した場合、 Enumerator を返します。

//emlist[例][ruby]{
require 'matrix'
Matrix[ [1,2], [3,4] ].each_with_index do |e, row, col|
puts "#{e} at #{row}, #{col}"
end
# => 1 at 0, 0
# => 2 at 0, 1
# => 3...

Prime::PseudoPrimeGenerator#with_object(obj) -> Enumerator (54925.0)

与えられた任意のオブジェクトと要素をブロックに渡して評価します。

与えられた任意のオブジェクトと要素をブロックに渡して評価します。

@param obj 任意のオブジェクトを指定します。
@return 最初に与えられたオブジェクトを返します。
@return ブロックを与えられた場合は obj を返します。ブロックを与えられなかった場合は Enumerator を返します。

@see Enumerator#with_object

Vector#angle_with(v) -> Float (54922.0)

v と self がなす角度を返します。

v と self がなす角度を返します。

//emlist[例][ruby]{
require 'matrix'
Vector[1, 0].angle_with(Vector[0, 1]) # => Math::PI/2
//}

@param v このベクトルと self とがなす角度を計算します
@raise ZeroVectorError self もしくは v のどちらかが零ベクトルである場合に
発生します
@raise ExceptionForMatrix::ErrDimensionMismatch v と self の
ベクトルの次元が異なる場合に発...

絞り込み条件を変える

Gem::DependencyInstaller#find_gems_with_sources(dep) -> Array (54904.0)

与えられた条件にマッチする Gem::Specification のインスタンスと URI のペアのリストを 返します。

与えられた条件にマッチする Gem::Specification のインスタンスと URI のペアのリストを
返します。

Gem はローカル (Dir.pwd) とリモート (Gem.sources) の両方から検索します。
結果は、バージョンの新しい順が先にきます。また、ローカルの Gem も先にきます。

@param dep Gem::Dependency のインスタンスを指定します。

REXML::Child#replace_with(child) -> self (54904.0)

親ノードの子ノード列上において、 self を child に置き換えます。

親ノードの子ノード列上において、 self を child に置き換えます。

@param child 置き換え後のノード
@see REXML::Parent#replace_child

Rake::TaskManager#enhance_with_matching_rule(task_name, level = 0) -> Rake::Task | nil (54904.0)

与えられたタスク名にマッチしたルールが存在する場合は、そのタスクに見つかったルールの 事前タスクとアクションを追加して返します。

与えられたタスク名にマッチしたルールが存在する場合は、そのタスクに見つかったルールの
事前タスクとアクションを追加して返します。

@param task_name タスクの名前を指定します。

@param level 現在のルール解決のネストの深さを指定します。

@raise RuntimeError ルールの解決時にオーバーフローした場合に発生します。

Prime::PseudoPrimeGenerator#with_index {|prime, index| ... } -> self (54649.0)

与えられたブロックに対して、素数を0起点の連番を渡して評価します。

与えられたブロックに対して、素数を0起点の連番を渡して評価します。

@return ブロックを与えられた場合は self を返します。 ブロックを与えられなかった場合は Enumerator を返します。

//emlist[例][ruby]{
require 'prime'
Prime::EratosthenesGenerator.new(10).each_with_index do |prime, index|
p [prime, index]
end
# [2, 0]
# [3, 1]
# [5, 2]
# [7, 3]
//}

@see Enumerator#with_ind...

Prime::PseudoPrimeGenerator#with_object(obj) {|prime, obj| ... } -> object (54625.0)

与えられた任意のオブジェクトと要素をブロックに渡して評価します。

与えられた任意のオブジェクトと要素をブロックに渡して評価します。

@param obj 任意のオブジェクトを指定します。
@return 最初に与えられたオブジェクトを返します。
@return ブロックを与えられた場合は obj を返します。ブロックを与えられなかった場合は Enumerator を返します。

@see Enumerator#with_object

絞り込み条件を変える

rubygems/commands/generate_index_command (54091.0)

ある Gem サーバに対するインデックスを作成するためのライブラリです。

ある Gem サーバに対するインデックスを作成するためのライブラリです。

Usage: gem generate_index [options]
Options:
-d, --directory=DIRNAME repository base dir containing gems subdir
Common Options:
-h, --help このコマンドのヘルプを表示します
-V, --[no-]verbose 表示を詳細にします
...

rubygems/commands/pristine_command (54019.0)

インストールされている Gem パッケージを初期状態にするためのライブラリです。

インストールされている Gem パッケージを初期状態にするためのライブラリです。

Usage: gem pristine [args] [options]
Options:
--all インストールされている全ての Gem パッケージを
初期状態に戻します
-v, --version VERSION 指定したバージョンの Gem パッケージを
...

Enumerator#with_index(offset = 0) -> Enumerator (46015.0)

生成時のパラメータに従って、要素にインデックスを添えて繰り返します。 インデックスは offset から始まります。

生成時のパラメータに従って、要素にインデックスを添えて繰り返します。
インデックスは offset から始まります。

ブロックを指定した場合の戻り値は生成時に指定したレシーバ自身です。

//emlist[例][ruby]{
str = "xyz"

enum = Enumerator.new {|y| str.each_byte {|b| y << b }}
enum.with_index {|byte, idx| p [byte, idx] }
# => [120, 0]
# [121, 1]
# [122, 2]

require "stringi...

Enumerator#with_index(offset = 0) {|(*args), idx| ... } -> object (46015.0)

生成時のパラメータに従って、要素にインデックスを添えて繰り返します。 インデックスは offset から始まります。

生成時のパラメータに従って、要素にインデックスを添えて繰り返します。
インデックスは offset から始まります。

ブロックを指定した場合の戻り値は生成時に指定したレシーバ自身です。

//emlist[例][ruby]{
str = "xyz"

enum = Enumerator.new {|y| str.each_byte {|b| y << b }}
enum.with_index {|byte, idx| p [byte, idx] }
# => [120, 0]
# [121, 1]
# [122, 2]

require "stringi...

Enumerator#with_object(obj) -> Enumerator (45979.0)

繰り返しの各要素に obj を添えてブロックを繰り返し、obj を返り値として返します。

繰り返しの各要素に obj を添えてブロックを繰り返し、obj を返り値として返します。

obj には任意のオブジェクトを渡すことができます。

ブロックが渡されなかった場合は、上で説明した繰り返しを実行し、
最後に obj を返す Enumerator を返します。

//emlist[例][ruby]{
# 0,1,2 と呼びだす enumeratorを作る
to_three = Enumerator.new do |y|
3.times do |x|
y << x
end
end

to_three_with_string = to_three.with_object...

絞り込み条件を変える

Enumerator#with_object(obj) {|(*args), memo_obj| ... } -> object (45979.0)

繰り返しの各要素に obj を添えてブロックを繰り返し、obj を返り値として返します。

繰り返しの各要素に obj を添えてブロックを繰り返し、obj を返り値として返します。

obj には任意のオブジェクトを渡すことができます。

ブロックが渡されなかった場合は、上で説明した繰り返しを実行し、
最後に obj を返す Enumerator を返します。

//emlist[例][ruby]{
# 0,1,2 と呼びだす enumeratorを作る
to_three = Enumerator.new do |y|
3.times do |x|
y << x
end
end

to_three_with_string = to_three.with_object...

Enumerator::Lazy#with_index(offset = 0) -> Enumerator::Lazy (45979.0)

生成時のパラメータに従って、要素にインデックスを添えて繰り返します。 インデックスは offset から始まります。

生成時のパラメータに従って、要素にインデックスを添えて繰り返します。
インデックスは offset から始まります。

ブロックを指定した場合の戻り値は生成時に指定したレシーバ自身です。

//emlist[][ruby]{
("a"..).lazy.with_index(1) { |it, index| puts "#{index}:#{it}" }.take(3).force
# => 1:a
# 2:b
# 3:c
//}

@see Enumerator#with_index

Enumerator::Lazy#with_index(offset = 0) {|(*args), idx| ... } -> Enumerator::Lazy (45979.0)

生成時のパラメータに従って、要素にインデックスを添えて繰り返します。 インデックスは offset から始まります。

生成時のパラメータに従って、要素にインデックスを添えて繰り返します。
インデックスは offset から始まります。

ブロックを指定した場合の戻り値は生成時に指定したレシーバ自身です。

//emlist[][ruby]{
("a"..).lazy.with_index(1) { |it, index| puts "#{index}:#{it}" }.take(3).force
# => 1:a
# 2:b
# 3:c
//}

@see Enumerator#with_index

Socket::Constants::IP_PORTRANGE -> Integer (45649.0)

Set the port range for sockets with unspecified port numbers。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Set the port range for sockets with unspecified port numbers。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP, ip(4freebsd)

void rb_compile_error_with_enc(const char *file, int line, void *enc, const char *fmt, ...) (37501.0)

この関数は Ruby 2.3.0 から deprecated です。公開関数ですが内部利用のみを想 定しています。外部のライブラリで使用すべきではありません。

この関数は Ruby 2.3.0 から deprecated です。公開関数ですが内部利用のみを想
定しています。外部のライブラリで使用すべきではありません。

絞り込み条件を変える

Kernel#with_config(config, default = nil) {|config, default| ... } -> bool | String (37243.0)

configure のオプションを検査します。

configure のオプションを検査します。

configure のオプションに --with-<config> が指定された場合は真を返しま
す。--without-<config> が指定された場合は偽を返します。どちらでもない場
合は default を返します。

これはデバッグ情報などのカスタム定義を、追加するのに役立ちます。

@param config configure のオプションの名前を指定します。

@param default デフォルト値を返します。


require 'mkmf'
if with_config("debug")
$defs...

Pathname#each_child(with_directory = true) -> Enumerator (36973.0)

self.children(with_directory).each と同じです。

self.children(with_directory).each と同じです。

@param with_directory 偽を指定するとファイル名のみ返します。デフォルトは真です。

//emlist[例][ruby]{
require "pathname"

Pathname("/usr/local").each_child {|f| p f }
# => #<Pathname:/usr/local/bin>
# => #<Pathname:/usr/local/etc>
# => #<Pathname:/usr/local/include>
# => #<Pathname:/us...

Pathname#each_child(with_directory = true) {|pathname| ...} -> [Pathname] (36973.0)

self.children(with_directory).each と同じです。

self.children(with_directory).each と同じです。

@param with_directory 偽を指定するとファイル名のみ返します。デフォルトは真です。

//emlist[例][ruby]{
require "pathname"

Pathname("/usr/local").each_child {|f| p f }
# => #<Pathname:/usr/local/bin>
# => #<Pathname:/usr/local/etc>
# => #<Pathname:/usr/local/include>
# => #<Pathname:/us...

Kernel#with_config(config, default = nil) -> bool | String (36943.0)

configure のオプションを検査します。

configure のオプションを検査します。

configure のオプションに --with-<config> が指定された場合は真を返しま
す。--without-<config> が指定された場合は偽を返します。どちらでもない場
合は default を返します。

これはデバッグ情報などのカスタム定義を、追加するのに役立ちます。

@param config configure のオプションの名前を指定します。

@param default デフォルト値を返します。


require 'mkmf'
if with_config("debug")
$defs...

IRB::Inspector.keys_with_inspector(inspector) -> Array (36922.0)

引数で指定した IRB::Inspector に対応する key の配列を返します。

引数で指定した IRB::Inspector に対応する key の配列を返します。

@param inspector IRB::Inspector オブジェクトを指定します。

IRB::Inspector.keys_with_inspector(IRB::Inspector::INSPECTORS[true])
# => [true, :p, "p", :inspect, "inspect"]

絞り込み条件を変える

Socket::AI_PASSIVE -> Integer (36649.0)

Get address to use with bind。

Get address to use with bind。

Socket.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getaddrinfo(3)

Socket::Constants::AI_PASSIVE -> Integer (36649.0)

Get address to use with bind。

Get address to use with bind。

Socket.getaddrinfo, Addrinfo.getaddrinfo の引数 flags に渡す
定数です。

@see getaddrinfo(3)

Socket::Constants::EAI_NODATA -> Integer (36649.0)

No address associated with hostname

No address associated with hostname

getaddrinfo(3), getnameinfo(3) などの
エラーコードです。
対応する Socket.getaddrinfo, Addrinfo.getaddrinfo などは
エラーを SocketError に変換するため、この定数は直接は利用しません。

@see getaddrinfo(3linux)

Socket::Constants::IFF_DYNAMIC (36649.0)

dialup device with changing addresses

dialup device with changing addresses

Socket::Constants::IPV6_RECVPATHMTU -> Integer (36649.0)

Receive current path MTU with datagram。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive current path MTU with datagram。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IPV6,
3542

絞り込み条件を変える

Socket::Constants::IP_PASSSEC -> Integer (36649.0)

@todo Retrieve security context with datagram。

@todo
Retrieve security context with datagram。

Socket::Constants::IP_RECVDSTADDR -> Integer (36649.0)

Receive IP destination address with datagram。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive IP destination address with datagram。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP,
ip(4freebsd)

Socket::Constants::IP_RECVSLLA -> Integer (36649.0)

@todo Receive link-layer address with datagrams

@todo
Receive link-layer address with datagrams

Socket::Constants::SO_TIMESTAMP -> Integer (36649.0)

Receive timestamp with datagrams (timeval)。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive timestamp with datagrams (timeval)。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see getsockopt(2freebsd),
socket(7linux), Socket::Constants::SOL_SOCKET
Socket::AncillaryData#timestamp

Socket::Constants::SO_TIMESTAMPNS -> Integer (36649.0)

@todo Receive nanosecond timestamp with datagrams (timespec)。

@todo
Receive nanosecond timestamp with datagrams (timespec)。

@see Socket::Constants::SO_TIMESTAMP,
Socket::AncillaryData#timestamp

絞り込み条件を変える

Socket::EAI_NODATA -> Integer (36649.0)

No address associated with hostname

No address associated with hostname

getaddrinfo(3), getnameinfo(3) などの
エラーコードです。
対応する Socket.getaddrinfo, Addrinfo.getaddrinfo などは
エラーを SocketError に変換するため、この定数は直接は利用しません。

@see getaddrinfo(3linux)

Socket::IFF_DYNAMIC (36649.0)

dialup device with changing addresses

dialup device with changing addresses

Socket::IPV6_RECVPATHMTU -> Integer (36649.0)

Receive current path MTU with datagram。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive current path MTU with datagram。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IPV6,
3542

Socket::IP_PASSSEC -> Integer (36649.0)

@todo Retrieve security context with datagram。

@todo
Retrieve security context with datagram。

Socket::IP_PORTRANGE -> Integer (36649.0)

Set the port range for sockets with unspecified port numbers。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Set the port range for sockets with unspecified port numbers。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP, ip(4freebsd)

絞り込み条件を変える

Socket::IP_RECVDSTADDR -> Integer (36649.0)

Receive IP destination address with datagram。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive IP destination address with datagram。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP,
ip(4freebsd)

Socket::IP_RECVSLLA -> Integer (36649.0)

@todo Receive link-layer address with datagrams

@todo
Receive link-layer address with datagrams

Socket::SO_TIMESTAMP -> Integer (36649.0)

Receive timestamp with datagrams (timeval)。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive timestamp with datagrams (timeval)。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see getsockopt(2freebsd),
socket(7linux), Socket::Constants::SOL_SOCKET
Socket::AncillaryData#timestamp

Socket::SO_TIMESTAMPNS -> Integer (36649.0)

@todo Receive nanosecond timestamp with datagrams (timespec)。

@todo
Receive nanosecond timestamp with datagrams (timespec)。

@see Socket::Constants::SO_TIMESTAMP,
Socket::AncillaryData#timestamp

rdoc/generator/json_index (36199.0)

他のジェネレータが生成する HTML で検索が行えるように、JSON の検索インデッ クスを生成するサブライブラリです。

他のジェネレータが生成する HTML で検索が行えるように、JSON の検索インデッ
クスを生成するサブライブラリです。

This generator is derived from sdoc by Vladimir Kolesnikov and
contains verbatim code written by him.

このジェネレータは HTML ジェネレータと一緒に使うために設計されています。:

class RDoc::Generator::Darkfish
def initialize options
# ...
@base_dir = Pa...

絞り込み条件を変える

did_you_mean (36055.0)

名前のタイポによって NameError や NoMethodError が起きたと きに、自動的に他の似た名前を提案してくれるライブラリです。

名前のタイポによって NameError や NoMethodError が起きたと
きに、自動的に他の似た名前を提案してくれるライブラリです。

"Yuki".starts_with?("Y")
# => NoMethodError: undefined method `starts_with?' for "Yuki":String
# Did you mean? start_with?

デフォルトで有効になっており、無効にするにはコマンドラインオプションで
--disable=did_you_mean を指定します。

このライブラリはbundled gem(gemフ...

Continuation (36019.0)

継続を表すクラスです。

継続を表すクラスです。

Kernel.#callcc { |cont| ... } の呼び出し
は、直前の状態(ローカル変数の定義、スタックフレーム)を cont に記憶
してブロックを実行します。cont は、Continuation クラスのインスタ
ンスで、Continuation#call メソッドを実行するこ
とでいつでも記憶した状態を継続することができます。

C 言語の setjmp()/longjmp() がわかる人は
setjmp() == callcc {|c| }
longjmp() == c.call
と考えれば、わかりやすいかも知れません(ただし、callc...

パターンマッチ (28333.0)

パターンマッチ * patterns * variable_binding * variable_pinning * matching_non_primitive_objects * guard_clauses * current_feature_status * pattern_syntax * some_undefined_behavior_examples

パターンマッチ
* patterns
* variable_binding
* variable_pinning
* matching_non_primitive_objects
* guard_clauses
* current_feature_status
* pattern_syntax
* some_undefined_behavior_examples

パターンマッチは、構造化された値に対して、構造をチェックし、マッチした部分をローカル変数に束縛するという、深いマッチを可能にする機能です。(『束縛』は、パターンマッチの輸入元である関数型言語の用語で...

Hash#filter! {|key, value| ... } -> self | nil (28045.0)

キーと値を引数としてブロックを評価した結果が真であるような要素を self に残します。

キーと値を引数としてブロックを評価した結果が真であるような要素を self
に残します。

keep_if は常に self を返します。
filter! と select! はオブジェクトが変更された場合に self を、
されていない場合に nil を返します。

ブロックが与えられなかった場合は、自身と keep_if から生成した
Enumerator オブジェクトを返します。

//emlist[例][ruby]{
h1 = {}
c = ("a".."g")
c.each_with_index {|e, i| h1[i] = e }

h2 = h1.dup
h1.select!...

Pathname#children(with_directory = true) -> [Pathname] (27922.0)

self 配下にあるパス名(Pathnameオブジェクト)の配列を返します。

self 配下にあるパス名(Pathnameオブジェクト)の配列を返します。

ただし、 ".", ".." は要素に含まれません。

@param with_directory 偽を指定するとファイル名のみ返します。デフォルトは真です。

@raise Errno::EXXX self が存在しないパスであったりディレクトリでなければ例外が発生します。

//emlist[例][ruby]{
require 'pathname'
Pathname.new("/tmp").children # => [#<Pathname:.X11-unix>, #<Pathname:.iroha_unix>...

絞り込み条件を変える

Time#strftime(format) -> String (27817.0)

時刻を format 文字列に従って文字列に変換した結果を返します。

時刻を format 文字列に従って文字列に変換した結果を返します。

@param format フォーマット文字列を指定します。使用できるものは 以下の通りです。

* %A: 曜日の名称(Sunday, Monday ... )
* %a: 曜日の省略名(Sun, Mon ... )
* %B: 月の名称(January, February ... )
* %b: 月の省略名(Jan, Feb ... )
* %C: 世紀 (2009年であれば 20)
* %c: 日付と時刻 (%a %b %e %T %Y)
* %D: 日付 (%m/%d/%y)
* ...

Hash#filter! -> Enumerator (27745.0)

キーと値を引数としてブロックを評価した結果が真であるような要素を self に残します。

キーと値を引数としてブロックを評価した結果が真であるような要素を self
に残します。

keep_if は常に self を返します。
filter! と select! はオブジェクトが変更された場合に self を、
されていない場合に nil を返します。

ブロックが与えられなかった場合は、自身と keep_if から生成した
Enumerator オブジェクトを返します。

//emlist[例][ruby]{
h1 = {}
c = ("a".."g")
c.each_with_index {|e, i| h1[i] = e }

h2 = h1.dup
h1.select!...

Hash#keep_if -> Enumerator (27745.0)

キーと値を引数としてブロックを評価した結果が真であるような要素を self に残します。

キーと値を引数としてブロックを評価した結果が真であるような要素を self
に残します。

keep_if は常に self を返します。
filter! と select! はオブジェクトが変更された場合に self を、
されていない場合に nil を返します。

ブロックが与えられなかった場合は、自身と keep_if から生成した
Enumerator オブジェクトを返します。

//emlist[例][ruby]{
h1 = {}
c = ("a".."g")
c.each_with_index {|e, i| h1[i] = e }

h2 = h1.dup
h1.select!...

Hash#keep_if {|key, value| ... } -> self (27745.0)

キーと値を引数としてブロックを評価した結果が真であるような要素を self に残します。

キーと値を引数としてブロックを評価した結果が真であるような要素を self
に残します。

keep_if は常に self を返します。
filter! と select! はオブジェクトが変更された場合に self を、
されていない場合に nil を返します。

ブロックが与えられなかった場合は、自身と keep_if から生成した
Enumerator オブジェクトを返します。

//emlist[例][ruby]{
h1 = {}
c = ("a".."g")
c.each_with_index {|e, i| h1[i] = e }

h2 = h1.dup
h1.select!...

Thread#report_on_exception=(newstate) (27691.0)

真の場合、そのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

真の場合、そのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

デフォルトはスレッド作成時の Thread.report_on_exception です。

@param newstate スレッド実行中に例外発生した場合、その内容を報告するかどうかを true か false で指定します。

//emlist[例][ruby]{
a = Thread.new{ Thread.stop; raise }
a.report_on_exception = true
a.report_on_exception # => true
a.run
# => #<Th...

絞り込み条件を変える

Matrix#each(which = :all) -> Enumerator (27637.0)

行列の各要素を引数としてブロックを呼び出します。

行列の各要素を引数としてブロックを呼び出します。

0行目、1行目、…という順番で処理します。
which に以下の Symbol を指定することで
引数として使われる要素を限定することができます。
* :all - すべての要素(デフォルト)
* :diagonal - 対角要素
* :off_diagonal 対角要素以外
* :lower 対角成分とそれより下側の部分
* :upper対角成分とそれより上側の部分
* :strict_lower 対角成分の下側
* :strict_upper 対角成分の上側

ブロックを省略した場合、 Enumerator ...

Matrix#each(which = :all) {|e| ... } -> self (27637.0)

行列の各要素を引数としてブロックを呼び出します。

行列の各要素を引数としてブロックを呼び出します。

0行目、1行目、…という順番で処理します。
which に以下の Symbol を指定することで
引数として使われる要素を限定することができます。
* :all - すべての要素(デフォルト)
* :diagonal - 対角要素
* :off_diagonal 対角要素以外
* :lower 対角成分とそれより下側の部分
* :upper対角成分とそれより上側の部分
* :strict_lower 対角成分の下側
* :strict_upper 対角成分の上側

ブロックを省略した場合、 Enumerator ...

Matrix.build(row_size, column_size = row_size) -> Enumerable (27637.0)

row_size×column_sizeの行列をブロックの返り値から生成します。

row_size×column_sizeの行列をブロックの返り値から生成します。

行列の各要素の位置がブロックに渡され、それの返り値が行列の要素となります。

ブロックを省略した場合は Enumerator を返します。

//emlist[例][ruby]{
require 'matrix'
m = Matrix.build(2, 4) {|row, col| col - row }
# => Matrix[[0, 1, 2, 3], [-1, 0, 1, 2]]
m = Matrix.build(3) { rand }
# => a 3x3 matrix with random...

Matrix.build(row_size, column_size = row_size) {|row, col| ... } -> Matrix (27637.0)

row_size×column_sizeの行列をブロックの返り値から生成します。

row_size×column_sizeの行列をブロックの返り値から生成します。

行列の各要素の位置がブロックに渡され、それの返り値が行列の要素となります。

ブロックを省略した場合は Enumerator を返します。

//emlist[例][ruby]{
require 'matrix'
m = Matrix.build(2, 4) {|row, col| col - row }
# => Matrix[[0, 1, 2, 3], [-1, 0, 1, 2]]
m = Matrix.build(3) { rand }
# => a 3x3 matrix with random...

Thread.report_on_exception=(newstate) (27619.0)

真の時は、いずれかのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

真の時は、いずれかのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

デフォルトは true です。

Thread.new { 1.times { raise } }

は $stderr に以下のように出力します:

#<Thread:...> terminated with exception (report_on_exception is true):
Traceback (most recent call last):
2: from -e:1:in `block in <main>'
1: fro...

絞り込み条件を変える

Socket::Constants::IP_BLOCK_SOURCE -> Integer (27397.0)

Block IPv4 multicast packets with a give source address。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Block IPv4 multicast packets with a give source address。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP,
ip(4freebsd)

Socket::Constants::IP_UNBLOCK_SOURCE -> Integer (27397.0)

Unblock IPv4 multicast packets with a give source address。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Unblock IPv4 multicast packets with a give source address。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP,
ip(4freebsd)

Thread#report_on_exception -> bool (27391.0)

真の場合、そのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

真の場合、そのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

デフォルトはスレッド作成時の Thread.report_on_exception です。

@param newstate スレッド実行中に例外発生した場合、その内容を報告するかどうかを true か false で指定します。

//emlist[例][ruby]{
a = Thread.new{ Thread.stop; raise }
a.report_on_exception = true
a.report_on_exception # => true
a.run
# => #<Th...

Socket::Constants::IPV6_PKTINFO -> Integer (27349.0)

Receive packet information with datagram。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive packet information with datagram。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IPV6,
ip6(4freebsd), ipv6(7linux),
3542

Socket::Constants::IPV6_RECVHOPLIMIT -> Integer (27349.0)

Receive hop limit with datagram。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive hop limit with datagram。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IPV6,
3542

絞り込み条件を変える

Socket::Constants::IP_HDRINCL -> Integer (27349.0)

Header is included with data。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Header is included with data。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP,
ip(4freebsd)

Socket::Constants::IP_PKTINFO -> Integer (27349.0)

Receive packet information with datagrams。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive packet information with datagrams。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP, ip(7linux)

Socket::Constants::IP_PKTOPTIONS -> Integer (27349.0)

@todo Receive packet options with datagrams

@todo
Receive packet options with datagrams

Socket::Constants::IP_RECVIF -> Integer (27349.0)

Receive interface information with datagrams。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive interface information with datagrams。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP, ip(4freebsd)

Socket::Constants::IP_RECVOPTS -> Integer (27349.0)

Receive IP destination address with datagram。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive IP destination address with datagram。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP,
ip(7linux)

絞り込み条件を変える

Socket::Constants::IP_RECVTOS -> Integer (27349.0)

Receive TOS with incoming packets。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive TOS with incoming packets。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP, ip(7linux)

Socket::Constants::IP_RECVTTL -> Integer (27349.0)

Receive IP TTL with datagrams。 BasicSocket#getsockopt, BasicSocket#setsockopt の第2引数(optname)に使用します。

Receive IP TTL with datagrams。
BasicSocket#getsockopt, BasicSocket#setsockopt
の第2引数(optname)に使用します。

@see Socket::Constants::IPPROTO_IP, ip(7linux), ip(4freebsd)

Thread.report_on_exception -> bool (27319.0)

真の時は、いずれかのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

真の時は、いずれかのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

デフォルトは true です。

Thread.new { 1.times { raise } }

は $stderr に以下のように出力します:

#<Thread:...> terminated with exception (report_on_exception is true):
Traceback (most recent call last):
2: from -e:1:in `block in <main>'
1: fro...

Rinda::TupleSpace (27037.0)

Tuple Space を表すクラスです。

Tuple Space を表すクラスです。

このクラスのインスタンスを
drb を経由して公開することで
タプルスペースを他のプロセスからアクセスさせることができるようになります。

タプルスペースを drb 経由で利用する側は
DRb::DRbObject.new_with_uri などでこのオブジェクトのリモートオブジェクトを
取得し、Rinda::TupleSpaceProxy をかぶせることで利用します。

===[a:renewer] タプルの寿命と renewer
タプルを Rinda::TupleSpace#write などで追加するときにその寿命を
秒数で指定することができ...

Marshal フォーマット (20053.0)

Marshal フォーマット フォーマットバージョン 4.8 を元に記述しています。

Marshal フォーマット
フォーマットバージョン 4.8 を元に記述しています。

=== nil, true, false

それぞれ、'0', 'T', 'F' になります。

//emlist[][ruby]{
p Marshal.dump(nil).unpack1("x2 a*") # => "0"
p Marshal.dump(true).unpack1("x2 a*") # => "T"
p Marshal.dump(false).unpack1("x2 a*") # => "F"
//}

Ruby 2.1 以前では、インスタンス変数を設定しても dump されません...

絞り込み条件を変える

Kernel#check_signedness(type, headers = nil, opts = nil) -> "signed" | "unsigned" | nil (19393.0)

Returns the signedness of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. If the +type+ is found and is a numeric type, a macro is passed as a preprocessor constant to the compiler using the +type+ name, in uppercase, prepended with 'SIGNEDNESS_OF_', followed by the +type+ name, followed by '=X' where 'X' is positive integer if the +type+ is unsigned, or negative integer if the +type+ is signed. For example, if size_t is defined as unsigned, then check_signedness('size_t') would returned +1 and the SIGNEDNESS_OF_SIZE_T=+1 preprocessor macro would be passed to the compiler, and SIGNEDNESS_OF_INT=-1 if check_signedness('int') is done.

Returns the signedness of the given +type+. You may optionally
specify additional +headers+ to search in for the +type+.

If the +type+ is found and is a numeric type, a macro is passed as a
preprocessor constant to the compiler using the +type+ name, in
uppercase, prepended with 'SIGNEDNESS...

Kernel#check_signedness(type, headers = nil, opts = nil) { ... } -> "signed" | "unsigned" | nil (19393.0)

Returns the signedness of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. If the +type+ is found and is a numeric type, a macro is passed as a preprocessor constant to the compiler using the +type+ name, in uppercase, prepended with 'SIGNEDNESS_OF_', followed by the +type+ name, followed by '=X' where 'X' is positive integer if the +type+ is unsigned, or negative integer if the +type+ is signed. For example, if size_t is defined as unsigned, then check_signedness('size_t') would returned +1 and the SIGNEDNESS_OF_SIZE_T=+1 preprocessor macro would be passed to the compiler, and SIGNEDNESS_OF_INT=-1 if check_signedness('int') is done.

Returns the signedness of the given +type+. You may optionally
specify additional +headers+ to search in for the +type+.

If the +type+ is found and is a numeric type, a macro is passed as a
preprocessor constant to the compiler using the +type+ name, in
uppercase, prepended with 'SIGNEDNESS...

Base64.#urlsafe_encode64(bin, padding: true) -> String (19219.0)

与えられたデータを Base64 エンコードした文字列を返します。

与えられたデータを Base64 エンコードした文字列を返します。

このメソッドは 4648 の "Base 64 Encoding with URL and Filename Safe Alphabet" に対応しています。
"+" を "-" に "/" を "_" に置き換えます。

デフォルトでは戻り値は = によるパディングを含むことがあります。
パディングを含めたくない場合は、padding オプションに false を指定してください。

@param bin Base64 エンコードするデータを指定します。
@param padding false を指定した場合、 = によ...

Shellwords.#shelljoin(array) -> String (18937.0)

配列の各要素である文字列に対して、Bourne シェルのコマンドライン中で安全に 使えるためのエスケープを適用し、空白文字を介してそれらを連結したコマンド ライン文字列を生成します。

配列の各要素である文字列に対して、Bourne シェルのコマンドライン中で安全に
使えるためのエスケープを適用し、空白文字を介してそれらを連結したコマンド
ライン文字列を生成します。

個々の配列要素に対するエスケープには、Shellwords.#shellescape と
同じ規則が適用されます。

@param array エスケープ対象の文字列を要素とする配列を指定します。
@return エスケープ結果を連結した文字列を返します。

例:
require 'shellwords'

pattern = 'Jan 15'
file = 'file nam...

Psych.safe_load(yaml, legacy_permitted_classes=[], legacy_permitted_symbols=[], legacy_aliases=false, legacy_filename=nil) -> object (18919.0)

安全に YAML フォーマットの文書を読み込み Ruby のオブジェクトを生成して返します。

安全に YAML フォーマットの文書を読み込み Ruby のオブジェクトを生成して返します。

デフォルトでは以下のクラスのオブジェクトしか変換しません。

* TrueClass
* FalseClass
* NilClass
* Numeric
* String
* Array
* Hash

再帰的なデータ構造はデフォルトでは許可されていません。

任意のクラスを許可するにはキーワード引数 permitted_classes を指定すると、
そのクラスが追加されます。例えば Date クラスを許可するには
以下のように書いてください:

//emlist[permitte...

絞り込み条件を変える

<< 1 2 > >>