るりまサーチ

最速Rubyリファレンスマニュアル検索!
2599件ヒット [1-100件を表示] (0.133秒)
トップページ > クエリ:E[x] > クエリ:Include[x]

別のキーワード

  1. open3 popen2e
  2. socket af_e164
  3. matrix det_e
  4. matrix rank_e
  5. open3 capture2e

オブジェクト

キーワード

検索結果

<< 1 2 3 ... > >>

Enumerable#include?(val) -> bool (32213.0)

val と == の関係にある要素を含むとき真を返します。

...val と == の関係にある要素を含むとき真を返します。

@param val 任意のオブジェクト

//emlist[例][ruby]{
[2, 4, 6].include? 2 #=> true
[2, 4, 6].include? 1 #=> false
[2, 4, 6].member? 2 #=> true
[2, 4, 6].member? 1 #=> false
//}...

ENV.include?(key) -> bool (29201.0)

key で指定される環境変数が存在する時、真を返します。

...key で指定される環境変数が存在する時、真を返します。

@param key 環境変数の名前を指定します。文字列で指定します。
文字列以外のオブジェクトを指定した場合は to_str メソッ
ドによる暗黙の型変換を試...

Enumerable#member?(val) -> bool (29113.0)

val と == の関係にある要素を含むとき真を返します。

...val と == の関係にある要素を含むとき真を返します。

@param val 任意のオブジェクト

//emlist[例][ruby]{
[2, 4, 6].include? 2 #=> true
[2, 4, 6].include? 1 #=> false
[2, 4, 6].member? 2 #=> true
[2, 4, 6].member? 1 #=> false
//}...

Enumerable#each_entry -> Enumerator (29106.0)

ブロックを各要素に一度ずつ適用します。

...配列として渡されます。

//emlist[例][ruby]{
class Foo
include
Enumerable
def each
yield 1
yield 1,2
e
nd
e
nd
Foo.new.each_entry{|o| print o, " -- "}
# => 1 -- [1, 2] --
//}

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

@see Enumerable#slice_before...

Enumerable#each_entry {|obj| block} -> self (29106.0)

ブロックを各要素に一度ずつ適用します。

...配列として渡されます。

//emlist[例][ruby]{
class Foo
include
Enumerable
def each
yield 1
yield 1,2
e
nd
e
nd
Foo.new.each_entry{|o| print o, " -- "}
# => 1 -- [1, 2] --
//}

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

@see Enumerable#slice_before...

絞り込み条件を変える

ENV.has_key?(key) -> bool (26201.0)

key で指定される環境変数が存在する時、真を返します。

...key で指定される環境変数が存在する時、真を返します。

@param key 環境変数の名前を指定します。文字列で指定します。
文字列以外のオブジェクトを指定した場合は to_str メソッ
ドによる暗黙の型変換を試...

ENV.key?(key) -> bool (26201.0)

key で指定される環境変数が存在する時、真を返します。

...key で指定される環境変数が存在する時、真を返します。

@param key 環境変数の名前を指定します。文字列で指定します。
文字列以外のオブジェクトを指定した場合は to_str メソッ
ドによる暗黙の型変換を試...

ERB#def_module(methodname=&#39;erb&#39;) -> Module (26106.0)

変換した Ruby スクリプトをメソッドとして定義した無名のモジュールを返します。

...am methodname メソッド名

//emlist[例][ruby]{
require 'erb'
filename = 'example.rhtml'
e
rb = ERB.new("test1<%= arg1 %>\ntest2<%= arg2 %>\n")
e
rb.filename = filename
MyModule = erb.def_module('render(arg1, arg2)')
class MyClass
include
MyModule
e
nd
print MyClass.new.render('foo', 123)
# test1...
...foo
# test2123
//}...

ERB::Util.#html_escape(s) -> String (26106.0)

文字列 s を HTML用にエスケープした文字列を返します。

...照 &amp; &quot; &lt; &gt; にそれぞれ変更した文字列を返します
(CGI.escapeHTMLとほぼ同じです)。

@param s HTMLエスケープを行う文字列

//emlist[例][ruby]{
require "erb"
include
ERB::Util

puts html_escape("is a > 0 & a < 10?")
# is a &gt; 0 &amp; a &lt; 10?
//}...
<< 1 2 3 ... > >>