445件ヒット
[401-445件を表示]
(0.157秒)
クラス
- BasicSocket (11)
- Module (5)
-
Net
:: HTTP (165) -
OpenSSL
:: SSL :: SSLContext (11) -
OpenSSL
:: SSL :: SSLSocket (44) - OptionParser (154)
- Socket (11)
- TCPServer (11)
- UNIXServer (11)
モジュール
-
CGI
:: QueryExtension (11) -
Gem
:: LocalRemoteOptions (11)
キーワード
-
accept
_ language (11) -
accept
_ nonblock (44) -
accept
_ uri _ http (11) - connect (11)
-
connect
_ nonblock (11) - get (22)
- get2 (22)
- getsockopt (11)
- head (11)
- head2 (22)
- post2 (22)
-
post
_ connection _ check (11) - reject (11)
-
request
_ get (22) -
request
_ head (22) -
request
_ post (22) -
ruby2
_ keywords (5) -
session
_ cache _ stats (11)
検索結果
先頭5件
- Net
:: HTTP # head2(path , header = nil) -> Net :: HTTPResponse - Net
:: HTTP # post2(path , data , header = nil) -> Net :: HTTPResponse - Net
:: HTTP # request _ get(path , header = nil) -> Net :: HTTPResponse - Net
:: HTTP # request _ head(path , header = nil) -> Net :: HTTPResponse - Net
:: HTTP # request _ post(path , data , header = nil) -> Net :: HTTPResponse
-
Net
:: HTTP # head2(path , header = nil) -> Net :: HTTPResponse (207.0) -
サーバ上の path にあるエンティティのヘッダのみを取得します。 Net::HTTPResponse オブジェクトを返します。
...ィのヘッダのみを取得します。
Net::HTTPResponse オブジェクトを返します。
header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という
形のハッシュでなけれ......文字列で指定します。
@param header リクエストの HTTP ヘッダをハッシュで指定します。
head2 は時代遅れなので使わないでください。
//emlist[例][ruby]{
response = http.request_head('/index.html')
p response['content-type']
//}
@see Net::HTTP#head... -
Net
:: HTTP # post2(path , data , header = nil) -> Net :: HTTPResponse (207.0) -
サーバ上の path にあるエンティティに対し文字列 data を POST で送ります。 返り値は Net::HTTPResponse のインスタンスです。
...data を
POST で送ります。
返り値は Net::HTTPResponse のインスタンスです。
header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という
形のハッシュでなけれ......た状態で Net::HTTPResponse
オブジェクトをブロックに渡します。
POST する場合にはヘッダに Content-Type: を指定する必要があります。
もし header に指定しなかったならば、 Content-Type として
"application/x-www-form-urlencoded" を用います....../emlist[例][ruby]{
response = http.request_post('/cgi-bin/nice.rb', 'datadatadata...')
p response.status
puts response.body # body is already read
# using block
http.request_post('/cgi-bin/nice.rb', 'datadatadata...') {|response|
p response.status
p response['content-type']
response... -
Net
:: HTTP # request _ get(path , header = nil) -> Net :: HTTPResponse (207.0) -
サーバ上の path にあるエンティティを取得します。 Net::HTTPResponse オブジェクトを返します。
...るエンティティを取得します。
Net::HTTPResponse オブジェクトを返します。
header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という
形のハッシュでなけれ......に呼び出されたときは、
エンティティボディをソケットから読み出す前に、
接続を維持した状態で Net::HTTPResponse
オブジェクトをブロックに渡します。
大きなサイズのボディを一度に読みだすとまずく、
小さなサイズに分......で指定します。
//emlist[例][ruby]{
# example
response = http.request_get('/index.html')
p response['content-type']
puts response.body # body is already read
# using block
http.request_get('/index.html') {|response|
p response['content-type']
response.read_body do |str| # rea... -
Net
:: HTTP # request _ head(path , header = nil) -> Net :: HTTPResponse (207.0) -
サーバ上の path にあるエンティティのヘッダのみを取得します。 Net::HTTPResponse オブジェクトを返します。
...ィのヘッダのみを取得します。
Net::HTTPResponse オブジェクトを返します。
header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という
形のハッシュでなけれ......文字列で指定します。
@param header リクエストの HTTP ヘッダをハッシュで指定します。
head2 は時代遅れなので使わないでください。
//emlist[例][ruby]{
response = http.request_head('/index.html')
p response['content-type']
//}
@see Net::HTTP#head... -
Net
:: HTTP # request _ post(path , data , header = nil) -> Net :: HTTPResponse (207.0) -
サーバ上の path にあるエンティティに対し文字列 data を POST で送ります。 返り値は Net::HTTPResponse のインスタンスです。
...data を
POST で送ります。
返り値は Net::HTTPResponse のインスタンスです。
header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という
形のハッシュでなけれ......た状態で Net::HTTPResponse
オブジェクトをブロックに渡します。
POST する場合にはヘッダに Content-Type: を指定する必要があります。
もし header に指定しなかったならば、 Content-Type として
"application/x-www-form-urlencoded" を用います....../emlist[例][ruby]{
response = http.request_post('/cgi-bin/nice.rb', 'datadatadata...')
p response.status
puts response.body # body is already read
# using block
http.request_post('/cgi-bin/nice.rb', 'datadatadata...') {|response|
p response.status
p response['content-type']
response...