るりまサーチ (Ruby 2.5.0)

最速Rubyリファレンスマニュアル検索!
41件ヒット [1-41件を表示] (0.035秒)
トップページ > バージョン:2.5.0[x] > クエリ:y[x] > クエリ:headers[x]

別のキーワード

  1. psych psych_y
  2. kernel y
  3. psych y
  4. kernel psych_y
  5. y kernel

ライブラリ

クラス

モジュール

検索結果

CSV#headers -> Array | true | nil (54676.0)

nil を返した場合は、ヘッダは使用されません。 真を返した場合は、ヘッダを使用するが、まだ読み込まれていません。 配列を返した場合は、ヘッダは既に読み込まれています。

nil を返した場合は、ヘッダは使用されません。
真を返した場合は、ヘッダを使用するが、まだ読み込まれていません。
配列を返した場合は、ヘッダは既に読み込まれています。

//emlist[例][ruby]{
require "csv"

csv = CSV.new("header1,header2\nrow1_1,row1_2")
csv.headers # => nil
csv = CSV.new("header1,header2\nrow1_1,row1_2", headers: true)
csv.headers # => true
csv.read
csv.headers # =>...

CSV::Row#headers -> Array (54622.0)

この行のヘッダのリストを返します。

この行のヘッダのリストを返します。

//emlist[例][ruby]{
require "csv"

row = CSV::Row.new(["header1", "header2"], [1, 2])
row.headers # => ["header1", "header2"]
//}

CSV::Table#headers -> Array (54622.0)

自身のヘッダ行を返します。

自身のヘッダ行を返します。

テーブルが空である場合は空の配列を返します。

//emlist[例][ruby]{
require "csv"

row = CSV::Row.new(["header1", "header2"], ["row1_1", "row1_2"])
table = CSV::Table.new([row])
table.headers # => ["header1", "header2"]
//}

Net::HTTPHeaderSyntaxError (36001.0)

HTTP ヘッダの内容が不正である場合に発生する例外です。

HTTP ヘッダの内容が不正である場合に発生する例外です。

Kernel#find_type(type, opt, *headers) -> Array (18925.0)

静的な型 type がシステムに存在するかどうか検査します。

静的な型 type がシステムに存在するかどうか検査します。

@param type 検査したい型の名前を指定します。

@param opt コンパイラに渡す追加のオプションを指定します。

@param headers 追加のヘッダを指定します。

@see Kernel#have_type

絞り込み条件を変える

Kernel#find_type(type, opt, *headers) { ... } -> Array (18925.0)

静的な型 type がシステムに存在するかどうか検査します。

静的な型 type がシステムに存在するかどうか検査します。

@param type 検査したい型の名前を指定します。

@param opt コンパイラに渡す追加のオプションを指定します。

@param headers 追加のヘッダを指定します。

@see Kernel#have_type

Kernel#have_type(type, headers = nil, opt = "") -> bool (18925.0)

静的な型 type がシステムに存在するかどうか検査します。

静的な型 type がシステムに存在するかどうか検査します。

型 type がシステムに存在する場合は、グローバル変数 $defs に
"-DHAVE_type" を追加し、真を返します。型 type がシステムに存在しない場
合は、偽を返します。

例えば、

require 'mkmf'
have_type('foo') # => true

である場合、HAVE_TYPE_FOO をというプリプロセッサマクロをコンパイラに渡します。

@param type 検査したい型の名前を指定します。

@param headers 追加のヘッダを指定します。

@param opt ...

Kernel#have_type(type, headers = nil, opt = "") { ... } -> bool (18925.0)

静的な型 type がシステムに存在するかどうか検査します。

静的な型 type がシステムに存在するかどうか検査します。

型 type がシステムに存在する場合は、グローバル変数 $defs に
"-DHAVE_type" を追加し、真を返します。型 type がシステムに存在しない場
合は、偽を返します。

例えば、

require 'mkmf'
have_type('foo') # => true

である場合、HAVE_TYPE_FOO をというプリプロセッサマクロをコンパイラに渡します。

@param type 検査したい型の名前を指定します。

@param headers 追加のヘッダを指定します。

@param opt ...

Kernel#have_library(lib, func = nil, headers = nil) -> bool (18625.0)

ライブラリ lib がシステムに存在し、関数 func が定義されているかどうかをチェックします。 チェックが成功すれば $libs に lib を追加し true を返します。 チェックが失敗したら false を返します。

ライブラリ lib がシステムに存在し、関数 func が定義されているかどうかをチェックします。
チェックが成功すれば $libs に lib を追加し true を返します。
チェックが失敗したら false を返します。

@param lib ライブラリの名前を指定します。

@param func 検査する関数名を指定します。
nil または空文字列のときは、"main" になります。

@param headers 追加のヘッダファイルを指定します。

Kernel#have_library(lib, func = nil, headers = nil) { ... } -> bool (18625.0)

ライブラリ lib がシステムに存在し、関数 func が定義されているかどうかをチェックします。 チェックが成功すれば $libs に lib を追加し true を返します。 チェックが失敗したら false を返します。

ライブラリ lib がシステムに存在し、関数 func が定義されているかどうかをチェックします。
チェックが成功すれば $libs に lib を追加し true を返します。
チェックが失敗したら false を返します。

@param lib ライブラリの名前を指定します。

@param func 検査する関数名を指定します。
nil または空文字列のときは、"main" になります。

@param headers 追加のヘッダファイルを指定します。

絞り込み条件を変える

Kernel#try_constant(const, headers = nil, opt = "") -> Integer | nil (18625.0)

定数 const がシステムに存在するかどうか検査します。 Kernel#have_const を使ってください。

定数 const がシステムに存在するかどうか検査します。
Kernel#have_const を使ってください。

@param const C 言語の定数名を指定します。

@param headers 追加のヘッダファイルを指定します。

@param opt コンパイラに渡すオプションを指定します。
$CFLAGS もコンパイラには渡されます。

@return 定数 const がシステムに存在する場合はその値を返します。
定数 const がシステムに存在しない場合は nil を返します。

Kernel#try_constant(const, headers = nil, opt = "") { ... } -> Integer | nil (18625.0)

定数 const がシステムに存在するかどうか検査します。 Kernel#have_const を使ってください。

定数 const がシステムに存在するかどうか検査します。
Kernel#have_const を使ってください。

@param const C 言語の定数名を指定します。

@param headers 追加のヘッダファイルを指定します。

@param opt コンパイラに渡すオプションを指定します。
$CFLAGS もコンパイラには渡されます。

@return 定数 const がシステムに存在する場合はその値を返します。
定数 const がシステムに存在しない場合は nil を返します。

Kernel#try_func(func, libs, headers = nil) -> bool (18625.0)

関数 func がシステムに存在するかどうか検査します。 Kernel#have_func を使ってください。

関数 func がシステムに存在するかどうか検査します。
Kernel#have_func を使ってください。

@param func 関数名を指定します。

@param libs ライブラリの名前を指定します。

@param headers 関数 func を使用するのに必要なヘッダファイル名を指定しま
す。これは関数の型をチェックするためではなく、関数が実際
にはマクロで定義されている場合などのために使用します。

Kernel#try_func(func, libs, headers = nil) { ... } -> bool (18625.0)

関数 func がシステムに存在するかどうか検査します。 Kernel#have_func を使ってください。

関数 func がシステムに存在するかどうか検査します。
Kernel#have_func を使ってください。

@param func 関数名を指定します。

@param libs ライブラリの名前を指定します。

@param headers 関数 func を使用するのに必要なヘッダファイル名を指定しま
す。これは関数の型をチェックするためではなく、関数が実際
にはマクロで定義されている場合などのために使用します。

Kernel#try_static_assert(expr, headers = nil, opt = "") -> bool (18625.0)

@todo ???

@todo ???

...

@param expr C 言語の式を指定します。

@param headers 追加のヘッダファイルを指定します。

@param opt コンパイラに渡すオプションを指定します。
$CFLAGS もコンパイラには渡されます。

絞り込み条件を変える

Kernel#try_static_assert(expr, headers = nil, opt = "") { ... } -> bool (18625.0)

@todo ???

@todo ???

...

@param expr C 言語の式を指定します。

@param headers 追加のヘッダファイルを指定します。

@param opt コンパイラに渡すオプションを指定します。
$CFLAGS もコンパイラには渡されます。

Kernel#try_type(type, headers = nil, opt = "") -> bool (18625.0)

Kernel#have_type を使ってください。

Kernel#have_type を使ってください。

@param type 検査したい型の名前を指定します。

@param headers 追加のヘッダを指定します。

@param opt コンパイラに渡す追加のオプションを指定します。

Kernel#try_type(type, headers = nil, opt = "") { ... } -> bool (18625.0)

Kernel#have_type を使ってください。

Kernel#have_type を使ってください。

@param type 検査したい型の名前を指定します。

@param headers 追加のヘッダを指定します。

@param opt コンパイラに渡す追加のオプションを指定します。

Kernel#try_var(var, headers = nil) -> bool (18625.0)

Kernel#have_var を使ってください。

Kernel#have_var を使ってください。

@param var 検査したい変数名を指定します。

@param headers 追加のヘッダを指定します。

Kernel#try_var(var, headers = nil) { ... } -> bool (18625.0)

Kernel#have_var を使ってください。

Kernel#have_var を使ってください。

@param var 検査したい変数名を指定します。

@param headers 追加のヘッダを指定します。

絞り込み条件を変える

CSV::Table#empty? -> bool (18319.0)

ヘッダーを除いて、データがないときに true を返します。

ヘッダーを除いて、データがないときに true を返します。

Array#empty? に委譲しています。

//emlist[][ruby]{
require 'csv'
csv = CSV.new("a,b\n", headers: true)
table = csv.read
p table.empty? # => true
table << [1, 2]
p table.empty? # => false
//}

@see Array#empty?

Kernel#check_signedness(type, headers = nil, opts = nil) -> "signed" | "unsigned" | nil (655.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 (655.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#convertible_int(type, headers = nil, opts = nil) (655.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) { ... } (655.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...

絞り込み条件を変える

CSV::Row#fields(*headers_and_or_indices) -> Array (643.0)

与えられた引数に対応する値の配列を返します。

与えられた引数に対応する値の配列を返します。

要素の探索に CSV::Row.field を使用しています。

@param headers_and_or_indices ヘッダの名前かインデックスか Range
のインスタンスか第 1 要素がヘッダの名前で
第 2 要素がオフセットになっている 2 要素
の配列をいくつでも指定します。混在するこ
とがで...

CSV::Row#values_at(*headers_and_or_indices) -> Array (643.0)

与えられた引数に対応する値の配列を返します。

与えられた引数に対応する値の配列を返します。

要素の探索に CSV::Row.field を使用しています。

@param headers_and_or_indices ヘッダの名前かインデックスか Range
のインスタンスか第 1 要素がヘッダの名前で
第 2 要素がオフセットになっている 2 要素
の配列をいくつでも指定します。混在するこ
とがで...

Kernel#check_sizeof(type, headers = nil) -> Integer | nil (625.0)

与えられた型のサイズを返します。

与えられた型のサイズを返します。

型 type がシステムに存在する場合は、グローバル変数 $defs に
"-DSIZEOF_type=X" を追加し、型のサイズを返します。型 type がシステムに
存在しない場合は、nil を返します。

例えば、

require 'mkmf'
check_sizeof('mystruct') # => 12

である場合、SIZEOF_MYSTRUCT=12 というプリプロセッサマクロをコンパイラに渡します。

@param type 検査したい型を指定します。

@param headers 追加のヘッダファイルを指定します。

Kernel#check_sizeof(type, headers = nil) { ... } -> Integer | nil (625.0)

与えられた型のサイズを返します。

与えられた型のサイズを返します。

型 type がシステムに存在する場合は、グローバル変数 $defs に
"-DSIZEOF_type=X" を追加し、型のサイズを返します。型 type がシステムに
存在しない場合は、nil を返します。

例えば、

require 'mkmf'
check_sizeof('mystruct') # => 12

である場合、SIZEOF_MYSTRUCT=12 というプリプロセッサマクロをコンパイラに渡します。

@param type 検査したい型を指定します。

@param headers 追加のヘッダファイルを指定します。

Kernel#have_struct_member(type, member, headers = nil) -> bool (625.0)

member というメンバを持つ構造体 type がシステムに存在するかどうか検査します。

member というメンバを持つ構造体 type がシステムに存在するかどうか検査します。

member というメンバを持つ構造体 type がシステムに存在する場合は、
グローバル変数 $defs に "-DHAVE_type_member" を追加し、真を返します。
member というメンバを持つ構造体 type が存在しない場合は、偽を返します。

例えば

require 'mkmf'
have_struct_member('struct foo', 'bar') # => true

である場合、HAVE_STRUCT_FOO_BAR というプリプロセッサマクロをコンパ...

絞り込み条件を変える

Kernel#have_struct_member(type, member, headers = nil) { ... } -> bool (625.0)

member というメンバを持つ構造体 type がシステムに存在するかどうか検査します。

member というメンバを持つ構造体 type がシステムに存在するかどうか検査します。

member というメンバを持つ構造体 type がシステムに存在する場合は、
グローバル変数 $defs に "-DHAVE_type_member" を追加し、真を返します。
member というメンバを持つ構造体 type が存在しない場合は、偽を返します。

例えば

require 'mkmf'
have_struct_member('struct foo', 'bar') # => true

である場合、HAVE_STRUCT_FOO_BAR というプリプロセッサマクロをコンパ...

CSV::Table#values_at(indices_or_headers) -> Array (604.0)

デフォルトのミックスモードでは、インデックスのリストを与えると行単位の 参照を行い、行の配列を返します。他の方法は列単位の参照と見なします。行 単位の参照では、返り値は行ごとの配列を要素に持つ配列です。

デフォルトのミックスモードでは、インデックスのリストを与えると行単位の
参照を行い、行の配列を返します。他の方法は列単位の参照と見なします。行
単位の参照では、返り値は行ごとの配列を要素に持つ配列です。

探索方法を変更したい場合は CSV::Table#by_col!,
CSV::Table#by_row! を使用してください。

アクセスモードを混在させることはできません。

//emlist[例 ロウモード][ruby]{
require "csv"

row1 = CSV::Row.new(["header1", "header2"], ["row1_1", "row1_2"])
r...

CSV#read -> [Array] | CSV::Table (403.0)

残りの行を読み込んで配列の配列を返します。 self の生成時に headers オプションに偽でない値が指定されていた場合は CSV::Table オブジェクトを返します。

残りの行を読み込んで配列の配列を返します。
self の生成時に headers オプションに偽でない値が指定されていた場合は CSV::Table オブジェクトを返します。

データソースは読み込み用にオープンされている必要があります。

//emlist[例 headers: false][ruby]{
require "csv"

csv = CSV.new(DATA.read)
csv.read
# => [["header1", "header2"], ["row1_1", "row1_2"], ["row2_1", "row2_2"]]

__END__
header1,head...

CSV#readlines -> [Array] | CSV::Table (403.0)

残りの行を読み込んで配列の配列を返します。 self の生成時に headers オプションに偽でない値が指定されていた場合は CSV::Table オブジェクトを返します。

残りの行を読み込んで配列の配列を返します。
self の生成時に headers オプションに偽でない値が指定されていた場合は CSV::Table オブジェクトを返します。

データソースは読み込み用にオープンされている必要があります。

//emlist[例 headers: false][ruby]{
require "csv"

csv = CSV.new(DATA.read)
csv.read
# => [["header1", "header2"], ["row1_1", "row1_2"], ["row2_1", "row2_2"]]

__END__
header1,head...

CSV.read(path, options = Hash.new) -> [Array] | CSV::Table (367.0)

CSV ファイルを配列の配列にするために使います。 headers オプションに偽でない値を指定した場合は CSV::Table オブジェクトを返します。

CSV ファイルを配列の配列にするために使います。
headers オプションに偽でない値を指定した場合は CSV::Table オブジェクトを返します。

@param path CSV ファイルのパスを指定します。

@param options CSV.new のオプションと同じオプションを指定できます。
:encoding というキーを使用すると入力のエンコーディングを指定することができます。
入力のエンコーディングか Encoding.default_external と異なる場合は
必ず指定...

絞り込み条件を変える

CSV.readlines(path, options = Hash.new) -> [Array] | CSV::Table (367.0)

CSV ファイルを配列の配列にするために使います。 headers オプションに偽でない値を指定した場合は CSV::Table オブジェクトを返します。

CSV ファイルを配列の配列にするために使います。
headers オプションに偽でない値を指定した場合は CSV::Table オブジェクトを返します。

@param path CSV ファイルのパスを指定します。

@param options CSV.new のオプションと同じオプションを指定できます。
:encoding というキーを使用すると入力のエンコーディングを指定することができます。
入力のエンコーディングか Encoding.default_external と異なる場合は
必ず指定...

URI::MailTo.build(ary) -> URI::MailTo (355.0)

引数で与えられた URI 構成要素から URI::MailTo オブジェクトを生成します。 引数の正当性をチェックします。

引数で与えられた URI 構成要素から URI::MailTo オブジェクトを生成します。
引数の正当性をチェックします。

@param ary 構成要素を
[to, headers]
という文字列の配列で与えます。headers は、以下のような文字列か配列で
与えます。
"subject=subscribe&cc=addr"

[["subject", "subscribe"], ["cc", "addr"]]

@param hash 構成要素をハッシュで与えます。ハッシュのキーは :to, :headers です。ハッシュの値は ary と同様です。

@r...

CSV#header_converters -> Array (319.0)

現在有効なヘッダ用変換器のリストを返します。

現在有効なヘッダ用変換器のリストを返します。

組込みの変換器は名前を返します。それ以外は、オブジェクトを返します。

//emlist[例][ruby]{
require "csv"

csv = CSV.new("HEADER1,HEADER2\nrow1_1,row1_2", headers: true, header_converters: CSV::HeaderConverters.keys)
csv.header_converters # => [:downcase, :symbol]
csv.read.to_a # => header2], ["row1_1",...

CSV.parse(str, options = Hash.new) -> Array (319.0)

このメソッドは文字列を簡単にパースすることができます。 ブロックを与えた場合は、ブロックにそれぞれの行を渡します。 ブロックを省略した場合は、配列の配列を返します。

このメソッドは文字列を簡単にパースすることができます。
ブロックを与えた場合は、ブロックにそれぞれの行を渡します。
ブロックを省略した場合は、配列の配列を返します。

@param str 文字列を指定します。

@param options CSV.new のオプションと同じオプションを指定できます。

//emlist[例][ruby]{
require 'csv'
require 'pp'

s = <<EOS
id,first name,last name,age
1,taro,tanaka,20
2,jiro,suzuki,18
EOS

pp CSV.parse(s)
# => ...

CSV.table(path, options = Hash.new) -> CSV::Table | [Array] (319.0)

以下と同等のことを行うメソッドです。

以下と同等のことを行うメソッドです。

//emlist[][ruby]{
CSV.read( path, { headers: true,
converters: :numeric,
header_converters: :symbol }.merge(options) )
//}

@param path ファイル名を指定します。

@param options CSV.new のオプションと同じオプションを指定できます。


@see CSV.read

絞り込み条件を変える

URI::Generic.component -> [Symbol] (319.0)

URI の構成要素を表すシンボルの配列を返します。

URI の構成要素を表すシンボルの配列を返します。

require 'uri'
p URI::Generic.component
p URI::MailTo.component

# => [:scheme, :userinfo, :host, :port, :registry, :path, :opaque, :query, :fragment]
# => [:scheme, :to, :headers]