ライブラリ
- ビルトイン (2)
- optparse (2)
- psych (2)
-
rake
/ packagetask (1) -
rexml
/ document (2) -
rubygems
/ commands / unpack _ command (1) -
rubygems
/ platform (1) -
rubygems
/ specification (3) -
rubygems
/ version (2)
クラス
-
Encoding
:: UndefinedConversionError (2) -
Gem
:: Commands :: UnpackCommand (1) -
Gem
:: Platform (1) -
Gem
:: Specification (3) -
Gem
:: Version (2) - OptionParser (2)
-
Psych
:: Nodes :: Node (2) -
REXML
:: Document (1) -
REXML
:: Instruction (1) -
Rake
:: PackageTask (1)
キーワード
-
destination
_ encoding _ name (1) -
error
_ char (1) -
full
_ name (1) -
get
_ path (1) -
mark
_ version (1) -
rubygems
_ version (1) -
stand
_ alone? (1) - target (1)
-
to
_ s (1) -
to
_ yaml (1) - ver (1)
- yaml (1)
検索結果
先頭5件
-
Gem
:: Platform # version -> String (63610.0) -
プラットフォームのバージョンを返します。
プラットフォームのバージョンを返します。 -
OptionParser
# version -> String (63610.0) -
プログラムのバージョンを文字列で返します。
プログラムのバージョンを文字列で返します。
@return プログラムのバージョンを文字列で返します。
@see OptionParser#ver -
Rake
:: PackageTask # version -> String (63610.0) -
作成するパッケージのバージョンを表す文字列を返します。
作成するパッケージのバージョンを表す文字列を返します。 -
Gem
:: Version # version -> String (54757.0) -
バージョン情報を文字列として返します。
バージョン情報を文字列として返します。
//emlist[][ruby]{
version = Gem::Version.new("1.2.3a")
p version.to_s # => "1.2.3a"
p version.version # => "1.2.3a"
//} -
Gem
:: Specification # mark _ version -> String (36910.0) -
RubyGems のバージョンを内部にセットします。
RubyGems のバージョンを内部にセットします。 -
Gem
:: Commands :: UnpackCommand # get _ path(gemname , version _ req) -> String | nil (27928.0) -
引数で指定された条件にマッチする Gem パッケージを保存しているパスを返します。
引数で指定された条件にマッチする Gem パッケージを保存しているパスを返します。
@param gemname Gem パッケージの名前を指定します。
@param version_req バージョンの満たすべき条件を文字列で指定します。 -
Encoding
:: UndefinedConversionError # error _ char -> String (27643.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
//} -
Gem
:: Specification # rubygems _ version -> String (27610.0) -
この Gem パッケージを作成した RubyGems のバージョンを返します。
この Gem パッケージを作成した RubyGems のバージョンを返します。 -
Encoding
:: UndefinedConversionError # destination _ encoding _ name -> String (27607.0) -
エラーを発生させた変換の変換先のエンコーディングを文字列で返します。
エラーを発生させた変換の変換先のエンコーディングを文字列で返します。
@see Encoding::UndefinedConversionError#destination_encoding -
Gem
:: Specification # full _ name -> String (18673.0) -
この Gem パッケージのバージョンを含む完全な名前 (name-version) を返します。
この Gem パッケージのバージョンを含む完全な名前 (name-version) を返します。
プラットフォームの情報が指定されている場合は、それも含みます (name-version-platform)。 -
Psych
:: Nodes :: Node # to _ yaml(io=nil , options={}) -> String | IO (18628.0) -
AST を YAML ドキュメントに変換します。
AST を YAML ドキュメントに変換します。
io に IO オブジェクトを指定した場合は、その
オブジェクトに変換後のドキュメントが書き込まれます。
この場合は io を返り値として返します。
io を省略した(nil を指定した)場合には変換後のドキュメントを
文字列で返します。
Psych::Nodes::Stream 以外を変換しようとすると、AST として不正で
あるためエラーが発生します。
options には以下が指定できます。
: :version
YAML document に付加するバージョンを [major, minor] という配列、
もしくは文... -
Psych
:: Nodes :: Node # yaml(io=nil , options={}) -> String | IO (18628.0) -
AST を YAML ドキュメントに変換します。
AST を YAML ドキュメントに変換します。
io に IO オブジェクトを指定した場合は、その
オブジェクトに変換後のドキュメントが書き込まれます。
この場合は io を返り値として返します。
io を省略した(nil を指定した)場合には変換後のドキュメントを
文字列で返します。
Psych::Nodes::Stream 以外を変換しようとすると、AST として不正で
あるためエラーが発生します。
options には以下が指定できます。
: :version
YAML document に付加するバージョンを [major, minor] という配列、
もしくは文... -
REXML
:: Document # stand _ alone? -> String (18625.0) -
XML 宣言の standalone の値を文字列で返します。
XML 宣言の standalone の値を文字列で返します。
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new(<<EOS)
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<e />
EOS
doc.stand_alone? # => "yes"
//} -
REXML
:: Instruction # target -> String (18625.0) -
XML 処理命令のターゲットを返します。
XML 処理命令のターゲットを返します。
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new(<<EOS)
<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/css" href="style.css"?>
<root />
EOS
doc[2] # => <?p-i xml-stylesheet ...?>
doc[2].target # => "xml-stylesheet"
doc[2].content # => "t... -
Gem
:: Version # to _ s -> String (9457.0) -
バージョン情報を文字列として返します。
バージョン情報を文字列として返します。
//emlist[][ruby]{
version = Gem::Version.new("1.2.3a")
p version.to_s # => "1.2.3a"
p version.version # => "1.2.3a"
//} -
OptionParser
# ver -> String (9409.0) -
program_name、version と release から生成したバージョンを表す文字列を返します。
program_name、version と release から生成したバージョンを表す文字列を返します。
//emlist[例][ruby]{
require "optparse"
OptionParser.new do |opts|
opts.banner = "Usage: example.rb [options]"
opts.program_name = "Optparse Example"
opts.version = [0, 1]
opts.release = "2019-05-01"
opts.on_tail("--version", "Show v...