9件ヒット
[1-9件を表示]
(0.177秒)
ライブラリ
- ビルトイン (2)
- openssl (2)
- pathname (1)
- rake (2)
-
shell
/ filter (2)
クラス
検索結果
先頭5件
-
Rake
:: InvocationChain :: EmptyInvocationChain # to _ s -> String (90607.0) -
'TOP' という文字列を返します。
'TOP' という文字列を返します。 -
Rake
:: InvocationChain # to _ s -> String (72625.0) -
トップレベルのタスクから自身までの依存関係を文字列として返します。
トップレベルのタスクから自身までの依存関係を文字列として返します。
//emlist[][ruby]{
# Rakefile での記載例とする
task default: :test_rake_app
task :test_rake_app do
invocation_chain= Rake::InvocationChain.new("task_a", Rake::InvocationChain::EMPTY)
invocation_chain.to_s # => "TOP => task_a"
end
//} -
Thread
:: Backtrace :: Location # to _ s -> String (72625.0) -
self が表すフレームを Kernel.#caller と同じ表現にした文字列を返し ます。
self が表すフレームを Kernel.#caller と同じ表現にした文字列を返し
ます。
//emlist[例][ruby]{
# foo.rb
class Foo
attr_accessor :locations
def initialize(skip)
@locations = caller_locations(skip)
end
end
Foo.new(0..2).locations.map do |call|
puts call.to_s
end
# => path/to/foo.rb:5:in `initialize'
# path/to/foo... -
OpenSSL
:: X509 :: Certificate # to _ s -> String (63607.0) -
PEM 形式の文字列を返します。
PEM 形式の文字列を返します。 -
Shell
:: Filter # to _ s -> String (54643.0) -
実行結果を文字列で返します。
実行結果を文字列で返します。
require 'shell'
Shell.def_system_command("wc")
sh = Shell.new
sh.transact {
puts (cat("/etc/passwd") | wc("-l")).to_s
} -
Pathname
# truncate(length) -> 0 (36652.0) -
File.truncate(self.to_s, length) と同じです。
File.truncate(self.to_s, length) と同じです。
@param length 変更したいサイズを整数で与えます。
@see File.truncate -
Thread
:: Backtrace :: Location # inspect -> String (27352.0) -
Thread::Backtrace::Location#to_s の結果を人間が読みやすいような文 字列に変換したオブジェクトを返します。
Thread::Backtrace::Location#to_s の結果を人間が読みやすいような文
字列に変換したオブジェクトを返します。
//emlist[例][ruby]{
# foo.rb
class Foo
attr_accessor :locations
def initialize(skip)
@locations = caller_locations(skip)
end
end
Foo.new(0..2).locations.map do |call|
puts call.inspect
end
# => "path/to/foo.rb:5:in ... -
OpenSSL
:: X509 :: Certificate # to _ pem -> String (18307.0) -
PEM 形式の文字列を返します。
PEM 形式の文字列を返します。 -
Shell
:: Filter # |(filter) -> object (112.0) -
パイプ結合を filter に対して行います。
パイプ結合を filter に対して行います。
@param filter Shell::Filter オブジェクトを指定します。
@return filter を返します。
使用例
require 'shell'
Shell.def_system_command("tail")
Shell.def_system_command("head")
Shell.def_system_command("wc")
sh = Shell.new
sh.transact {
i = 1
while i <= (cat("/etc/passwd") | wc(...