275件ヒット
[1-100件を表示]
(0.016秒)
種類
- インスタンスメソッド (72)
- ライブラリ (72)
- 文書 (59)
- 変数 (36)
- クラス (36)
クラス
-
Encoding
:: UndefinedConversionError (12) - OptionParser (24)
-
WIN32OLE
_ TYPELIB (36)
モジュール
- Kernel (36)
キーワード
-
$ -I (12) -
$ : (12) -
$ LOAD _ PATH (12) -
NEWS for Ruby 2
. 0 . 0 (12) -
NEWS for Ruby 2
. 7 . 0 (6) -
NEWS for Ruby 3
. 0 . 0 (5) - Request (12)
- Rubyの起動 (12)
- UndefinedConversionError (12)
-
WIN32OLE
_ TYPELIB (12) -
error
_ char (12) -
major
_ version (12) -
minor
_ version (12) -
net
/ imap (12) -
net
/ pop (12) -
on
_ tail (12) - optparse (12)
- rake (12)
- rss (12)
-
ruby 1
. 6 feature (12) -
ruby 1
. 8 . 3 feature (12) - ver (12)
- yaml (12)
検索結果
先頭5件
-
WIN32OLE
_ TYPELIB # version -> Float (18113.0) -
TypeLibのバージョン番号を取得します。
...号、小数点
数部にマイナーバージョン番号を設定したFloatで返します。
@raise WIN32OLERuntimeError TypeLibの属性が読み取れない場合に通知します。
tlib = WIN32OLE_TYPELIB.new('Microsoft Excel 14.0 Object Library')
puts tlib.version # => 1.7... -
WIN32OLE
_ TYPELIB # major _ version -> Integer (6113.0) -
TypeLibのメジャーバージョン番号を取得します。
...取得します。
@return TypeLibのメジャーバージョン番号を整数で返します。
@raise WIN32OLERuntimeError TypeLibの属性が読み取れない場合に通知します。
tlib = WIN32OLE_TYPELIB.new('Microsoft Excel 14.0 Object Library')
puts tlib.major_version # => 1... -
WIN32OLE
_ TYPELIB # minor _ version -> Integer (6113.0) -
TypeLibのマイナーバージョン番号を取得します。
...取得します。
@return TypeLibのマイナーバージョン番号を整数で返します。
@raise WIN32OLERuntimeError TypeLibの属性が読み取れない場合に通知します。
tlib = WIN32OLE_TYPELIB.new('Microsoft Excel 14.0 Object Library')
puts tlib.minor_version # => 7... -
Encoding
:: UndefinedConversionError (6006.0) -
エンコーディング変換後の文字が存在しない場合に発生する例外。
...-JP に変換しようとした場合などに発生します。
//emlist[例][ruby]{
"\u2603".encode(Encoding::EUC_JP)
#=> Encoding::UndefinedConversionError: U+2603 from UTF-8 to EUC-JP
//}
変換が多段階でなされ、その途中で例外が生じた場合は、
例外オブジェクト......-JP.
rescue Encoding::UndefinedConversionError
p $!.source_encoding #=> #<Encoding:UTF-8>
p $!.destination_encoding #=> #<Encoding:EUC-JP>
p $!.source_encoding_name #=> "UTF-8"
p $!.destination_encoding_name #=> "EUC-JP"
puts $!.error_char.dump #=> "\u{a0}... -
Encoding
:: UndefinedConversionError # error _ char -> String (3006.0) -
エラーを発生させた1文字を文字列で返します。
...エラーを発生させた1文字を文字列で返します。
//emlist[例][ruby]{
ec = Encoding::Converter.new("UTF-8", "EUC-JP")
begin
ec.convert("\u{a0}")
rescue Encoding::UndefinedConversionError
puts $!.error_char.dump #=> "\u{a0}"
end
//}... -
optparse (90.0)
-
コマンドラインのオプションを取り扱うためのライブラリです。
...プ
デフォルトで --help と --version オプションを認識します。
ruby ./sample.rb --help
# => Usage: sample [options]
ruby ./sample.rb --version
# => *出力なし*
--version は、トップレベルに Version 定数が定義されていると出......す。
(優先度は低いが VERSION 定数も参照します。Ruby のバージョンを示す VERSION
定数が ruby 1.8 までは定義されているので注意)
//emlist[][ruby]{
require 'optparse'
opt = OptionParser.new
Version = "1.2.3" # opt.version = "1.2.3"
opt.parse!(ARGV)
//}......nParser.new
parser.on('-i') { puts "-i" }
parser.on('-o') { puts '-o' }
subparsers = Hash.new {|h,k|
$stderr.puts "no such subcommand: #{k}"
exit 1
}
subparsers['add'] = OptionParser.new.on('-i') { puts "add -i" }
subparsers['del'] = OptionParser.new.on('-i') { puts "del -i" }
subparsers['list'... -
ruby 1
. 6 feature (88.0) -
ruby 1.6 feature ruby version 1.6 は安定版です。この版での変更はバグ修正がメイン になります。
...ruby 1.6 feature
ruby version 1.6 は安定版です。この版での変更はバグ修正がメイン
になります。
((<stable-snapshot|URL:ftp://ftp.netlab.co.jp/pub/lang/ruby/stable-snapshot.tar.gz>)) は、日々更新される安定版の最新ソースです。
== 1.6.8 (2002-12-24) ->......Integer>)) と同じ規則を
使用するようになりました。
p sprintf("%d", nil)
=> -:1:in `sprintf': no implicit conversion from nil (TypeError)
from -:1
ruby 1.6.7 (2002-03-01) [i586-linux]
=> ruby 1.6.7 (2002-07-30) [i586-linux]......シグナルを送らないと終了しない不具合が修正さ
れました。((<ruby-bugs-ja:PR#223>))
trap(:TERM, "EXIT")
END{
puts "exit"
}
Thread.start { Thread.stop }
sleep
: 2002-04-17: Regexp#inspect
((<ruby-bugs-ja:PR#222>))
p %r{\/}
=> ruby 1... -
NEWS for Ruby 3
. 0 . 0 (72.0) -
NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...* `in` is changed to return `true` or `false`. 17371
//emlist{
0 => a
p a #=> 0
{b: 0, c: 1} => {b:}
p b #=> 0
//}
//emlist{
# version 3.0
0 in 1 #=> false
# version 2.7
0 in 1 #=> raise NoMatchingPatternError
//}
* Find-pattern is added. [EXPERIMENTAL]
16828
//emlist{
case ["a", 1, "b......IO
* IO#nonblock? now defaults to `true`. 16786
* IO#wait_readable, IO#wait_writable, IO#read, IO#write and other related methods (e.g. IO#puts, IO#gets) may invoke the scheduler hook `#io_wait(io, events, timeout)` in a non-blocking execution context. 16786
* Kernel
* Kernel#clone wh......ate to BigDecimal 3.0.0
* This version is Ractor compatible.
* Bundler
* Update to Bundler 2.2.3
* CGI
* Update to 0.2.0
* This version is Ractor compatible.
* CSV
* Update to CSV 3.1.9
* Date
* Update to Date 3.1.1
* This version is Ractor compatible.
* Digest... -
Kernel
$ $ -I -> [String] (60.0) -
Rubyライブラリをロードするときの検索パスです。
..._ruby/VERSION サイト固有、バージョン依存のライブラリ
/usr/local/lib/ruby/site_ruby/VERSION/ARCH サイト固有、システム依存、拡張ライブラリ
/usr/local/lib/ruby/site_ruby サイト固有ライブラリ
/usr/local/lib/ruby/VERSION......標準ライブラリ
/usr/local/lib/ruby/VERSION/ARCH 標準、システム依存、拡張ライブラリ
上記表中の VERSION は Ruby のバージョンを表す文字列で、
「1.6」や「1.8」です。
ARCH はハードウェアと OS を表す文字列で、......ます。
したがって Ruby で記述されたコードでは常に .so を使うべきです。
なお、ロードパスをコマンドラインから調べるには
$ ruby -e 'puts $:'
とします。
この変数はグローバルスコープです。
@see spec/rubycmd, spec/envvars......述されたコードでは常に .so を使うべきです。
なお、ロードパスをコマンドラインから調べるには
$ ruby -e 'puts $:'
とします。
$LOAD_PATH の特異メソッドとして resolve_feature_path が定義されています。
require を呼んだときに...