PATH:
opt
/
alt
/
ruby34
/
share
/
ri
/
system
/
MatchData
U:RDoc::AnyMethod[iI"named_captures:ETI"MatchData#named_captures;TF:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"+Returns a hash of the named captures; ;TI"Leach key is a capture name; each value is its captured string or +nil+:;To:RDoc::Markup::BlankLine o:RDoc::Markup::Verbatim; [I"0m = /(?<foo>.)(.)(?<bar>.+)/.match("hoge") ;TI"/# => #<MatchData "hoge" foo:"h" bar:"ge"> ;TI"5m.named_captures # => {"foo"=>"h", "bar"=>"ge"} ;TI" ;TI"&m = /(?<a>.)(?<b>.)/.match("01") ;TI"(# => #<MatchData "01" a:"0" b:"1"> ;TI"3m.named_captures #=> {"a" => "0", "b" => "1"} ;TI" ;TI"&m = /(?<a>.)(?<b>.)?/.match("0") ;TI"'# => #<MatchData "0" a:"0" b:nil> ;TI"3m.named_captures #=> {"a" => "0", "b" => nil} ;TI" ;TI"&m = /(?<a>.)(?<a>.)/.match("01") ;TI"(# => #<MatchData "01" a:"0" a:"1"> ;TI"'m.named_captures #=> {"a" => "1"} ;T:@format0o; ; [I"4If keyword argument +symbolize_names+ is given ;TI">a true value, the keys in the resulting hash are Symbols:;T@o;; [I"&m = /(?<a>.)(?<a>.)/.match("01") ;TI"(# => #<MatchData "01" a:"0" a:"1"> ;TI"<m.named_captures(symbolize_names: true) #=> {:a => "1"};T; 0: @fileI" re.c;T:0@omit_headings_from_table_of_contents_below0I"4named_captures(symbolize_names: false) -> hash ;T0[ I"(p1 = {});T@*FI"MatchData;TcRDoc::NormalClass00
[-] string-i.ri
[edit]
[-] size-i.ri
[edit]
[-] end-i.ri
[edit]
[-] to_s-i.ri
[edit]
[-] captures-i.ri
[edit]
[-] offset-i.ri
[edit]
[-] to_a-i.ri
[edit]
[-] match-i.ri
[edit]
[-] match_length-i.ri
[edit]
[-] pre_match-i.ri
[edit]
[-] deconstruct-i.ri
[edit]
[-] names-i.ri
[edit]
[-] byteoffset-i.ri
[edit]
[-] cdesc-MatchData.ri
[edit]
[-] deconstruct_keys-i.ri
[edit]
[-] hash-i.ri
[edit]
[-] values_at-i.ri
[edit]
[-] eql%3f-i.ri
[edit]
[-] regexp-i.ri
[edit]
[-] begin-i.ri
[edit]
[-] named_captures-i.ri
[edit]
[-] %5b%5d-i.ri
[edit]
[+]
..
[-] bytebegin-i.ri
[edit]
[-] %3d%3d-i.ri
[edit]
[-] inspect-i.ri
[edit]
[-] byteend-i.ri
[edit]
[-] length-i.ri
[edit]
[-] post_match-i.ri
[edit]