るりまサーチ

最速Rubyリファレンスマニュアル検索!
1623件ヒット [101-200件を表示] (0.130秒)

別のキーワード

  1. _builtin to_s
  2. openssl to_der
  3. openssl to_s
  4. _builtin to_a
  5. openssl to_pem

ライブラリ

モジュール

キーワード

検索結果

<< < 1 2 3 4 ... > >>

NilClass#to_a -> Array (18108.0)

空配列 [] を返します。

...空配列 [] を返します。

//emlist[例][ruby]{
nil.to_a #=> []
//}...

OpenSSL::X509::Name#to_a -> [[String, String, Integer]] (18108.0)

内容を配列にして返します。

...ssl'
n = OpenSSL::X509::Name.parse('/C=JP/ST=Kanagawa/L=Yokohama/O=Example Company/OU=Lab3/CN=foobar/emailAddress=foobar@lab3.example.co.jp')
n.to_a
# => [["C", "JP", 19], ["ST", "Kanagawa", 12], ["L", "Yokohama", 12], ["O", "Example Company", 12], ["OU", "Lab3", 12], ["CN", "foobar", 12], ["e...

OptionParser#to_a -> [String] (18108.0)

サマリの各行を要素とした配列を返します。

...を返します。

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

opts = OptionParser.new do |opts|
opts.on_head("-i", "--init")
opts.on("-u", "--update")
opts.on_tail("-h", "--help")
end

opts.to_a # => ["Usage: test [options]", " -i, --init\n", " -u, --update\n", " -h, --help\n"]
//}...

REXML::Attributes#to_a -> [Attribute] (18108.0)

属性の配列を返します。

...属性の配列を返します。

//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new("<a x='1' y='2' z='3' />")
doc.root.attributes.to_a # => [x='1', y='2', z='3']
//}...

Rake::FileList#to_a -> Array (18108.0)

内部的な配列を返します。

...内部的な配列を返します。

//emlist[][ruby]{
# Rakefile での記載例とする

task default: :test_rake_app
task :test_rake_app do
file_list = FileList['a.c', 'b.c']
file_list.to_a # => ["a.c", "b.c"]
end
//}...

絞り込み条件を変える

RubyVM::InstructionSequence#to_a -> Array (18108.0)

self の情報を 14 要素の配列にして返します。

...令とオペランドの配列の配列。


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

iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
pp iseq.to_a
# ※ Ruby 2.5.0 での実行結果
# => ["YARVInstructionSequence/SimpleDataFormat",
# 2,
# 0,
# 1,
# {:arg_size=>0, :local_size=>2, :stack_max=>2},...

SDBM#to_a -> [[String]] (18108.0)

self の各要素を格納した配列を返します。

...

返される配列の1つの要素は [key, value] です。
つまり配列の配列を返します。

require 'sdbm'

db1 = SDBM.open('aaa.gdbm', 0666)
db1.clear
db1['a'] = 'aaa'
db1['b'] = 'bbb'
db1['c'] = 'ccc'

p db1.to_a #=> [["a", "aaa"], ["b", "bbb"], ["c", "ccc"]]...

Set#to_a -> Array (18108.0)

self を配列に変換します。要素の順序は不定です。

...self を配列に変換します。要素の順序は不定です。

//emlist[][ruby]{
require 'set'
set = Set['hello', 'world']
p set.to_a # => ["hello", "world"]
//}...
...self を配列に変換します。要素の順序は不定です。

//emlist[][ruby]{
set = Set['hello', 'world']
p set.to_a # => ["hello", "world"]
//}...

Shell::Filter#to_a -> [String] (18108.0)

実行結果を文字列の配列で返します。

...実行結果を文字列の配列で返します。

require 'shell'
Shell.def_system_command("wc")
sh = Shell.new
puts sh.cat("/etc/passwd").to_a...

Struct#to_a -> [object] (18108.0)

構造体のメンバの値を配列にいれて返します。

...れて返します。

//emlist[例][ruby]{
Customer = Struct.new(:name, :address, :zip)
Customer.new("Joe Smith", "123 Maple, Anytown NC", 12345).to_a
# => ["Joe Smith", "123 Maple, Anytown NC", 12345]
//}

[注意] 本メソッドの記述は Struct の下位クラスのインスタンスに対し...

絞り込み条件を変える

<< < 1 2 3 4 ... > >>