るりまサーチ (Ruby 2.3.0)

最速Rubyリファレンスマニュアル検索!
10件ヒット [1-10件を表示] (0.143秒)
トップページ > バージョン:2.3.0[x] > 種類:インスタンスメソッド[x] > クエリ:l[x] > クエリ:open[x] > クラス:Net::HTTP[x]

別のキーワード

  1. matrix l
  2. kernel $-l
  3. _builtin $-l
  4. lupdecomposition l
  5. l

ライブラリ

キーワード

検索結果

Net::HTTP#open_timeout -> Integer|nil (18628.0)

接続時に待つ最大秒数を返します。

...接続時に待つ最大秒数を返します。

この秒数たってもコネクションが
開かなければ例外 Net::OpenTimeout を発生します。

デフォルトは 60 (秒)です。

@see Net::HTTP#read_timeout, Net::HTTP#open_timeout=...

Net::HTTP#cert -> OpenSSL::X509::Certificate | nil (607.0)

クライアント証明書を返します。

...クライアント証明書を返します。

@see Net::HTTP#cert=, OpenSSL::SSL::SSLContext#cert...

Net::HTTP#cert_store -> OpenSSL::X509::Store | nil (607.0)

接続相手の証明書の検証のために使う、信頼している CA 証明書を 含む証明書ストアを返します。

...接続相手の証明書の検証のために使う、信頼している CA 証明書を
含む証明書ストアを返します。

@see Net::HTTP#cert_store, OpenSSL::SSL::SSLContext#cert_store=...

Net::HTTP#key -> OpenSSL::PKey::PKey | nil (607.0)

クライアント証明書の秘密鍵を返します。

...クライアント証明書の秘密鍵を返します。

@see Net::HTTP#key=, OpenSSL::SSL::SSLContext#key...

Net::HTTP#peer_cert -> OpenSSL::X509::Certificate | nil (607.0)

サーバの証明書を返します。

サーバの証明書を返します。

SSL/TLS が有効でなかったり、接続前である場合には nil
を返します。

@see OpenSSL::SSL::SSLSocket#peer_cert

絞り込み条件を変える

Net::HTTP#get(path, header = nil, dest = nil) -> Net::HTTPResponse (325.0)

サーバ上の path にあるエンティティを取得し、 Net::HTTPResponse のインスタンスとして返します。

...サーバ上の path にあるエンティティを取得し、
Net::HTTP
Response のインスタンスとして返します。

header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という...
...呼びだされたときは
エンティティボディを少しずつ文字列として
ブロックに与えます。このとき戻り値の
Net::HTTP
Response オブジェクトは有効な body を
持ちません。

dest は時代遅れの引数です。利用しないでください。
dest...
....html' )

# net/http version 1.2
response = http.get('/index.html')

# compatible in both version
response , = http.get('/index.html')
response.body

# compatible, using block
File.open('save.txt', 'w') {|f|
http.get('/~foo/', nil) do |str|
f.write str
end
}
//}

@see Net::HTTP#request_get...

Net::HTTP#get(path, header = nil, dest = nil) {|body_segment| .... } -> Net::HTTPResponse (325.0)

サーバ上の path にあるエンティティを取得し、 Net::HTTPResponse のインスタンスとして返します。

...サーバ上の path にあるエンティティを取得し、
Net::HTTP
Response のインスタンスとして返します。

header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という...
...呼びだされたときは
エンティティボディを少しずつ文字列として
ブロックに与えます。このとき戻り値の
Net::HTTP
Response オブジェクトは有効な body を
持ちません。

dest は時代遅れの引数です。利用しないでください。
dest...
....html' )

# net/http version 1.2
response = http.get('/index.html')

# compatible in both version
response , = http.get('/index.html')
response.body

# compatible, using block
File.open('save.txt', 'w') {|f|
http.get('/~foo/', nil) do |str|
f.write str
end
}
//}

@see Net::HTTP#request_get...

Net::HTTP#post(path, data, header = nil, dest = nil) -> Net::HTTPResponse (325.0)

サーバ上の path にあるエンティティに対し文字列 data を POST で送ります。

...サーバ上の path にあるエンティティに対し文字列 data を
POST で送ります。

返り値は Net::HTTPResponse のインスタンスです。

ブロックと一緒に呼びだされたときはエンティティボディを少しずつ文字列として
ブロックに与え...
....rb', 'query=subject&target=ruby')

# version 1.2
response = http.post('/cgi-bin/search.rb', 'query=subject&target=ruby')

# using block
File.open('save.html', 'w') {|f|
http.post('/cgi-bin/search.rb', 'query=subject&target=ruby') do |str|
f.write str
end
}
//}

@see Net::HTTP#request_post...

Net::HTTP#post(path, data, header = nil, dest = nil) {|body_segment| .... } -> Net::HTTPResponse (325.0)

サーバ上の path にあるエンティティに対し文字列 data を POST で送ります。

...サーバ上の path にあるエンティティに対し文字列 data を
POST で送ります。

返り値は Net::HTTPResponse のインスタンスです。

ブロックと一緒に呼びだされたときはエンティティボディを少しずつ文字列として
ブロックに与え...
....rb', 'query=subject&target=ruby')

# version 1.2
response = http.post('/cgi-bin/search.rb', 'query=subject&target=ruby')

# using block
File.open('save.html', 'w') {|f|
http.post('/cgi-bin/search.rb', 'query=subject&target=ruby') do |str|
f.write str
end
}
//}

@see Net::HTTP#request_post...

Net::HTTP#read_timeout -> Integer|nil (325.0)

読みこみ(read(2)) 一回でブロックしてよい最大秒数 を返します。

...ックしてよい最大秒数
を返します。

この秒数たっても読みこめなければ例外 Net::ReadTimeout
を発生します。

nilはタイムアウトしないことを意味します。

デフォルトは 60 (秒)です。

@see Net::HTTP#open_timeout, Net::HTTP#read_timeout=...

絞り込み条件を変える