ライブラリ
- ビルトイン (239)
クラス
-
ARGF
. class (33) -
Encoding
:: Converter (44) - Regexp (11)
- String (119)
- Symbol (32)
キーワード
- capitalize (16)
- capitalize! (8)
- downcase (16)
- downcase! (8)
- encode (33)
- encode! (22)
-
primitive
_ convert (44) -
set
_ encoding (33) - swapcase (16)
- swapcase! (8)
- upcase (16)
- upcase! (8)
検索結果
先頭5件
- Regexp
# options -> Integer - Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer , destination _ byteoffset , destination _ bytesize , options) -> Symbol - ARGF
. class # set _ encoding(enc _ str , options = {}) -> self - ARGF
. class # set _ encoding(ext _ enc , int _ enc , options = {}) -> self - String
# capitalize!(*options) -> self | nil
-
Regexp
# options -> Integer (26150.0) -
正規表現の生成時に指定されたオプションを返します。戻り値は、 Regexp::EXTENDED, Regexp::IGNORECASE, Regexp::MULTILINE, Regexp::FIXEDENCODING, Regexp::NOENCODING, の論理和です。
...GNORECASE # => 1
p //i.options # => 1
p Regexp.new("foo", Regexp::IGNORECASE ).options # => 1
p Regexp.new("foo", Regexp::EXTENDED).options # => 2
p Regexp.new("foo", Regexp::IGNORECASE | Regexp::EXTENDED).options # => 3
p Regexp.new("foo", Regexp::MULTILINE).options # => 4
p Regexp.new("......foo", Regexp::IGNORECASE | Regexp::MULTILINE ).options # => 5
p Regexp.new("foo", Regexp::MULTILINE | Regexp::EXTENDED).options # =>6
p Regexp.new("foo", Regexp::IGNORECASE | Regexp::MULTILINE | Regexp::EXTENDED).options # => 7
//}... -
Encoding
:: Converter # primitive _ convert(source _ buffer , destination _ buffer , destination _ byteoffset , destination _ bytesize , options) -> Symbol (8114.0) -
エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。
...ッファでのオフセット
@param destination_bytesize 変換先バッファの容量
@param options 変換の詳細を指定する定数やハッシュ
@return 変換結果を表す Symbol
options には以下が指定できます。
: hash form
:partial_input => true # source buf... -
ARGF
. class # set _ encoding(enc _ str , options = {}) -> self (8109.0) -
ARGF の外部/内部エンコーディングを設定します。 次以降に処理するファイルにも同じ設定が適用されます。
...ます。
@param int_enc 内部エンコーディングを表す文字列か
Encoding オブジェクトを指定します。
@param options エンコーディング変換のオプション。
String#encode と同じものが指定できます。
@see String#encode... -
ARGF
. class # set _ encoding(ext _ enc , int _ enc , options = {}) -> self (8109.0) -
ARGF の外部/内部エンコーディングを設定します。 次以降に処理するファイルにも同じ設定が適用されます。
...ます。
@param int_enc 内部エンコーディングを表す文字列か
Encoding オブジェクトを指定します。
@param options エンコーディング変換のオプション。
String#encode と同じものが指定できます。
@see String#encode... -
String
# capitalize!(*options) -> self | nil (8108.0) -
文字列先頭の文字を大文字に、残りを小文字に破壊的に変更します。
...文字列先頭の文字を大文字に、残りを小文字に破壊的に変更します。
@param options オプションの詳細は String#downcase を参照してください。
@return capitalize! は self を変更して返しますが、
変更が起こらなかった場合は ni... -
String
# capitalize(*options) -> String (8108.0) -
文字列先頭の文字を大文字に、残りを小文字に変更した文字列を返します。
...文字列先頭の文字を大文字に、残りを小文字に変更した文字列を返します。
@param options オプションの詳細は String#downcase を参照してください。
//emlist[例][ruby]{
p "foobar--".capitalize # => "Foobar--"
p "fooBAR--".capitalize # => "Foobar--"... -
String
# downcase!(*options) -> self | nil (8108.0) -
全ての大文字を対応する小文字に破壊的に置き換えます。 どの文字がどう置き換えられるかは、オプションの有無や文字列のエンコーディングに依存します。
...どの文字がどう置き換えられるかは、オプションの有無や文字列のエンコーディングに依存します。
@param options オプションの詳細は String#downcase を参照してください。
@return self を変更して返します。変更が無かった場合... -
String
# downcase(*options) -> String (8108.0) -
全ての大文字を対応する小文字に置き換えた文字列を返します。 どの文字がどう置き換えられるかは、オプションの有無や文字列のエンコーディングに依存します。
...どの文字がどう置き換えられるかは、オプションの有無や文字列のエンコーディングに依存します。
@param options オプションの意味は以下の通りです。
: オプションなし
完全な Unicode ケースマッピングに対応し、ほとん... -
String
# swapcase!(*options) -> self | nil (8108.0) -
大文字を小文字に、小文字を大文字に破壊的に変更します。
...大文字を小文字に、小文字を大文字に破壊的に変更します。
@param options オプションの詳細は String#downcase を参照してください。
swapcase! は self を変更して返しますが、
置換が起こらなかった場合は nil を返します。
この... -
String
# swapcase(*options) -> String (8108.0) -
大文字を小文字に、小文字を大文字に変更した文字列を返します。
...大文字を小文字に、小文字を大文字に変更した文字列を返します。
@param options オプションの詳細は String#downcase を参照してください。
//emlist[例][ruby]{
p "ABCxyz".swapcase # => "abcXYZ"
p "Access".swapcase # => "aCCESS"
//}
@see String#swapca... -
String
# upcase!(*options) -> self | nil (8108.0) -
全ての小文字を対応する大文字に破壊的に置き換えます。 どの文字がどう置き換えられるかは、オプションの有無や文字列のエンコーディングに依存します。
...どの文字がどう置き換えられるかは、オプションの有無や文字列のエンコーディングに依存します。
@param options オプションの詳細は String#downcase を参照してください。
//emlist[例][ruby]{
buf = "stRIng? STring."
buf.upcase!
p buf # => "...