種類
- 特異メソッド (44)
- インスタンスメソッド (33)
- 文書 (26)
- クラス (11)
ライブラリ
- csv (44)
-
rexml
/ document (11) - stringio (33)
キーワード
-
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (11) -
NEWS for Ruby 3
. 0 . 0 (4) - Transitive (11)
- open (44)
- printf (11)
-
ruby 1
. 8 . 3 feature (11)
検索結果
先頭5件
-
StringIO
# print() -> nil (39136.0) -
自身に引数を順に出力します。引数を省略した場合は、$_ を出力します。 引数の扱いは Kernel.#print を参照して下さい。
...は Kernel.#print を参照して下さい。
@param obj 書き込みたいオブジェクトを指定します。
@raise IOError 自身が書き込み用にオープンされていなければ発生します。
//emlist[例][ruby]{
require "stringio"
a = StringIO.new("", 'r+')
a.print("hoge", "b... -
StringIO
# print(*obj) -> nil (39136.0) -
自身に引数を順に出力します。引数を省略した場合は、$_ を出力します。 引数の扱いは Kernel.#print を参照して下さい。
...は Kernel.#print を参照して下さい。
@param obj 書き込みたいオブジェクトを指定します。
@raise IOError 自身が書き込み用にオープンされていなければ発生します。
//emlist[例][ruby]{
require "stringio"
a = StringIO.new("", 'r+')
a.print("hoge", "b... -
StringIO
# printf(format , *obj) -> nil (27112.0) -
指定されたフォーマットに従い各引数 obj を文字列に変換して、自身に出力します。
...書き込みたいオブジェクトを指定します。
@raise IOError 自身が書き込み用にオープンされていなければ発生します。
//emlist[例][ruby]{
require "stringio"
a = StringIO.new("", 'r+')
a.printf("%c%c%c", 97, 98, 99)
a.string #=> "abc"
//}... -
ruby 1
. 8 . 3 feature (30.0) -
ruby 1.8.3 feature *((<ruby 1.8 feature>)) *((<ruby 1.8.2 feature>))
...ーディングは要素の内部エンコーディングからoutput_encoding=で設定したエンコーディングへ変換されます。
: StringIO [lib] [compat]
close, close_read, close_write が ((<IO>)) と同じように、
nil を返すようになりました。((<ruby-dev:25623>))......として
ruby 1.8.3 に IO#((<IO/readpartial>)) が追加されました。
((<ruby-dev:25430>)) ((<ruby-dev:25443>))
$ ruby -e 'sleep 1; print "hoge"' | ruby-1.8.2 -rio/nonblock -we '
io = IO.open(0)
io.no......p io.read(4)'
-e:4:in `read': Resource temporarily unavailable (Errno::EAGAIN)
from -e:4
$ ruby -e 'sleep 1; print "hoge"' | ruby-1.8.3 -rio/nonblock -we '
io = IO.open(0)
io.no... -
NEWS for Ruby 3
. 0 . 0 (18.0) -
NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...and Net::HTTP#verify_hostname have been added to skip hostname verification. 16555
* Net::HTTP.get, Net::HTTP.get_response, and Net::HTTP.get_print can take the request headers as a Hash in the second argument when the first argument is a URI. 16686
* Net::SMTP
* Add SNI support.
*.......3.0
* This version is Ractor compatible.
* Reline
* Update to Reline 0.1.5
* RubyGems
* Update to RubyGems 3.2.3
* StringIO
* Update to StringIO 3.0.0
* This version is Ractor compatible.
* StringScanner
* Update to StringScanner 3.0.0
* This version is Ractor co......erb
* find
* net-ftp
* net-http
* net-imap
* net-protocol
* open-uri
* optparse
* pp
* prettyprint
* resolv-replace
* resolv
* rinda
* set
* securerandom
* shellwords
* tempfile
* tmpdir
* ti... -
REXML
:: Formatters :: Transitive (18.0) -
XMLドキュメントをテキストの内容を変えずに 多少の整形を加えて出力するクラスです。
...S
transitive_formatter = REXML::Formatters::Transitive.new
output = StringIO.new
transitive_formatter.write(doc, output)
output.string
# => "<root\n><children\n >\n<grandchildren foo='bar'\n />\n</children\n ></root\n>\n"
print output.string
# >> <root
# >> ><children
# >> >
# >> <grandchild......ren foo='bar'
# >> />
# >> </children
# >> ></root
# >> >
output = StringIO.new
transitive_formatter.write(REXML::XPath.first(doc, "/root/children"), output)
output.string
# => "<children\n>\n<grandchildren foo='bar'\n />\n</children\n>"
//}... -
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (12.0) -
1.6.8から1.8.0への変更点(まとめ) * ((<1.6.8から1.8.0への変更点(まとめ)/インタプリタの変更>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加されたクラス/モジュール>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加されたメソッド>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加された定数>)) * ((<1.6.8から1.8.0への変更点(まとめ)/拡張されたクラス/メソッド(互換性のある変更)>)) * ((<1.6.8から1.8.0への変更点(まとめ)/変更されたクラス/メソッド(互換性のない変更)>)) * ((<1.6.8から1.8.0への変更点(まとめ)/文法の変更>)) * ((<1.6.8から1.8.0への変更点(まとめ)/正規表現>)) * ((<1.6.8から1.8.0への変更点(まとめ)/Marshal>)) * ((<1.6.8から1.8.0への変更点(まとめ)/Windows 対応>)) * ((<1.6.8から1.8.0への変更点(まとめ)/廃止された(される予定の)機能>)) * ((<1.6.8から1.8.0への変更点(まとめ)/ライブラリ>)) * ((<1.6.8から1.8.0への変更点(まとめ)/拡張ライブラリAPI>)) * ((<1.6.8から1.8.0への変更点(まとめ)/バグ修正>)) * ((<1.6.8から1.8.0への変更点(まとめ)/サポートプラットフォームの追加>))
...。
((<ruby-dev:14172>))
== 拡張されたクラス/メソッド(互換性のある変更)
=== 組み込み関数
: ((<組み込み関数/sprintf>)) [new]
"%p" が追加されました。inspect の結果が利用されます。((<RCR#69>))
: ((<組み込み関数/trap>)) [compat]
あ......e Twister|URL:http://www.math.keio.ac.jp/~matumoto/mt.html>))
を使用するようになりました。
: ((<組み込み関数/sprintf>))('%u') [compat]
sprintf の '%u' で、最上位ビットの繰り返しをあらわす ".." は、付加
されないようになりました。((<ruby......ew]
追加
: 添付ライブラリ [lib] [new]
以下のライブラリが新たに追加されました。
((<iconv>)), ((<tsort>)), ((<StringIO>)), ((<strscan>)),
((<fileutils>)), racc/*
: ((<benchmark>)) [new]
added
: Curses [lib] [compat]
Updated. New methods and consta... -
CSV
. open(filename , mode = "rb" , options = Hash . new) -> CSV (12.0) -
このメソッドは IO オブジェクトをオープンして CSV でラップします。 これは CSV ファイルを書くための主要なインターフェイスとして使うことを意図しています。
...sync
* IO#internal_encoding
* IO#ioctl
* IO#isatty
* File#path
* IO#pid
* IO#pos
* IO#pos=
* IO#reopen
* IO#seek
* IO#stat
* StringIO#string
* IO#sync
* IO#sync=
* IO#tell
* IO#to_i
* IO#to_io
* File#truncate
* IO#tty?
@param filename ファイル名を指定し......["1", "taro", "tanaka", "20"]
csv << ["2", "jiro", "suzuki", "18"]
csv << ["3", "ami", "sato", "19"]
csv << ["4", "yumi", "adachi", "21"]
end
print File.read("test.csv")
# => id,first name,last name,age
# 1,taro,tanaka,20
# 2,jiro,suzuki,18
# 3,ami,sato,19
# 4,yumi,adachi,21
//}... -
CSV
. open(filename , mode = "rb" , options = Hash . new) {|csv| . . . } -> nil (12.0) -
このメソッドは IO オブジェクトをオープンして CSV でラップします。 これは CSV ファイルを書くための主要なインターフェイスとして使うことを意図しています。
...sync
* IO#internal_encoding
* IO#ioctl
* IO#isatty
* File#path
* IO#pid
* IO#pos
* IO#pos=
* IO#reopen
* IO#seek
* IO#stat
* StringIO#string
* IO#sync
* IO#sync=
* IO#tell
* IO#to_i
* IO#to_io
* File#truncate
* IO#tty?
@param filename ファイル名を指定し......["1", "taro", "tanaka", "20"]
csv << ["2", "jiro", "suzuki", "18"]
csv << ["3", "ami", "sato", "19"]
csv << ["4", "yumi", "adachi", "21"]
end
print File.read("test.csv")
# => id,first name,last name,age
# 1,taro,tanaka,20
# 2,jiro,suzuki,18
# 3,ami,sato,19
# 4,yumi,adachi,21
//}... -
CSV
. open(filename , options = Hash . new) -> CSV (12.0) -
このメソッドは IO オブジェクトをオープンして CSV でラップします。 これは CSV ファイルを書くための主要なインターフェイスとして使うことを意図しています。
...sync
* IO#internal_encoding
* IO#ioctl
* IO#isatty
* File#path
* IO#pid
* IO#pos
* IO#pos=
* IO#reopen
* IO#seek
* IO#stat
* StringIO#string
* IO#sync
* IO#sync=
* IO#tell
* IO#to_i
* IO#to_io
* File#truncate
* IO#tty?
@param filename ファイル名を指定し......["1", "taro", "tanaka", "20"]
csv << ["2", "jiro", "suzuki", "18"]
csv << ["3", "ami", "sato", "19"]
csv << ["4", "yumi", "adachi", "21"]
end
print File.read("test.csv")
# => id,first name,last name,age
# 1,taro,tanaka,20
# 2,jiro,suzuki,18
# 3,ami,sato,19
# 4,yumi,adachi,21
//}...