1082件ヒット
[1-100件を表示]
(0.133秒)
別のキーワード
ライブラリ
- ビルトイン (544)
-
cgi
/ core (24) -
cgi
/ html (72) - delegate (24)
-
irb
/ input-method (120) -
minitest
/ unit (2) -
net
/ http (24) - openssl (36)
- psych (8)
-
rdoc
/ top _ level (12) -
webrick
/ httprequest (12) -
webrick
/ httpresponse (12) - win32ole (192)
クラス
- BasicObject (12)
- CGI (24)
- Delegator (24)
- Enumerator (24)
-
Enumerator
:: Lazy (48) - Exception (12)
-
IRB
:: FileInputMethod (24) -
IRB
:: InputMethod (24) -
IRB
:: ReadlineInputMethod (36) -
IRB
:: StdioInputMethod (36) - Method (62)
-
MiniTest
:: Unit (1) - Module (80)
- NameError (12)
-
Net
:: HTTPGenericRequest (12) - NoMethodError (12)
- Object (96)
-
OpenSSL
:: Engine (12) -
OpenSSL
:: SSL :: SSLContext (24) - Proc (26)
-
RDoc
:: TopLevel (12) - Regexp (24)
-
RubyVM
:: InstructionSequence (36) - String (60)
- UnboundMethod (48)
-
WEBrick
:: HTTPRequest (12) -
WEBrick
:: HTTPResponse (12) - WIN32OLE (36)
-
WIN32OLE
_ METHOD (108) -
WIN32OLE
_ PARAM (48)
モジュール
-
CGI
:: HtmlExtension (72) -
MiniTest
:: Assertions (1) -
Net
:: HTTPHeader (12)
キーワード
- << (14)
- >> (14)
-
_ getproperty (12) -
_ invoke (12) -
_ setproperty (12) -
absolute
_ path (12) - args (12)
- arity (24)
-
assert
_ respond _ to (1) - backtrace (12)
-
class
_ exec (12) - dispid (12)
- each (24)
- encode (36)
- encoding (36)
-
enum
_ for (48) -
file
_ name (12) -
find
_ local _ symbol (12) -
first
_ lineno (12) - form (24)
- gets (48)
- hash (24)
- header (12)
- helpcontext (12)
- helpfile (12)
- helpstring (12)
- inspect (24)
- line (24)
- match (24)
-
method
_ missing (12) -
module
_ exec (12) -
module
_ function (12) -
multipart
_ form (48) - name (12)
-
ole
_ type (12) -
ole
_ type _ detail (12) - out (12)
- path (12)
- private (12)
- protected (12)
-
protected
_ methods (12) -
psych
_ yaml _ as (4) - public (12)
-
public
_ methods (12) - puke (1)
-
renegotiation
_ cb= (12) -
request
_ method (24) -
respond
_ to _ missing? (12) -
return
_ type (12) -
return
_ type _ detail (12) -
return
_ vtype (12) - send (24)
-
session
_ get _ cb= (12) -
set
_ default (12) -
singleton
_ methods (12) -
size
_ opt _ params (12) -
size
_ params (12) -
source
_ location (12) -
to
_ enum (48) -
to
_ s (60) -
to
_ str (12) -
yaml
_ as (4)
検索結果
先頭5件
-
Net
:: HTTPGenericRequest # method -> String (24214.0) -
リクエストの HTTP メソッドを文字列で返します。
...リクエストの HTTP メソッドを文字列で返します。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Post.new(uri.request_uri)
req.method # => "POST"
req = Net::HTTP::Get.new(uri.request_uri)
req.method # => "GET"
//}... -
Net
:: HTTPHeader # method -> String (21208.0) -
リクエストの HTTP メソッドを文字列で返します。
...リクエストの HTTP メソッドを文字列で返します。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req.method # => "GET"
//}... -
Method
# inspect -> String (15375.0) -
self を読みやすい文字列として返します。
...します。
以下の形式の文字列を返します。
#<Method: klass1(klass2)#method> (形式1)
klass1 は、Method#inspect では、レシーバのクラス名、
UnboundMethod#inspect では、UnboundMethod オブジェクトの生成
元となったクラス/モジュ......モジュール名、
method は、メソッド名を表します。
//emlist[例][ruby]{
module Foo
def foo
"foo"
end
end
class Bar
include Foo
def bar
end
end
p Bar.new.method(:foo) # => #<Method: Bar(Foo)#foo>
p Bar.new.method(:bar) # => #<Method: Bar#bar>
//}
klass......が同じ場合は以下の形式になります。
#<Method: klass1#method> (形式2)
特異メソッドに対しては、
#<Method: obj.method> (形式3)
#<Method: klass1(klass2).method> (形式4)
という形式の文字列......します。
以下の形式の文字列を返します。
#<Method: klass1(klass2)#method(arg) foo.rb:2> (形式1)
klass1 は、Method#inspect では、レシーバのクラス名、
UnboundMethod#inspect では、UnboundMethod オブジェクトの生成
元となったクラス/モジ......klass2 は、実際にそのメソッドを定義しているクラス/モジュール名、
method は、メソッド名を表します。
arg は引数を表します。
「foo.rb:2」は Method#source_location を表します。
source_location が nil の場合には付きません。
//em......Foo
def bar(a, b)
end
end
p Bar.new.method(:foo) # => #<Method: Bar(Foo)#foo() test.rb:2>
p Bar.new.method(:bar) # => #<Method: Bar#bar(a, b) test.rb:8>
//}
klass1 と klass2 が同じ場合は以下の形式になります。
#<Method: klass1#method() foo.rb:2> (... -
WIN32OLE
_ METHOD # helpstring -> String | nil (15319.0) -
メソッドのヘルプ文字列を取得します。
...す。
helpstringは、IDEがメソッドのバルーンヘルプを表示するような場合に利用可
能な、1行程度でメソッドを説明する文字列です。
@return ヘルプ文字列を返します。未定義ならばnilを返します。
tobj = WIN32OLE_TYPE.new('Microsof......t Internet Controls', 'IWebBrowser')
method = WIN32OLE_METHOD.new(tobj, 'Navigate')
puts method.helpstring # => Navigates to a URL or file.... -
Delegator
# protected _ methods(all = true) -> [Symbol] (15201.0) -
そのオブジェクトが理解できる protected メソッド名の一覧を返します。
...そのオブジェクトが理解できる protected メソッド名の一覧を返します。
@param all 偽を指定すると __getobj__ のスーパークラスで定義されたメソッドを除きます。
@see Object#protected_methods... -
Delegator
# public _ methods(all = true) -> [Symbol] (15201.0) -
そのオブジェクトが理解できる public メソッド名の一覧を返します。
...そのオブジェクトが理解できる public メソッド名の一覧を返します。
@param all 偽を指定すると __getobj__ のスーパークラスで定義されたメソッドを除きます。
@see Object#public_methods... -
Method
# to _ s -> String (12275.0) -
self を読みやすい文字列として返します。
...します。
以下の形式の文字列を返します。
#<Method: klass1(klass2)#method> (形式1)
klass1 は、Method#inspect では、レシーバのクラス名、
UnboundMethod#inspect では、UnboundMethod オブジェクトの生成
元となったクラス/モジュ......モジュール名、
method は、メソッド名を表します。
//emlist[例][ruby]{
module Foo
def foo
"foo"
end
end
class Bar
include Foo
def bar
end
end
p Bar.new.method(:foo) # => #<Method: Bar(Foo)#foo>
p Bar.new.method(:bar) # => #<Method: Bar#bar>
//}
klass......が同じ場合は以下の形式になります。
#<Method: klass1#method> (形式2)
特異メソッドに対しては、
#<Method: obj.method> (形式3)
#<Method: klass1(klass2).method> (形式4)
という形式の文字列......します。
以下の形式の文字列を返します。
#<Method: klass1(klass2)#method(arg) foo.rb:2> (形式1)
klass1 は、Method#inspect では、レシーバのクラス名、
UnboundMethod#inspect では、UnboundMethod オブジェクトの生成
元となったクラス/モジ......klass2 は、実際にそのメソッドを定義しているクラス/モジュール名、
method は、メソッド名を表します。
arg は引数を表します。
「foo.rb:2」は Method#source_location を表します。
source_location が nil の場合には付きません。
//em......Foo
def bar(a, b)
end
end
p Bar.new.method(:foo) # => #<Method: Bar(Foo)#foo() test.rb:2>
p Bar.new.method(:bar) # => #<Method: Bar#bar(a, b) test.rb:8>
//}
klass1 と klass2 が同じ場合は以下の形式になります。
#<Method: klass1#method() foo.rb:2> (... -
Object
# respond _ to _ missing?(symbol , include _ private) -> bool (12241.0) -
自身が symbol で表されるメソッドに対し BasicObject#method_missing で反応するつもりならば真を返します。
...ソッドに対し
BasicObject#method_missing で反応するつもりならば真を返します。
Object#respond_to? はメソッドが定義されていない場合、
デフォルトでこのメソッドを呼びだし問合せます。
BasicObject#method_missing を override した場合に......。
@param symbol メソッド名シンボル
@param include_private private method も含めたい場合に true が渡されます
//emlist[例][ruby]{
class Sample
def method_missing(name, *args)
if name =~ /^to_*/
[name, *args] # => [:to_sample, "sample args1", "sample args2"]......super
end
end
def respond_to_missing?(sym, include_private)
(sym =~ /^to_*/) ? true : super
end
end
s = Sample.new
s.to_sample("sample args1", "sample args2")
s.respond_to?(:to_sample) # => true
s.respond_to?(:sample) # => false
//}
@see Object#respond_to?, BasicObject#method_m... -
Object
# singleton _ methods(inherited _ too = true) -> [Symbol] (12231.0) -
そのオブジェクトに対して定義されている特異メソッド名 (public あるいは protected メソッド) の一覧を返します。
...そのオブジェクトに対して定義されている特異メソッド名
(public あるいは protected メソッド) の一覧を返します。
inherited_too が真のときは継承した特異メソッドを含みます。
継承した特異メソッドとは Object#extend によって追......ngleton_methods(false) は、Object#methods(false) と同じです。
@param inherited_too 継承した特異メソッドを含める場合は真を、
そうでない場合は偽を指定します。
//emlist[例1][ruby]{
Parent = Class.new
class <<Parent
private; def pr......_class_parent() end
protected; def protected_class_parent() end
public; def public_class_parent() end
end
Foo = Class.new(Parent)
class <<Foo
private; def private_class_foo() end
protected; def protected_class_foo() end
public; def public_class_foo() end
end
module Bar
private...