るりまサーチ

最速Rubyリファレンスマニュアル検索!
193件ヒット [1-100件を表示] (0.023秒)
トップページ > クエリ:end[x] > クエリ:usage[x]

別のキーワード

  1. _builtin end
  2. ripper end_seen?
  3. _builtin exclude_end?
  4. _builtin end_with?
  5. range end

検索結果

<< 1 2 > >>

Gem::Commands::DependencyCommand#usage -> String (21101.0)

使用方法を表す文字列を返します。

使用方法を表す文字列を返します。

rubygems/commands/dependency_command (6006.0)

インストールされている Gem パッケージの依存関係を表示するためのライブラリです。

...

Usage
: gem dependency GEMNAME [options]
Options:
-v, --version VERSION 指定したバージョンの依存関係を表示します
--platform PLATFORM 指定したプラットフォームの依存関係を表示します
-R, --[no-]reverse-dependenc...
...ッグオプションを有効にします
Arguments:
GEMNAME 依存関係を表示する Gem の名前を指定します
Summary:
インストールされている Gem の依存関係を表示します
Defaults:
--local --version '>= 0' --no-reverse-dependencies...

rdoc (66.0)

RDoc は Ruby のドキュメント生成を行うためのライブラリです。rdoc という ドキュメント生成のためのコマンドも含んでいます。

...ディレクト
リを再帰的に走査します。ただしこの場合 Ruby と C のソースファイルのみが
処理されます。

===[a:usage] 使いかた

RDoc はコマンドラインから以下のようにして起動します。

$ rdoc <options> [name...]

ファイルをパー...
...ントも使え
ますし、=begin/=end でのコメントも使えます。=begin/=end を使う場合は、
以下のように =begin の行に 'rdoc' タグを付ける必要があります。

=begin rdoc
Documentation to
be processed by RDoc.
=end

パラグラフは左のインデン...
...したい場合は all 修飾
子を加えます。

//emlist{
module SM #:nodoc:
class Input
end

end

module Markup #:nodoc: all
class Output
end

end

//}

以上のコードでは、SM::Input のドキュメントのみが出力されます。

: :stopdoc...

Rubyで使われる記号の意味(正規表現の複雑な記号は除く) (60.0)

Rubyで使われる記号の意味(正規表現の複雑な記号は除く) ex q num per and or  plus minus ast slash hat sq  period comma langl rangl eq tilde  dollar at under lbrarbra  lbra2rbra2 lbra3rbra3 dq colon ac  backslash semicolon

...ソッドを示すために使われます。

: xx ? yy : zz

d:spec/operator#cond。三項演算子とも呼ばれます。if xx then yy else zz end と同じ意味です。

: /xxx?/

正規表現の、量指定子(quantifiers)。直前の正規表現の 0 または 1 回の繰り返し。

===...
...ためには
d:spec/variables#const を参照。

: xx ? yy : zz

条件演算子。三項演算子とも呼ばれます。if xx then yy else zz end と同じ意味です。
d:spec/operator#cond を参照。


: { a:"aaa", b:"bbb" }

ハッシュの新しい記法。以下と同じです。
//em...
...行され、
その標準出力が文字列として与えられます。d:spec/literal#commandを参照。
//emlist{
puts `ruby -h`
#=> Usage: ruby [switches] [--] [programfile] [arguments]
#=> ....
//}

===[a:backslash] \
バックスラッシュ。環境によって¥に見えたり...

test/unit (54.0)

ユニットテストを行うためのライブラリです。

...います。

まずテスト対象のソース(foo.rb)が必要です。

class Foo
def foo
"foo"
end

def bar
"foo"
end

end


次にユニットテスト(test_foo.rb)を書きます。テストを実行するメソッド(テストメソッド)の...
...st::Unit::TestCase
def setup
@obj = Foo.new
end


# def teardown
# end

def test_foo
assert_equal("foo", @obj.foo)
end

def test_bar
assert_equal("bar", @obj.bar)
end

end


テストを実行するには上で用意した test_...
...ps

--name=test_barのような指定は行えません。

以下のようにすると help も表示されます。

$ ruby test_foo.rb --help
Usage
: test_foo [options]
minitest options:
-h, --help Display this help.
-s, --seed SEED Sets ran...

絞り込み条件を変える

rinda/rinda (36.0)

Rubyで実装されたタプルスペース(Tuple Space)を扱うためのライブラリです。

...it(#{v})"
v + v
end


uri = ARGV.shift || raise("usage: #{$0} <server_uri>")

DRb.start_service
ts = Rinda::TupleSpaceProxy.new(DRbObject.new(nil, uri))

while true
r = ts.take(['sum', nil, nil])
v = do_it(r[2])
ts.write(['ans', r[1], r[2], v])
end



# rindac.rb...
...ift || raise("usage: #{$0} <server_uri>")

DRb.start_service
ts = Rinda::TupleSpaceProxy.new(DRbObject.new(nil, uri))

(1..10).each do |n|
ts.write(['sum', DRb.uri, n])
end


(1..10).each do |n|
ans = ts.take(['ans', DRb.uri, n, nil])
p [ans[2], ans[3]]
end


この例は...

OptionParser#banner=(heading) (30.0)

サマリの最初に表示される文字列を指定します。

...y]{
require "optparse"

options = {}
opts = OptionParser.new do |opts|
opts.banner = "Usage: example.rb [options]" # => "Usage: example.rb [options]"

opts.on("-v", "--[no-]verbose", "Run verbosely") do |v|
options[:verbose] = v
end

end


opts.banner # => "Usage: example.rb [options]"
//}...

OptionParser#banner -> String (24.0)

サマリの最初に表示される文字列を返します。

...します。

//emlist[例][ruby]{
require "optparse"

options = {}
opts = OptionParser.new do |opts|
opts.banner = "Usage: example.rb [options]"

opts.on("-v", "--[no-]verbose", "Run verbosely") do |v|
options[:verbose] = v
end

end


p opts.banner # => "Usage: example.rb [options]"
//}...

OptionParser#help -> String (24.0)

サマリの文字列を返します。

...optparse"

options = {}
opts = OptionParser.new do |opts|
opts.banner = "Usage: example.rb [options]"

opts.on("-v", "--[no-]verbose", "Run verbosely") do |v|
options[:verbose] = v
end

end


puts opts.help

# => Usage: example.rb [options]
# -v, --[no-]verbose Run verbosely...

OptionParser#on_tail(*arg, &block) -> self (24.0)

オプションを取り扱うためのブロックを自身の持つリストの最後に登録します。

...opts.on_tail("-h", "--help")
end


puts opts.help

# => Usage: test [options]
# -i, --init
# -u, --update
# -h, --help
//}

//emlist[例][ruby]{
require "optparse"

opts = OptionParser.new
opts.on_tail("-h", "--help", "Show this message") do
puts opts
exit
end


opts.on_tail("--version",...
..."Show version") do
puts OptionParser::Version.join('.')
exit
end

//}

@see OptionParser#on, OptionParser#on_head...

絞り込み条件を変える

<< 1 2 > >>