るりまサーチ

最速Rubyリファレンスマニュアル検索!
70件ヒット [1-70件を表示] (0.030秒)
トップページ > クエリ:File[x] > クエリ:print[x] > 種類:文書[x]

別のキーワード

  1. _builtin file?
  2. _builtin file
  3. file lstat
  4. file atime
  5. file size

検索結果

1.6.8から1.8.0への変更点(まとめ) (373.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への変更点(まとめ)/サポートプラットフォームの追加>))

...り、(({$?})) の値も整数からこのクラ
スのインスタンスになりました。

=== クラス階層

: ((<File::Constants>))

File
::Constants は、File クラスでなく IO クラスが include するように
なりました。((<ruby-dev:20964>))

: ((<UnboundMethod>)) [com...
...。($deferr はすぐに obsolete に
なりました。$stderr を使ってください)

=== ARGF

: ((<ARGF/ARGF.path>)) [new]

追加 (ARGF.filename の別名) ((<ruby-dev:20197>))

=== Array

: ((<Array#transpose|Array/transpose>)) [new]

追加

: ((<Array#zip|Enumerable/zip>)) [new]
: (...
...(<Enumerable#inject|Enumerable/inject>)) [new]
追加

=== File

: ((<File/File.extname>)) [new]

追加。ファイル名の拡張子を返します。((<ruby-talk:37617>))

: ((<File/File.fnmatch>)) [new]
: ((<File/File.fnmatch?>)) [new]
追加

このメソッドで使用す...

ruby 1.6 feature (199.0)

ruby 1.6 feature ruby version 1.6 は安定版です。この版での変更はバグ修正がメイン になります。

...ったため、enq などを
呼び出したときスーパークラス Queue の enq が実行されていました。

: 2002-09-11: ((<tempfile/Tempfile#size>))

追加 ((<ruby-dev:17221>))

: 2002-09-09

mswin32 版と mingw32 版の ruby で、1.6.6の頃から ruby の子プロセスに...
...by-dev:18145>))

: 2002-08-20 File.expand_path

Cygwin 1.3.x ((<ruby-bugs-ja:PR#299>))

p File.expand_path('file', 'c:/')

=> ruby 1.6.7 (2002-03-01) [i586-linux]
/tmp/c:/file
=> ruby 1.6.7 (2002-08-21) [i586-linux]
c:/file

: 2002-08-19 Thread (win)...
...-03-01) [i586-linux]
true
=> ruby 1.6.7 (2002-08-21) [i586-linux]
false

# : 2002-08-01 IO#read, gets ..., etc.
#
# File::NONBLOCK を指定した IO の読み込みで EWOULDBLOCK が発生すると、
# 途中まで読んだデータが失われることがあ...

クラス/メソッドの定義 (91.0)

クラス/メソッドの定義 * クラス/メソッドの定義: * class * singleton_class * module * method * operator * nest_method * eval_method * singleton_method * class_method * limit * 定義に関する操作: * alias * undef * defined

... File::Constants を include することで、
# File::RDONLY などと書かずに直接 RDONLY と書くことができる。
class File
module Constants
RDONLY = 0
WRONLY = 1
end
include Constants
end

File
.open("foo", File::RDONLY)

# あるいは

include File::Constants
File
.ope...
...n("foo", RDONLY)

# 上記はあくまでも例である。実際の File.open ではより簡便な
# File.open("foo", "r") という形式が使われる
//}

クラス定義式は、最後に評価した式の結果を返します。最後に評価した式
が値を返さない場合は nil を...
...][ruby]{
def foo(cnt, &block_arg)
cnt.times { block_arg.call } # ブロックに収まったProcオブジェクトはcallで実行
end
foo(3) { print "Ruby! " } #=> Ruby! Ruby! Ruby!
//}

メソッド定義において、仮引数はその種類毎に以下の順序でしか指定すること
...

制御構造 (85.0)

制御構造 条件分岐: * if * unless * case 繰り返し: * while * until * for * break * next * redo * retry 例外処理: * raise * begin その他: * return * BEGIN * END

...クラス設計者が定義する事が出来るものです.

=== 条件分岐
====[a:if] if

//emlist[例][ruby]{
if age >= 12 then
print
"adult fee\n"
else
print
"child fee\n"
end
gender = if foo.gender == "male" then "male" else "female" end
//}

文法:

if 式 [then]...
...には特別に

//emlist[][ruby]{
$_ =~ リテラル
//}

であるかのように評価されます。

==== if 修飾子

//emlist[例][ruby]{
print
"debug\n" if $DEBUG
//}

文法:

式 if 式

右辺の条件が成立する時に、左辺の式を評価してその結果を返しま...
...then 以下の
式を評価します。unless 式にelsif を指定することはできませ
ん。

==== unless 修飾子

//emlist[例][ruby]{
print
"stop\n" unless valid(passwd)
//}

文法:

式 unless 式

右辺の条件が成立しない時に、左辺の式を評価してその...

ruby 1.8.3 feature (79.0)

ruby 1.8.3 feature *((<ruby 1.8 feature>)) *((<ruby 1.8.2 feature>))

...=== 2005-09-19
: FileUtils.remove_entry_secure [lib] [new]
: FileUtils.remove_entry [lib] [new]
: FileUtils.chmod_R [lib] [new]
: FileUtils.chown [lib] [new]
: FileUtils.chown_R [lib] [new]
: FileUtils.commands [lib] [new]
: FileUtils.options...
...[lib] [new]
: FileUtils.have_option? [lib] [new]
: FileUtils.options_of [lib] [new]
: FileUtils.collect_method [lib] [new]

追加。

: FileUtils.rm_r [lib] [compat]
: FileUtils.rm_rf [lib] [compat]
: FileUtils.cd [lib] [compat]
: FileUtils.cp_r [lib] [compat]...
...: File.join [ruby] [compat]

型チェックを厳密にするようになりました。

$ ruby-1.8.2 -e 'p File.join(1, 2)'
"1/2"

$ ruby-1.8.3 -e 'p File.join(1, 2)'
-e:1:in `join': can't convert Fixnum into String (TypeError)
from -e:1

=== 2005-09-16
: File.e...

絞り込み条件を変える

ruby 1.8.5 feature (55.0)

ruby 1.8.5 feature ruby 1.8.4 から ruby 1.8.5 までの変更点です。

...o_xml [new]

こんな風にすると、RSS 1.0からRSS 2.0に変換できます。

rss10 = RSS::Parser.parse(File.read("1.0.rdf"))
File
.open("2.0.rss", "w") {|f| f.print(rss10.to_xml("2.0"))}

((<ruby-talk:197284>))

: RSS::VERSION

"0.1.5"から"0.1.6"になりました。

=== 20...
...RLIMIT_FSIZE
: Process::RLIMIT_NOFILE
: Process::RLIMIT_STACK
: Process::RLIMIT_AS
: Process::RLIMIT_MEMLOCK
: Process::RLIMIT_NPROC
: Process::RLIMIT_RSS
: Process::RLIMIT_SBSIZE

追加 ((<ruby-dev:28729>))

=== 2006-06-11

: OptionParser#getopts [new]

: tempfile の生成するテンポラリ...
...= 2006-02-21
: File#link [bug]

mswin32版・mingw32版でFile#linkが動かなくなっていた不具合が修正されました。

=== 2006-02-20

: RbConfig [new]

((<rbconfig>)) が Config に加えて RbConfig を定義するようになりました。

=== 2006-02-06

: File#flock [bug]...

NEWS for Ruby 3.0.0 (25.0)

NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。

...e each second element
# => ["data1", "data2", "data3"]
//}

* Binding
* Binding#eval when called with one argument will use `"(eval)"` for `__FILE__` and `1` for `__LINE__` in the evaluated code. 4352 17419
* ConditionVariable
* ConditionVariable#wait may now invoke the `block`/`unblock`...
..., and will return a frozen copy even if the receiver is unfrozen. 16175
* Kernel#eval when called with two arguments will use `"(eval)"` for `__FILE__` and `1` for `__LINE__` in the evaluated code. 4352
* Kernel#lambda now warns if called without a literal block. 15973
* Kernel.sleep inv...
...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.
*...