388件ヒット
[1-100件を表示]
(0.070秒)
別のキーワード
種類
- インスタンスメソッド (268)
- 特異メソッド (72)
- モジュール関数 (24)
- ライブラリ (24)
ライブラリ
- ビルトイン (4)
-
irb
/ context (12) - json (108)
- optparse (60)
- prettyprint (36)
- psych (12)
-
rexml
/ document (132)
クラス
-
IRB
:: Context (12) -
JSON
:: State (84) - OptionParser (60)
- PrettyPrint (36)
-
Psych
:: Emitter (12) -
REXML
:: AttlistDecl (12) -
REXML
:: Attribute (12) -
REXML
:: Declaration (12) -
REXML
:: DocType (12) -
REXML
:: Document (24) -
REXML
:: Entity (12) -
REXML
:: ExternalEntity (12) -
REXML
:: Formatters :: Pretty (12) -
REXML
:: Formatters :: Transitive (12) - Refinement (4)
モジュール
- JSON (24)
-
REXML
:: Node (12)
キーワード
-
auto
_ indent _ mode (12) - configure (12)
-
from
_ state (12) - generate (12)
- group (12)
-
import
_ methods (4) - indentation (12)
- irb (12)
- merge (12)
- nest (12)
- new (60)
- pp (12)
- summarize (24)
-
summary
_ indent (12) -
to
_ h (12) -
to
_ hash (12) -
to
_ s (12) - unparse (12)
- write (96)
検索結果
先頭5件
-
JSON
:: State # indent -> String (18213.0) -
インデントに使用する文字列を返します。
...インデントに使用する文字列を返します。
//emlist[例][ruby]{
require "json"
json_state = JSON::State.new(indent: "\t")
json_state.indent # => "\t"
JSON.generate({key1: "value1", key2: "value2"}, json_state)
# => "{\t\"key1\":\"value1\",\t\"key2\":\"value2\"}"
//}... -
PrettyPrint
# indent -> Integer (18201.0) -
現在のインデントの深さを返します。
現在のインデントの深さを返します。 -
OptionParser
# summary _ indent -> String (6219.0) -
サマリを表示する時のインデントを文字列で返します。
...e")
opts.on_tail("-h", "--help")
end
opts.summary_indent # => " "
opts.summarize
# => [" -i, --init\n", " -u, --update\n", " -h, --help\n"]
opts.summary_indent = " "
opts.summary_indent # => " "
opts.summarize
# => [" -i, --init\n", " -u, --update\n", " -h, --help... -
IRB
:: Context # auto _ indent _ mode -> bool (6207.0) -
入力が次の行に継続した時に自動で字下げを行うかどうかを返します。
...入力が次の行に継続した時に自動で字下げを行うかどうかを返します。
デフォルト値は false です。
@return 自動で字下げを行う場合は true を返します。行わない場合は false
を返します。
@see IRB::Context#auto_indent_mode=... -
Psych
:: Emitter # indentation -> Integer (6200.0) -
インデントのレベルを返します。
...インデントのレベルを返します。
@see Psych::Emitter#indentation=... -
irb (474.0)
-
irb は Interactive Ruby の略です。 irb を使うと、Ruby の式を標準入力から簡単に入力・実行することができます。
...0>
あとは Ruby の式を入力するだけで、その式が実行され、結果が表示されます。
irb(main):001:0> 1+2
3
irb(main):002:0> class Foo
irb(main):003:1> def foo
irb(main):004:2> print 1
irb(main):005:2> end
irb(main):006:1> end
:foo
irb(main):007:0>......) 式を .irbrc に記述すると、
irb コマンドのオプションを指定したのと同じ効果が得られます。
IRB.conf[:AUTO_INDENT] = false
IRB.conf[:BACK_TRACE_LIMIT] = 16
IRB.conf[:DEBUG_LEVEL] = 1
IRB.conf[:ECHO] = nil
IRB.conf[:EVAL_HISTORY] = nil
IRB.conf[:HISTORY......PT_I => nil, # 通常時のプロンプト
:PROMPT_N => nil, # 継続行のプロンプト
:PROMPT_S => nil, # 文字列などの継続行のプロンプト
:PROMPT_C => nil, # 式が継続している時のプロンプト
:RETURN => " ==>%s\n"... -
OptionParser
# summarize(to = [] , width = self . summary _ width , max = width - 1 , indent= self . summary _ indent) -> () (310.0) -
サマリを指定された to へと加えていきます。
...します。
@param indent サマリのインデントを文字列で指定します。
//emlist[例][ruby]{
require "optparse"
opts = OptionParser.new do |opts|
opts.on_head("-i", "--init")
opts.on("-u", "--update")
opts.on_tail("-h", "--help")
end
opts.summarize
# => [" -i, --init\n",......" -u, --update\n", " -h, --help\n"]
opts.summarize(["description\n"], 10, 8, " ")
# => ["description\n", " -i\n", " --init\n", " -u\n", " --update\n", " -h\n", " --help\n"]
//}... -
OptionParser
# summarize(to = [] , width = self . summary _ width , max = width - 1 , indent= self . summary _ indent) {|line| . . . } -> () (310.0) -
サマリを指定された to へと加えていきます。
...します。
@param indent サマリのインデントを文字列で指定します。
//emlist[例][ruby]{
require "optparse"
opts = OptionParser.new do |opts|
opts.on_head("-i", "--init")
opts.on("-u", "--update")
opts.on_tail("-h", "--help")
end
opts.summarize
# => [" -i, --init\n",......" -u, --update\n", " -h, --help\n"]
opts.summarize(["description\n"], 10, 8, " ")
# => ["description\n", " -i\n", " --init\n", " -u\n", " --update\n", " -h\n", " --help\n"]
//}... -
PrettyPrint
# nest(indent) { . . . } -> () (223.0) -
自身の現在のインデントを indent だけ増加させてから、ブロックを実行し、元に戻します。
...自身の現在のインデントを indent だけ増加させてから、ブロックを実行し、元に戻します。
@param indent インデントの増加分を整数で指定します。...