るりまサーチ

最速Rubyリファレンスマニュアル検索!
114件ヒット [1-100件を表示] (0.146秒)

別のキーワード

  1. rbconfig ruby
  2. fiddle ruby_free
  3. fiddle build_ruby_platform
  4. rake ruby
  5. rubygems/defaults ruby_engine

ライブラリ

クラス

キーワード

検索結果

<< 1 2 > >>

Object#send(name, *args) -> object (18305.0)

オブジェクトのメソッド name を args を引数に して呼び出し、メソッドの実行結果を返します。

...クトのメソッド name を args を引数に
して呼び出し、メソッドの実行結果を返します。

ブロック付きで呼ばれたときはブロックもそのまま引き渡します。

send
が再定義された場合に備えて別名 __send__ も
用意されており、ラ...
..._send__ は再定義すべきではありません。

send
, __send__ は、メソッドの呼び出し制限
にかかわらず任意のメソッドを呼び出せます。
d:spec/def#limit も参照してください。

public メソッドだけ呼び出せれば良い場合は
Object#public_send...
...しょう。

@param name 文字列かSymbol で指定するメソッド名です。
@param args 呼び出すメソッドに渡す引数です。

//emlist[][ruby]{
p -365.send(:abs) #=> 365
p "ruby".send(:sub,/./,"R") #=> "Ruby"


class Foo
def foo() "foo" end
def bar() "bar" end
def baz() "b...

Object#send(name, *args) { .... } -> object (18305.0)

オブジェクトのメソッド name を args を引数に して呼び出し、メソッドの実行結果を返します。

...クトのメソッド name を args を引数に
して呼び出し、メソッドの実行結果を返します。

ブロック付きで呼ばれたときはブロックもそのまま引き渡します。

send
が再定義された場合に備えて別名 __send__ も
用意されており、ラ...
..._send__ は再定義すべきではありません。

send
, __send__ は、メソッドの呼び出し制限
にかかわらず任意のメソッドを呼び出せます。
d:spec/def#limit も参照してください。

public メソッドだけ呼び出せれば良い場合は
Object#public_send...
...しょう。

@param name 文字列かSymbol で指定するメソッド名です。
@param args 呼び出すメソッドに渡す引数です。

//emlist[][ruby]{
p -365.send(:abs) #=> 365
p "ruby".send(:sub,/./,"R") #=> "Ruby"


class Foo
def foo() "foo" end
def bar() "bar" end
def baz() "b...

Net::HTTP#send_request(name, path, data = nil, header = nil) -> Net::HTTPResponse (12314.0)

HTTP リクエストをサーバに送り、そのレスポンスを Net::HTTPResponse のインスタンスとして返します。

...Net::HTTPResponse のインスタンスとして返します。

@param name リクエストのメソッド名を文字列で与えます。
@param path リクエストのパスを文字列で与えます。
@param data リクエストのボディを文字列で与えます。
@param header リク...
...エストのヘッダをハッシュで与えます。

//emlist[例][ruby]{
r
esponse = http.send_request('GET', '/index.html')
puts response.body
//}

@see Net::HTTP#request...

Module#ruby2_keywords(method_name, ...) -> nil (12238.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.

...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 argument...
...ash 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...
...other methods.

This should only be used for methods that delegate keywords to another
method, and only for backwards compatibility with Ruby versions before
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 version...

Proc#ruby2_keywords -> proc (12238.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...
...ormal 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.

This should only be used for procs that delegate keyword...
...s to another
method, and only for backwards compatibility with Ruby versions before
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...

絞り込み条件を変える

BasicObject#__send__(name, *args) -> object (6245.0)

オブジェクトのメソッド name を args を引数にして呼び出し、メソッドの結果を返します。

...name を args を引数にして呼び出し、メソッドの結果を返します。

ブロック付きで呼ばれたときはブロックもそのまま引き渡します。

@param name 呼び出すメソッドの名前。 Symbol または文字列で指定します。
@param args メソッ...
...t[例][ruby]{
class Mail
def delete(*args)
"(Mail#delete) - delete " + args.join(',')
end
def send(name, *args)
"(Mail#send) - #{name} #{args.join(',')}"
end
end
mail = Mail.new
mail.send :delete, "gentle", "readers" # => "(Mail#send) - delete gentle,readers"
mail.__send__ :del...
...ete, "gentle", "readers" # => "(Mail#delete) - delete gentle,readers"
//}

@see Object#send...

BasicObject#__send__(name, *args) { .... } -> object (6245.0)

オブジェクトのメソッド name を args を引数にして呼び出し、メソッドの結果を返します。

...name を args を引数にして呼び出し、メソッドの結果を返します。

ブロック付きで呼ばれたときはブロックもそのまま引き渡します。

@param name 呼び出すメソッドの名前。 Symbol または文字列で指定します。
@param args メソッ...
...t[例][ruby]{
class Mail
def delete(*args)
"(Mail#delete) - delete " + args.join(',')
end
def send(name, *args)
"(Mail#send) - #{name} #{args.join(',')}"
end
end
mail = Mail.new
mail.send :delete, "gentle", "readers" # => "(Mail#send) - delete gentle,readers"
mail.__send__ :del...
...ete, "gentle", "readers" # => "(Mail#delete) - delete gentle,readers"
//}

@see Object#send...

Object#public_send(name, *args) -> object (6239.0)

オブジェクトの public メソッド name を args を引数にして呼び出し、メソッ ドの実行結果を返します。

...の public メソッド name を args を引数にして呼び出し、メソッ
ドの実行結果を返します。

ブロック付きで呼ばれたときはブロックもそのまま引き渡します。

//emlist[][ruby]{
1.public_send(:+, 2) # => 3
//}

@param name 文字列かSymbol で指...
...@param args 呼び出すメソッドに渡す引数です。

@raise ArgumentError name を指定しなかった場合に発生します。

@raise NoMethodError protected メソッドや private メソッドに対して実行
した場合に発生します。

//emlist[][ruby]{...
...1.public_send(:puts, "hello") # => NoMethodError
//}

@see BasicObject#__send__, Object#send...

Object#public_send(name, *args) { .... } -> object (6239.0)

オブジェクトの public メソッド name を args を引数にして呼び出し、メソッ ドの実行結果を返します。

...の public メソッド name を args を引数にして呼び出し、メソッ
ドの実行結果を返します。

ブロック付きで呼ばれたときはブロックもそのまま引き渡します。

//emlist[][ruby]{
1.public_send(:+, 2) # => 3
//}

@param name 文字列かSymbol で指...
...@param args 呼び出すメソッドに渡す引数です。

@raise ArgumentError name を指定しなかった場合に発生します。

@raise NoMethodError protected メソッドや private メソッドに対して実行
した場合に発生します。

//emlist[][ruby]{...
...1.public_send(:puts, "hello") # => NoMethodError
//}

@see BasicObject#__send__, Object#send...
<< 1 2 > >>