種類
- インスタンスメソッド (22)
- ライブラリ (3)
- 文書 (1)
ライブラリ
- csv (5)
- mkmf (4)
-
net
/ http (8) -
rubygems
/ package / tar _ header (4) -
webrick
/ httprequest (1)
クラス
- CSV (3)
-
CSV
:: Row (2) -
Gem
:: Package :: TarHeader (4) -
Net
:: HTTP (1) -
WEBrick
:: HTTPRequest (1)
モジュール
- Kernel (4)
-
Net
:: HTTPHeader (7)
キーワード
- [] (1)
-
canonical
_ each (1) - cgi (1)
-
cgi
/ session (1) -
check
_ signedness (2) -
convertible
_ int (2) - each (1)
-
each
_ capitalized (1) -
each
_ capitalized _ name (1) -
each
_ header (1) -
each
_ key (1) -
each
_ name (1) - gname (1)
- header? (1)
-
header
_ convert (3) - include? (1)
- linkname (1)
-
ruby 1
. 8 . 4 feature (1) -
send
_ request (1) - uname (1)
-
webrick
/ cgi (1)
検索結果
先頭5件
-
Gem
:: Package :: TarHeader # name -> String (63352.0) -
tar のヘッダに含まれる name を返します。
tar のヘッダに含まれる name を返します。 -
Net
:: HTTPHeader # each _ capitalized _ name {|name| . . . . } -> () (27625.0) -
保持しているヘッダ名を正規化 ('x-my-header' -> 'X-My-Header') して、ブロックに渡します。
保持しているヘッダ名を正規化
('x-my-header' -> 'X-My-Header')
して、ブロックに渡します。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req.each_capitalized_name { |key| puts key }
# => Accept-Encoding
# => Accept
# => User-Agent
//} -
Gem
:: Package :: TarHeader # gname -> String (27301.0) -
tar のヘッダに含まれるグループ名を返します。
tar のヘッダに含まれるグループ名を返します。 -
Gem
:: Package :: TarHeader # linkname -> String (27301.0) -
tar のヘッダに含まれる linkname を返します。
tar のヘッダに含まれる linkname を返します。 -
Gem
:: Package :: TarHeader # uname -> String (27301.0) -
tar のヘッダに含まれるユーザ名を返します。
tar のヘッダに含まれるユーザ名を返します。 -
Net
:: HTTPHeader # each _ name {|name| . . . } -> () (18664.0) -
保持しているヘッダ名をブロックに渡して呼びだします。
保持しているヘッダ名をブロックに渡して呼びだします。
ヘッダ名は小文字で統一されます。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req.each_name { |name| puts name }
# => accept-encoding
# => accept
# => user-agent
//} -
CSV
# header _ convert(name) (18640.0) -
CSV#convert に似ていますが、ヘッダ行用のメソッドです。
CSV#convert に似ていますが、ヘッダ行用のメソッドです。
このメソッドはヘッダ行を読み込む前に呼び出さなければなりません。
@param name 変換器の名前を指定します。
//emlist[例 name を指定][ruby]{
require "csv"
csv = CSV.new("header1,header2\nrow1_1,row1_2", headers: true)
csv.header_convert(:symbol)
csv.first.headers # => [:header1, :header2]
//}
//emlist[例 ブロックを指定][... -
CSV
:: Row # header?(name) -> bool (18625.0) -
自身のヘッダに与えられた値が含まれている場合は真を返します。 そうでない場合は偽を返します。
自身のヘッダに与えられた値が含まれている場合は真を返します。
そうでない場合は偽を返します。
@param name この行のヘッダに含まれているかどうか調べたい値を指定します。
//emlist[例][ruby]{
require "csv"
row = CSV::Row.new(["header1", "header2"], [1, 2])
row.header?("header1") # => true
row.header?("header3") # => false
//} -
Net
:: HTTPHeader # each _ header {|name , val| . . . . } -> () (18607.0) -
保持しているヘッダ名とその値をそれぞれ ブロックに渡して呼びだします。
保持しているヘッダ名とその値をそれぞれ
ブロックに渡して呼びだします。
ヘッダ名は小文字で統一されます。
val は ", " で連結した文字列がブロックに渡されます。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req.each_header { |key,value| puts "#{key} = #{value}" }
# => accept-encoding... -
CSV
# header _ convert {|field , field _ info| . . . } (18340.0) -
CSV#convert に似ていますが、ヘッダ行用のメソッドです。
CSV#convert に似ていますが、ヘッダ行用のメソッドです。
このメソッドはヘッダ行を読み込む前に呼び出さなければなりません。
@param name 変換器の名前を指定します。
//emlist[例 name を指定][ruby]{
require "csv"
csv = CSV.new("header1,header2\nrow1_1,row1_2", headers: true)
csv.header_convert(:symbol)
csv.first.headers # => [:header1, :header2]
//}
//emlist[例 ブロックを指定][... -
CSV
# header _ convert {|field| . . . } (18340.0) -
CSV#convert に似ていますが、ヘッダ行用のメソッドです。
CSV#convert に似ていますが、ヘッダ行用のメソッドです。
このメソッドはヘッダ行を読み込む前に呼び出さなければなりません。
@param name 変換器の名前を指定します。
//emlist[例 name を指定][ruby]{
require "csv"
csv = CSV.new("header1,header2\nrow1_1,row1_2", headers: true)
csv.header_convert(:symbol)
csv.first.headers # => [:header1, :header2]
//}
//emlist[例 ブロックを指定][... -
Net
:: HTTPHeader # each _ key {|name| . . . } -> () (9364.0) -
保持しているヘッダ名をブロックに渡して呼びだします。
保持しているヘッダ名をブロックに渡して呼びだします。
ヘッダ名は小文字で統一されます。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req.each_name { |name| puts name }
# => accept-encoding
# => accept
# => user-agent
//} -
Net
:: HTTPHeader # canonical _ each {|name , value| . . . . } -> () (9343.0) -
ヘッダフィールドの正規化名とその値のペアを ブロックに渡し、呼びだします。
ヘッダフィールドの正規化名とその値のペアを
ブロックに渡し、呼びだします。
正規化名は name に対し
name.downcase.split(/-/).capitalize.join('-')
で求まる文字列です。 -
Net
:: HTTPHeader # each _ capitalized {|name , value| . . . . } -> () (9343.0) -
ヘッダフィールドの正規化名とその値のペアを ブロックに渡し、呼びだします。
ヘッダフィールドの正規化名とその値のペアを
ブロックに渡し、呼びだします。
正規化名は name に対し
name.downcase.split(/-/).capitalize.join('-')
で求まる文字列です。 -
CSV
:: Row # include?(name) -> bool (9325.0) -
自身のヘッダに与えられた値が含まれている場合は真を返します。 そうでない場合は偽を返します。
自身のヘッダに与えられた値が含まれている場合は真を返します。
そうでない場合は偽を返します。
@param name この行のヘッダに含まれているかどうか調べたい値を指定します。
//emlist[例][ruby]{
require "csv"
row = CSV::Row.new(["header1", "header2"], [1, 2])
row.header?("header1") # => true
row.header?("header3") # => false
//} -
Net
:: HTTPHeader # each {|name , val| . . . . } -> () (9307.0) -
保持しているヘッダ名とその値をそれぞれ ブロックに渡して呼びだします。
保持しているヘッダ名とその値をそれぞれ
ブロックに渡して呼びだします。
ヘッダ名は小文字で統一されます。
val は ", " で連結した文字列がブロックに渡されます。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req.each_header { |key,value| puts "#{key} = #{value}" }
# => accept-encoding... -
Net
:: HTTP # send _ request(name , path , data = nil , header = nil) -> Net :: HTTPResponse (622.0) -
HTTP リクエストをサーバに送り、そのレスポンスを Net::HTTPResponse のインスタンスとして返します。
HTTP リクエストをサーバに送り、そのレスポンスを
Net::HTTPResponse のインスタンスとして返します。
@param name リクエストのメソッド名を文字列で与えます。
@param path リクエストのパスを文字列で与えます。
@param data リクエストのボディを文字列で与えます。
@param header リクエストのヘッダをハッシュで与えます。
//emlist[例][ruby]{
response = http.send_request('GET', '/index.html')
puts response.body
//}
@see Net::H... -
WEBrick
:: HTTPRequest # [](header _ name) -> String (622.0) -
リクエストのヘッダの該当する内容を文字列で返します。
リクエストのヘッダの該当する内容を文字列で返します。
@param header_name ヘッダー名を文字列で指定します。大文字と小文字を区別しません。 -
Kernel
# convertible _ int(type , headers = nil , opts = nil) (541.0) -
Returns the convertible integer type of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. _Convertible_ means actually same type, or typedefed from same type. If the +type+ is a integer type and _convertible_ type is found, following macros are passed as preprocessor constants to the compiler using the +type+ name, in uppercase. * 'TYPEOF_', followed by the +type+ name, followed by '=X' where 'X' is the found _convertible_ type name. * 'TYP2NUM' and 'NUM2TYP, where 'TYP' is the +type+ name in uppercase with replacing '_t' suffix with 'T', followed by '=X' where 'X' is the macro name to convert +type+ to +Integer+ object, and vice versa. For example, if foobar_t is defined as unsigned long, then convertible_int("foobar_t") would return "unsigned long", and define macros: #define TYPEOF_FOOBAR_T unsigned long #define FOOBART2NUM ULONG2NUM #define NUM2FOOBART NUM2ULONG
Returns the convertible integer type of the given +type+. You may
optionally specify additional +headers+ to search in for the +type+.
_Convertible_ means actually same type, or typedefed from same type.
If the +type+ is a integer type and _convertible_ type is found,
following macros are p... -
Kernel
# convertible _ int(type , headers = nil , opts = nil) { . . . } (541.0) -
Returns the convertible integer type of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. _Convertible_ means actually same type, or typedefed from same type. If the +type+ is a integer type and _convertible_ type is found, following macros are passed as preprocessor constants to the compiler using the +type+ name, in uppercase. * 'TYPEOF_', followed by the +type+ name, followed by '=X' where 'X' is the found _convertible_ type name. * 'TYP2NUM' and 'NUM2TYP, where 'TYP' is the +type+ name in uppercase with replacing '_t' suffix with 'T', followed by '=X' where 'X' is the macro name to convert +type+ to +Integer+ object, and vice versa. For example, if foobar_t is defined as unsigned long, then convertible_int("foobar_t") would return "unsigned long", and define macros: #define TYPEOF_FOOBAR_T unsigned long #define FOOBART2NUM ULONG2NUM #define NUM2FOOBART NUM2ULONG
Returns the convertible integer type of the given +type+. You may
optionally specify additional +headers+ to search in for the +type+.
_Convertible_ means actually same type, or typedefed from same type.
If the +type+ is a integer type and _convertible_ type is found,
following macros are p... -
cgi
/ session (541.0) -
CGI のセッション管理を行うライブラリ。
CGI のセッション管理を行うライブラリ。
セッションとは、HTTP の一連のリクエストとレスポンスが属するべき
コンテクスト (状況) のことをいいます。
セッション管理には従来通り cgi ライブラリが提供する
クッキーを使用してもいいですが、
この cgi/session を使用した方がよりわかりやすいでしょう。
セッション情報は Hash ライクなインターフェースです。
セッションはセッション ID とプログラムが記録した
セッション情報から構成されます。
デフォルトでは CGI::Session::FileStore が使用され、
記録できるのは文字列のみです。
セッション情報... -
cgi (433.0)
-
CGI プログラムの支援ライブラリです。
CGI プログラムの支援ライブラリです。
CGI プロトコルの詳細については以下の文書を参照してください。
* https://tools.ietf.org/html/draft-coar-cgi-v11-03
* 3875: The Common Gateway Interface (CGI) Version 1.1
* https://www.w3.org/CGI/
=== 使用例
==== フォームフィールドの値を得る
//emlist[][ruby]{
require "cgi"
cgi = CGI.new
values = cgi['field_name'] ... -
Kernel
# check _ signedness(type , headers = nil , opts = nil) -> "signed" | "unsigned" | nil (397.0) -
Returns the signedness of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. If the +type+ is found and is a numeric type, a macro is passed as a preprocessor constant to the compiler using the +type+ name, in uppercase, prepended with 'SIGNEDNESS_OF_', followed by the +type+ name, followed by '=X' where 'X' is positive integer if the +type+ is unsigned, or negative integer if the +type+ is signed. For example, if size_t is defined as unsigned, then check_signedness('size_t') would returned +1 and the SIGNEDNESS_OF_SIZE_T=+1 preprocessor macro would be passed to the compiler, and SIGNEDNESS_OF_INT=-1 if check_signedness('int') is done.
Returns the signedness of the given +type+. You may optionally
specify additional +headers+ to search in for the +type+.
If the +type+ is found and is a numeric type, a macro is passed as a
preprocessor constant to the compiler using the +type+ name, in
uppercase, prepended with 'SIGNEDNESS... -
Kernel
# check _ signedness(type , headers = nil , opts = nil) { . . . } -> "signed" | "unsigned" | nil (397.0) -
Returns the signedness of the given +type+. You may optionally specify additional +headers+ to search in for the +type+. If the +type+ is found and is a numeric type, a macro is passed as a preprocessor constant to the compiler using the +type+ name, in uppercase, prepended with 'SIGNEDNESS_OF_', followed by the +type+ name, followed by '=X' where 'X' is positive integer if the +type+ is unsigned, or negative integer if the +type+ is signed. For example, if size_t is defined as unsigned, then check_signedness('size_t') would returned +1 and the SIGNEDNESS_OF_SIZE_T=+1 preprocessor macro would be passed to the compiler, and SIGNEDNESS_OF_INT=-1 if check_signedness('int') is done.
Returns the signedness of the given +type+. You may optionally
specify additional +headers+ to search in for the +type+.
If the +type+ is found and is a numeric type, a macro is passed as a
preprocessor constant to the compiler using the +type+ name, in
uppercase, prepended with 'SIGNEDNESS... -
webrick
/ cgi (163.0) -
一般の CGI 環境で webrick ライブラリのサーブレットと同じように CGI スクリプトを書くための ライブラリです。サーバが WEBrick でなくても使うことが出来ます。
一般の CGI 環境で webrick ライブラリのサーブレットと同じように CGI スクリプトを書くための
ライブラリです。サーバが WEBrick でなくても使うことが出来ます。
=== 使い方
WEBrick のサーブレットを作成するのと同じように、WEBrick::CGI のサブクラスでメソッド
do_GET や do_POST を定義することによって CGI スクリプトを書きます。
スクリプトの最後で WEBrick::CGI#start メソッドを呼ぶ必要があります。
WEBrick::CGI#start メソッドは service メソッドを呼び出し、service メソッ... -
ruby 1
. 8 . 4 feature (37.0) -
ruby 1.8.4 feature ruby 1.8.4 での ruby 1.8.3 からの変更点です。
ruby 1.8.4 feature
ruby 1.8.4 での ruby 1.8.3 からの変更点です。
掲載方針
*バグ修正の影響も含めて動作が変わるものを収録する。
*単にバグを直しただけのものは収録しない。
*ライブラリへの単なる定数の追加は収録しない。
以下は各変更点に付けるべきタグです。
記号について(特に重要なものは大文字(主観))
# * カテゴリ
# * [ruby]: ruby インタプリタの変更
# * [api]: 拡張ライブラリ API
# * [lib]: ライブラリ
* レベル
* [bug]: バグ修正
* [new]: 追加され...