るりまサーチ (Ruby 2.4.0)

最速Rubyリファレンスマニュアル検索!
5件ヒット [1-5件を表示] (0.178秒)

別のキーワード

  1. _builtin to_a
  2. matrix to_a
  3. to_a
  4. dbm to_a
  5. rexml/document to_a

キーワード

検索結果

ARGF.class#print(*arg) -> nil (81943.0)

引数を順に処理対象のファイルに出力します。

引数を順に処理対象のファイルに出力します。

c:ARGF#inplace時にのみ使用できます。
また $stdout への代入の影響を受けません。
それ以外は Kernel.#print と同じです。

@param arg 出力するオブジェクトを任意個指定します。

IO#print(*arg) -> nil (72979.0)

引数を IO ポートに順に出力します。引数を省略した場合は、$_ を出力します。

引数を IO ポートに順に出力します。引数を省略した場合は、$_ を出力します。

@param arg Kernel.#print と同じです。

@raise IOError 自身が書き込み用にオープンされていなければ発生します。

@raise Errno::EXXX 出力に失敗した場合に発生します。

//emlist[例][ruby]{
$stdout.print("This is ", 100, " percent.\n") # => This is 100 percent.
//}

@see Kernel.#print

ARGF.class#printf(format, *arg) -> nil (45922.0)

C 言語の printf と同じように、format に従い引数を 文字列に変換して処理対象のファイルに出力します。

C 言語の printf と同じように、format に従い引数を
文字列に変換して処理対象のファイルに出力します。

c:ARGF#inplace時にのみ使用できます。
また $stdout への代入の影響を受けません。
それ以外は出力先を指定しない形式の Kernel.#printf と同じです。

@param format フォーマット文字列です。
@param arg フォーマットされる引数です。

Shell::CommandProcessor#system(command, *opts) -> Shell::SystemCommand (18640.0)

command を実行する.

command を実行する.

@param command 実行するコマンドのパスを文字列で指定します。

@param opts command のオプションを文字列で指定します。複数可。

使用例:

require 'shell'
Shell.verbose = false
sh = Shell.new

print sh.system("ls", "-l")
Shell.def_system_command("head")
sh.system("ls", "-l") | sh.head("-n 3") > STDOUT

Shell::Filter#system(command, *opts) -> Shell::SystemCommand (9640.0)

command を実行する.

command を実行する.

@param command 実行するコマンドのパスを文字列で指定します。

@param opts command のオプションを文字列で指定します。複数可。

使用例:

require 'shell'
Shell.verbose = false
sh = Shell.new

print sh.system("ls", "-l")
Shell.def_system_command("head")
sh.system("ls", "-l") | sh.head("-n 3") > STDOUT

絞り込み条件を変える