るりまサーチ

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

別のキーワード

  1. openssl new
  2. _builtin new
  3. rexml/document new
  4. resolv new
  5. socket new

ライブラリ

モジュール

キーワード

検索結果

<< 1 2 3 > >>

OptionParser.new(banner = nil, width = 32, indent = &#39; &#39; * 4) -> OptionParser (18216.0)

OptionParser オブジェクトを生成して返します。

...してブロックを評
価します。つまり、以下のような書き方が可能です。

//emlist[][ruby]{
require 'optparse'
OptionParser.new do |opt|

opt.on('-a') {|v| p v }
opt.on('-b') {|v| p v }

opt.parse!(ARGV)
end
//}

@param banner ヘルプ(サマリ)の最初の部分に...
...表示される、アプリケーションの説明などを文字列で与えます。

@param width サマリの幅を整数で与えます。

@param indent サマリのインデントを文字列で与えます。...

OptionParser.new(banner = nil, width = 32, indent = &#39; &#39; * 4) {|opt| ...} -> OptionParser (18216.0)

OptionParser オブジェクトを生成して返します。

...してブロックを評
価します。つまり、以下のような書き方が可能です。

//emlist[][ruby]{
require 'optparse'
OptionParser.new do |opt|

opt.on('-a') {|v| p v }
opt.on('-b') {|v| p v }

opt.parse!(ARGV)
end
//}

@param banner ヘルプ(サマリ)の最初の部分に...
...表示される、アプリケーションの説明などを文字列で与えます。

@param width サマリの幅を整数で与えます。

@param indent サマリのインデントを文字列で与えます。...

REXML::Formatters::Pretty.new(indentation=2, ie_hack=false) -> REXML::Formatter::Pretty (18201.0)

フォーマッタオブジェクトを生成して返します。

...します。

indent
ation でインデント幅を(空白の数で)指定します。

ie_hack に真を渡すと、空のタグを閉じる前で空白を挿入します。
これは特定のバージョンのIEのXMLパーサのバグを避けるための機能です。

@param indentation 出力...

REXML::Formatters::Transitive.new(indentation=2, ie_hack=false) -> REXML::Formatter::Transitive (18201.0)

フォーマッタオブジェクトを生成して返します。

...整形します。

indent
ation でインデント幅を指定できます。

ie_hack に真を渡すと、空のタグを閉じる前で空白を挿入します。
これは特定のバージョンのIEのXMLパーサのバグを避けるための機能です。

@param indentation インデント...

JSON::State.new(options = {}) -> JSON::State (18149.0)

自身を初期化します。

...身を初期化します。

@param options ハッシュを指定します。
指定可能なオプションは以下の通りです。

: :indent
インデントに使用する文字列を指定します。デフォルトは空文字列です。
: :space
JSON 形式の文字列のトー...
...te.new(indent: "\t")
json_state.class # => JSON::Ext::Generator::State
json_state.indent # => "\t"
//}

//emlist[例 JSON::State を指定][ruby]{
require "json"

json_state = JSON::State.new(indent: "\t")
copy = JSON::State.new(json_state)
copy.class # => JSON::Ext::Generator::State
copy.indent #...

絞り込み条件を変える

JSON::State#indent -> String (18119.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\"}"
//}...

OptionParser#summary_indent=(indent) (6232.0)

サマリを表示する時のインデントを文字列で指定します。

...@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.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\n"]
//}...

JSON::State#indent=(string) (6125.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\"}"
json_state.indent = " "
JSON.generate({key1: "value1", key2: "value2"}, json_s...

OptionParser#summary_indent -> String (6125.0)

サマリを表示する時のインデントを文字列で返します。

...tionParser.new do |opts|
opts.on_head("-i", "--init")
opts.on("-u", "--update")
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 #...

OptionParser#summarize(to = [], width = self.summary_width, max = width - 1, indent= self.summary_indent) -> () (216.0)

サマリを指定された to へと加えていきます。

...ます。

@param max サマリの最大幅を整数で指定します。

@param indent サマリのインデントを文字列で指定します。

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

opts = OptionParser.new do |opts|
opts.on_head("-i", "--init")
opts.on("-u", "--update")
opts.on_tail(...

絞り込み条件を変える

<< 1 2 3 > >>