るりまサーチ

最速Rubyリファレンスマニュアル検索!
516件ヒット [501-516件を表示] (0.101秒)

別のキーワード

  1. rbconfig ruby
  2. fiddle ruby_free
  3. fiddle build_ruby_platform
  4. rake ruby
  5. rubygems/defaults ruby_engine

ライブラリ

キーワード

検索結果

<< < ... 4 5 6 >>

StringScanner#eos? -> bool (6032.0)

スキャンポインタが文字列の末尾を指しているなら true を、 末尾以外を指しているなら false を返します。

...しているなら true を、
末尾以外を指しているなら false を返します。

//emlist[例][ruby]{
r
equire 'strscan'

s = StringScanner.new('test string')
s.eos? # => false
s.scan(/\w+/)
s.scan(/\s+/)
s.scan(/\w+/)
s.eos? # => true
//}

StringScanner
#empty? は将来の...
...バージョンで削除される予定です。
代わりに StringScanner#eos? を使ってください。...

StringScanner#matched? -> bool (6032.0)

前回のマッチが成功していたら true を、 失敗していたら false を返します。

...していたら true を、
失敗していたら false を返します。

//emlist[例][ruby]{
r
equire 'strscan'

s = StringScanner.new('test string')
s.matched? # => false
s.scan(/\w+/) # => "test"
s.matched? # => true
s.scan(/\w+/) # => nil
s.matched? # => false
s.scan(/\s+/) # => " "
s...
....matched? # => true
//}...
<< < ... 4 5 6 >>