ライブラリ
- benchmark (1)
- matrix (1)
- rake (1)
-
rexml
/ document (5) -
rexml
/ streamlistener (3) -
rubygems
/ source _ info _ cache (2) - shell (2)
-
shell
/ command-processor (2) -
shell
/ filter (4) -
shell
/ system-command (4)
クラス
-
Benchmark
:: Tms (1) -
Gem
:: SourceInfoCache (2) - Matrix (1)
-
REXML
:: DocType (3) -
REXML
:: Entity (1) -
REXML
:: NotationDecl (1) -
Rake
:: Application (1) - Shell (2)
-
Shell
:: CommandProcessor (2) -
Shell
:: Filter (4) -
Shell
:: SystemCommand (4)
モジュール
キーワード
- command (1)
- doctype (1)
- echo (3)
- eigensystem (1)
- entitydecl (1)
- external (1)
-
external
_ id (1) - format (1)
-
latest
_ system _ cache _ file (1) - name (1)
- notationdecl (1)
- notify (2)
- public (1)
-
system
_ cache _ file (1) -
to
_ a (1) -
to
_ s (1) - transact (3)
検索結果
先頭5件
-
REXML
:: DocType # system -> String | nil (63997.0) -
DTD のシステム識別子を返します。
DTD のシステム識別子を返します。
DTD が外部サブセットを含んでいない場合は nil を返します。
//emlist[][ruby]{
require 'rexml/document'
doctype = REXML::Document.new(<<EOS).doctype
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
EOS
doctype.system # => "http://www.w... -
REXML
:: NotationDecl # system -> String | nil (63907.0) -
システム識別子(URI)を返します。
システム識別子(URI)を返します。
宣言がシステム識別子を含まない場合は nil を返します。 -
Gem
:: SourceInfoCache # latest _ system _ cache _ file -> String (36907.0) -
最新のシステムキャッシュのファイル名を返します。
最新のシステムキャッシュのファイル名を返します。 -
Gem
:: SourceInfoCache # system _ cache _ file -> String (36907.0) -
システムキャッシュファイルの名前を返します。
システムキャッシュファイルの名前を返します。 -
Shell
# transact { . . . } -> object (27394.0) -
ブロック中で shell を self として実行します。
ブロック中で shell を self として実行します。
例:
require 'shell'
Shell.def_system_command("head")
sh = Shell.new
sh.transact{
system("ls", "-l") | head > STDOUT
# transact の中では、
# sh.system("ls", "-l") | sh.head > STDOUT と同じとなる。
} -
Shell
:: CommandProcessor # transact { . . . } -> object (27394.0) -
ブロック中で shell を self として実行します。
ブロック中で shell を self として実行します。
例:
require 'shell'
Shell.def_system_command("head")
sh = Shell.new
sh.transact{
system("ls", "-l") | head > STDOUT
# transact の中では、
# sh.system("ls", "-l") | sh.head > STDOUT と同じとなる。
} -
Shell
:: Filter # transact { . . . } -> object (27394.0) -
ブロック中で shell を self として実行します。
ブロック中で shell を self として実行します。
例:
require 'shell'
Shell.def_system_command("head")
sh = Shell.new
sh.transact{
system("ls", "-l") | head > STDOUT
# transact の中では、
# sh.system("ls", "-l") | sh.head > STDOUT と同じとなる。
} -
REXML
:: StreamListener # entitydecl(content) -> () (27376.0) -
DTDの実体宣言をパースしたときに呼び出されるコールバックメソッドです。
DTDの実体宣言をパースしたときに呼び出されるコールバックメソッドです。
@param content 実体宣言が配列で渡されます
実体宣言の書き方によって content に渡されるデータの形式が異なります。
//emlist[][ruby]{
require 'rexml/parsers/baseparser'
require 'rexml/parsers/streamparser'
require 'rexml/streamlistener'
xml = <<EOS
<!DOCTYPE root [
<!ENTITY % YN '"Yes"'>
<!ENTITY % YN 'Yes... -
REXML
:: StreamListener # notationdecl(content) -> () (27322.0) -
DTDの記法宣言をパースしたときに呼び出されるコールバックメソッドです。
DTDの記法宣言をパースしたときに呼び出されるコールバックメソッドです。
@param content 記法宣言が
[記法名文字列, 種別("PUBLIC" もしくは "SYSTEM"), 公開識別子文字列,
URI文字列] という配列で渡されます。 -
REXML
:: Entity # external -> String | nil (18952.0) -
実体が外部実体(external entity)宣言である場合は "SYSTEM" もしくは "PUBLIC" という文字列を返します。
実体が外部実体(external entity)宣言である場合は
"SYSTEM" もしくは "PUBLIC" という文字列を返します。
内部実体(internal entity)宣言である場合には nil を返します。 -
Matrix
# eigensystem -> Matrix :: EigenvalueDecomposition (18904.0) -
行列の固有値と左右の固有ベクトルを保持したオブジェクトを返します。
行列の固有値と左右の固有ベクトルを保持したオブジェクトを返します。
Matrix::EigenvalueDecomposition は to_ary を定義しているため、
多重代入によって3つの行列(右固有ベクトル、固有値行列、左固有ベクトル)
を得ることができます。
これを [V, D, W] と書くと、
(元の行列が対角化可能ならば)、
D は対角行列で、 self == V*D*W, V = W.inverse を満たします。
D のそれぞれの対角成分が行列の固有値です。
//emlist[例][ruby]{
require 'matrix'
m = Matrix[[1, 2], [... -
REXML
:: DocType # public -> String | nil (18694.0) -
DTD の公開識別子を返します。
DTD の公開識別子を返します。
DTD が公開識別子による外部サブセットを含んでいない場合は nil を返します。
//emlist[][ruby]{
require 'rexml/document'
doctype = REXML::Document.new(<<EOS).doctype
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
EOS
doctype.system # => "http:/... -
REXML
:: DocType # external _ id -> String | nil (18670.0) -
DTD が外部サブセットを用いている場合は "SYSTEM", "PUBLIC" の いずれかの文字列を返します。
DTD が外部サブセットを用いている場合は "SYSTEM", "PUBLIC" の
いずれかの文字列を返します。
それ以外の場合は nil を返します。
//emlist[][ruby]{
require 'rexml/document'
doctype = REXML::Document.new(<<EOS).doctype
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
EOS
doctype.... -
REXML
:: StreamListener # doctype(name , pub _ sys , long _ name , uri) -> () (18358.0) -
文書型宣言(DTD)をパースしたときに呼び出されるコールバックメソッドです。
文書型宣言(DTD)をパースしたときに呼び出されるコールバックメソッドです。
pub_sys, long_name, uri はDTDが内部サブセットのみを
利用している場合には nil が渡されます。
@param name 宣言されているルート要素名が文字列で渡されます。
@param pub_sys "PUBLIC" もしくは "SYSTEM" が渡されます。nilが渡される場合もあります。
@param long_name "SYSTEM" の場合はシステム識別子が、"PUBLIC"の場合は公開識別子が
文字列で渡されます
@param uri "SYSTEM" の場... -
Shell
:: SystemCommand # command -> String (18304.0) -
@todo
@todo
コマンド名を返します。 -
Shell
:: SystemCommand # name -> String (18304.0) -
@todo
@todo
コマンド名を返します。 -
Shell
:: SystemCommand # notify(*opts) -> String (18304.0) -
@todo
@todo
@param opts
@see Shell#notify -
Shell
:: SystemCommand # notify(*opts) {|message| . . . } -> String (18304.0) -
@todo
@todo
@param opts
@see Shell#notify -
Shell
# echo(*strings) -> Shell :: Filter (9658.0) -
実行すると, それらを内容とする Filter オブジェクトを返します.
実行すると, それらを内容とする Filter オブジェクトを返します.
@param strings シェルコマンド echo に与える引数を文字列で指定します。
動作例
require 'shell'
Shell.def_system_command("head")
sh = Shell.new
sh.transact {
glob("*.txt").to_a.each { |file|
file.chomp!
cat(file).each { |l|
echo(l) | tee(file + ".tee") >> "al... -
Shell
:: CommandProcessor # echo(*strings) -> Shell :: Filter (9658.0) -
実行すると, それらを内容とする Filter オブジェクトを返します.
実行すると, それらを内容とする Filter オブジェクトを返します.
@param strings シェルコマンド echo に与える引数を文字列で指定します。
動作例
require 'shell'
Shell.def_system_command("head")
sh = Shell.new
sh.transact {
glob("*.txt").to_a.each { |file|
file.chomp!
cat(file).each { |l|
echo(l) | tee(file + ".tee") >> "al... -
Shell
:: Filter # echo(*strings) -> Shell :: Filter (9658.0) -
実行すると, それらを内容とする Filter オブジェクトを返します.
実行すると, それらを内容とする Filter オブジェクトを返します.
@param strings シェルコマンド echo に与える引数を文字列で指定します。
動作例
require 'shell'
Shell.def_system_command("head")
sh = Shell.new
sh.transact {
glob("*.txt").to_a.each { |file|
file.chomp!
cat(file).each { |l|
echo(l) | tee(file + ".tee") >> "al... -
Rake
:: Application # options -> OpenStruct (9340.0) -
コマンドラインで与えられたアプリケーションのオプションを返します。
コマンドラインで与えられたアプリケーションのオプションを返します。
//emlist[][ruby]{
# Rakefile での記載例とする
task default: :test_rake_app
task :test_rake_app do
Rake.application.options # => #<OpenStruct always_multitask=false, backtrace=false, build_all=false, dryrun=false, ignore_deprecate=false, ignore_system=false, job_stats=... -
Shell
:: Filter # to _ s -> String (9340.0) -
実行結果を文字列で返します。
実行結果を文字列で返します。
require 'shell'
Shell.def_system_command("wc")
sh = Shell.new
sh.transact {
puts (cat("/etc/passwd") | wc("-l")).to_s
} -
Shell
:: Filter # to _ a -> [String] (9322.0) -
実行結果を文字列の配列で返します。
実行結果を文字列の配列で返します。
require 'shell'
Shell.def_system_command("wc")
sh = Shell.new
puts sh.cat("/etc/passwd").to_a -
Benchmark
:: Tms # format(fmtstr = nil , *args) -> String (940.0) -
self を指定されたフォーマットで整形して返します。
self を指定されたフォーマットで整形して返します。
このメソッドは Kernel.#format のようにオブジェクトを整形しますが、
以下の拡張を使用することができます。
: %u
user CPU time で置き換えられます。Benchmark::Tms#utime
: %y
system CPU time で置き換えられます(Mnemonic: y of "s*y*stem")。Benchmark::Tms#stime
: %U
子プロセスの user CPU time で置き換えられます。Benchmark::Tms#cutime
: %Y
子プロセスの s...