るりまサーチ

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

別のキーワード

  1. kernel $-l
  2. _builtin $-l
  3. matrix l
  4. lupdecomposition l
  5. l matrix

ライブラリ

クラス

キーワード

検索結果

OpenSSL::X509::Name::MULTILINE -> Integer (24301.0)

OpenSSL::X509::Name#to_s のフラグとして使います。

...OpenSSL::X509::Name#to_s のフラグとして使います。

複数行でフォーマットされます。...

Regexp::MULTILINE -> Integer (24301.0)

複数行モード。正規表現 "." が改行にマッチするようになります。 正規表現リテラルの //m オプションと同じです。

複数行モード。正規表現 "." が改行にマッチするようになります。
正規表現リテラルの //m オプションと同じです。

Regexp.compile(string, option = nil, code = nil) -> Regexp (6212.0)

文字列 string をコンパイルして正規表現オブジェクトを生成して返します。

...す。

@param option Regexp::IGNORECASE, Regexp::MULTILINE,
Regexp::EXTENDED
の論理和を指定します。
Integer 以外であれば真偽値の指定として見なされ
、真(nil, false 以外)であれば
Regexp::IGNORE...
...表現のコンパイルに失敗した場合発生します。

//emlist[例][ruby]{
str = "This is Regexp"
t1 = Regexp.compile("this is regexp", Regexp::IGNORECASE)
t1.match(str)
p $~ # => "This is Regexp"

t2 = Regexp.compile('
this # ここは使用されない
\ is
\ regexp # ここ...
...使用されない
', Regexp::EXTENDED | Regexp::IGNORECASE)
t2.match(str)
p Regexp.last_match # => "This is Regexp"

str = "ふるいけや\nかわずとびこむ\nみずのおと"
t2 = Regexp.compile("ふる.*?と", Regexp::MULTILINE)
p t2.match(str)[0] # => "ふるいけや\nかわずと"
//}...

OpenSSL::X509::Name#to_s(flags=nil) -> String (3242.0)

DNの文字列表現を返します。

...lags には通常は以下のいずれかを渡します。
* nil
* OpenSSL::X509::Name::COMPAT
* OpenSSL::X509::Name::RFC2253
* OpenSSL::X509::Name::ONELINE
* OpenSSL::X509::Name::MULTILINE

*
例:
require 'openssl'
n = OpenSSL::X509::Name.parse('/C=JP/ST=Kanagawa/L=Yokohama/O=Exampl...
...=Lab3/CN=foobar/emailAddress=foobar@lab3.example.co.jp')
n.to_s
# => "/C=JP/ST=Kanagawa/L=Yokohama/O=Example Company/OU=Lab3/CN=foobar/emailAddress=foobar@lab3.example.co.jp"
n.to_s(OpenSSL::X509::Name::COMPAT)
# => "C=JP, ST=Kanagawa, L=Yokohama, O=Example Company, OU=Lab3, CN=foobar/email...
...s=foobar@lab3.example.co.jp"
n.to_s(OpenSSL::X509::Name::RFC2253)
# => "emailAddress=foobar@lab3.example.co.jp,CN=foobar,OU=Lab3,O=Example Company,L=Yokohama,ST=Kanagawa,C=JP"
n.to_s(OpenSSL::X509::Name::ONELINE)
# => "C = JP, ST = Kanagawa, L = Yokohama, O = Example Company, OU = Lab3, CN =...

Regexp.new(string, option = nil, code = nil) -> Regexp (3212.0)

文字列 string をコンパイルして正規表現オブジェクトを生成して返します。

...す。

@param option Regexp::IGNORECASE, Regexp::MULTILINE,
Regexp::EXTENDED
の論理和を指定します。
Integer 以外であれば真偽値の指定として見なされ
、真(nil, false 以外)であれば
Regexp::IGNORE...
...表現のコンパイルに失敗した場合発生します。

//emlist[例][ruby]{
str = "This is Regexp"
t1 = Regexp.compile("this is regexp", Regexp::IGNORECASE)
t1.match(str)
p $~ # => "This is Regexp"

t2 = Regexp.compile('
this # ここは使用されない
\ is
\ regexp # ここ...
...使用されない
', Regexp::EXTENDED | Regexp::IGNORECASE)
t2.match(str)
p Regexp.last_match # => "This is Regexp"

str = "ふるいけや\nかわずとびこむ\nみずのおと"
t2 = Regexp.compile("ふる.*?と", Regexp::MULTILINE)
p t2.match(str)[0] # => "ふるいけや\nかわずと"
//}...

絞り込み条件を変える

正規表現 (516.0)

正規表現 * metachar * expansion * char * anychar * string * str * quantifier * capture * grouping * subexp * selector * anchor * cond * option * encoding * comment * free_format_mode * absenceop * list * specialvar * references

...string
* str
* quantifier
* capture
* grouping
* subexp
* selector
* anchor
* cond
* option
* encoding
* comment
* free_format_mode
* absenceop
* list
* specialvar
* references


正規表現(regular expression)は文字列のパターンを記述するための言語...
...ことが
できます。

//emlist[][ruby]{
place = "東京都"
/#{place}/.match("Go to 東京都") # => #<MatchData "東京都">
//}

埋め込んだ文字列にメタ文字が含まれているならば、それは
メタ文字として認識されます。

//emlist[][ruby]{
number = "(\\d+)"
op...
...# => #<MatchData "aBCd">
/a(?:(?i)bc)d/.match("aBCD") # => nil
//}

オプションは Regexp.new の引数に指定することもできます。

//emlist[][ruby]{
Regexp.new("abc", Regexp::IGNORECASE) # => /abc/i
Regexp.new("abc", Regexp::MULTILINE) # => /...