種類
- インスタンスメソッド (1627)
- 特異メソッド (312)
- 定数 (24)
- クラス (24)
- モジュール (12)
クラス
-
Net
:: HTTP (1195) -
Net
:: HTTPGenericRequest (96) -
Net
:: HTTPRequest (12) -
Net
:: HTTPResponse (180)
モジュール
-
Net
:: HTTPExceptions (12) -
Net
:: HTTPHeader (468)
キーワード
-
CODE
_ CLASS _ TO _ OBJ (12) -
CODE
_ TO _ OBJ (12) - HTTPHeader (12)
- HTTPMultiStatus (12)
- HTTPNonAuthoritativeInformation (12)
- Proxy (12)
- [] (12)
- []= (12)
- active? (12)
-
add
_ field (12) - address (12)
-
basic
_ auth (12) - body (24)
-
body
_ exist? (12) -
body
_ permitted? (12) -
body
_ stream (12) -
body
_ stream= (12) -
ca
_ file (12) -
ca
_ path (12) -
canonical
_ each (12) - cert (12)
-
cert
_ store (12) - chunked? (12)
- ciphers (12)
-
close
_ on _ empty _ response (12) - code (12)
-
content
_ length (12) -
content
_ length= (12) -
content
_ range (12) -
content
_ type (12) -
content
_ type= (12) -
continue
_ timeout (12) - copy (12)
-
default
_ port (12) - delete (24)
- each (12)
-
each
_ capitalized (12) -
each
_ capitalized _ name (12) -
each
_ header (12) -
each
_ key (12) -
each
_ name (12) -
each
_ value (12) - entity (12)
- fetch (36)
- finish (12)
-
form
_ data= (12) - get (48)
- get2 (24)
-
get
_ fields (12) -
get
_ print (24) -
get
_ response (24) - head (12)
- head2 (24)
- header (12)
-
http
_ default _ port (12) -
http
_ version (12) -
https
_ default _ port (12) -
is
_ version _ 1 _ 1? (12) -
is
_ version _ 1 _ 2? (12) -
keep
_ alive _ timeout (12) -
keep
_ alive _ timeout= (12) - key (12)
- key? (12)
- length (12)
-
local
_ host (12) -
local
_ port (12) - lock (12)
-
main
_ type (12) - method (24)
- mkcol (12)
- move (12)
- msg (12)
- new (24)
-
open
_ timeout (12) - patch (24)
- path (12)
-
peer
_ cert (12) - port (12)
- post (24)
- post2 (24)
-
post
_ form (12) - propfind (12)
- proppatch (12)
- proxy? (12)
-
proxy
_ address (24) -
proxy
_ basic _ auth (12) -
proxy
_ class? (12) -
proxy
_ from _ env? (12) -
proxy
_ pass (24) -
proxy
_ port (24) -
proxy
_ uri (12) -
proxy
_ user (24) - proxyaddr (12)
- proxyport (12)
- put (12)
- put2 (24)
- range (12)
-
range
_ length (12) -
read
_ body (24) -
read
_ timeout (12) -
reader
_ header (12) - request (24)
-
request
_ body _ permitted? (12) -
request
_ get (24) -
request
_ head (24) -
request
_ post (24) -
request
_ put (24) - response (24)
-
response
_ body _ permitted? (12) -
send
_ request (12) -
set
_ content _ type (12) -
set
_ debug _ output (12) -
set
_ form _ data (12) -
set
_ range (36) - size (12)
-
ssl
_ timeout (12) -
ssl
_ version (12) - start (48)
- started? (12)
-
sub
_ type (12) - trace (12)
-
type
_ params (12) - unlock (12)
-
use
_ ssl? (12) - value (12)
-
verify
_ callback (12) -
verify
_ depth (12) -
verify
_ mode (12) -
version
_ 1 _ 1? (12) -
version
_ 1 _ 2 (12) -
version
_ 1 _ 2? (12) -
write
_ timeout (7)
検索結果
先頭5件
-
Net
:: HTTPHeader # content _ range -> Range|nil (130.0) -
Content-Range: ヘッダフィールドの値を Range で返します。 Range の表わす長さは Net::HTTPHeader#range_length で得られます。
...Content-Range: ヘッダフィールドの値を Range で返します。
Range の表わす長さは Net::HTTPHeader#range_length で得られます。
ヘッダが設定されていない場合には nil を返します。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.exa......mple.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req.content_range # => nil
req['Content-Range'] = "bytes 0-499/1234"
req.content_range # => 0..499
//}... -
Net
:: HTTP # keep _ alive _ timeout -> Integer (118.0) -
以前のリクエストで使ったコネクションの再利用(keep-alive)を許可する秒数を 返します。
...以前のリクエストで使ったコネクションの再利用(keep-alive)を許可する秒数を
返します。
デフォルトは2(秒)です。
@see Net::HTTP#keep_alive_timeout=... -
Net
:: HTTPHeader # content _ length -> Integer|nil (118.0) -
Content-Length: ヘッダフィールドの表している値を整数で返します。
...Content-Length: ヘッダフィールドの表している値を整数で返します。
ヘッダが設定されていない場合には nil を返します。
@raise Net::HTTPHeaderSyntaxError フィールドの値が不正である場合に
発生します。......//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req.content_length # => nil
req.content_length = 10
req.content_length # => 10
//}... -
Net
:: HTTPHeader # proxy _ basic _ auth(account , password) -> [String] (118.0) -
Proxy 認証のために Proxy-Authorization: ヘッダをセットします。
...Proxy 認証のために Proxy-Authorization: ヘッダをセットします。
@param account アカウント名を文字列で与えます。
@param password パスワードを文字列で与えます。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html... -
Net
:: HTTP # get2(path , header = nil) -> Net :: HTTPResponse (114.0) -
サーバ上の path にあるエンティティを取得します。 Net::HTTPResponse オブジェクトを返します。
...[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| # read body now
print str
end
}
//}... -
Net
:: HTTP # get2(path , header = nil) {|response| . . . . } -> Net :: HTTPResponse (114.0) -
サーバ上の path にあるエンティティを取得します。 Net::HTTPResponse オブジェクトを返します。
...[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| # read body now
print str
end
}
//}... -
Net
:: HTTP # request _ get(path , header = nil) -> Net :: HTTPResponse (114.0) -
サーバ上の path にあるエンティティを取得します。 Net::HTTPResponse オブジェクトを返します。
...[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| # read body now
print str
end
}
//}... -
Net
:: HTTP # request _ get(path , header = nil) {|response| . . . . } -> Net :: HTTPResponse (114.0) -
サーバ上の path にあるエンティティを取得します。 Net::HTTPResponse オブジェクトを返します。
...[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| # read body now
print str
end
}
//}... -
Net
:: HTTPHeader # [](key) -> String|nil (114.0) -
key ヘッダフィールドを返します。
...ー 'content-length' に対しては '2048'
のような文字列が得られます。キーが存在しなければ nil を返します。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req['user-agent'] # =>...