48件ヒット
[1-48件を表示]
(0.029秒)
トップページ > :StringScanner#skip
別のキーワード
種類
- インスタンスメソッド (44)
- 文書 (4)
ライブラリ
- strscan (44)
クラス
- StringScanner (44)
キーワード
-
NEWS for Ruby 3
. 0 . 0 (4) -
scan
_ full (11) -
search
_ full (11) - skip (11)
-
skip
_ until (11)
検索結果
先頭5件
-
StringScanner
# skip(regexp) -> Integer | nil (62137.0) -
スキャンポインタの地点だけで regexp と文字列のマッチを試します。 マッチしたらスキャンポインタを進めマッチした部分文字列の 長さを返します。マッチしなかったら nil を返します。
...を返します。
@param regexp マッチに使用する正規表現を指定します。
//emlist[例][ruby]{
require 'strscan'
s = StringScanner.new('test string')
p s.skip(/\w+/) #=> 4
p s.skip(/\w+/) #=> nil
p s.skip(/\s+/) #=> 1
p s.skip(/\w+/) #=> 6
p s.skip(/./) #=> nil
//}... -
StringScanner
# skip _ until(regexp) -> Integer | nil (30107.0) -
regexp が一致するまで文字列をスキャンします。 マッチに成功したらスキャンポインタを進めて、 スキャン開始位置からマッチ部分の末尾までの部分文字列の長さを返します。 マッチに失敗したら nil を返します。
...nil を返します。
@param regexp マッチに使用する正規表現を指定します。
//emlist[例][ruby]{
require 'strscan'
s = StringScanner.new('test string')
s.scan_until(/str/) # => 8
s.matched # => "str"
s.pos # => 8
s.pre_match # => "test "
//}... -
StringScanner
# scan _ full(regexp , s , f) -> object (21078.0) -
スキャンポインタの位置から regexp と文字列のマッチを試します。
...scan_full(regexp, true, true) は StringScanner#scan と同等。
* scan_full(regexp, true, false) は StringScanner#skip と同等。
* scan_full(regexp, false, true) は StringScanner#check と同等。
* scan_full(regexp, false, false) は StringScanner#match? と同等。
@param reg......n'
s = StringScanner.new('test string')
p s.scan_full(/\w+/, true, true) #=> "test"
p s.scan_full(/\s+/, false, true) #=> " "
p s.scan_full(/\s+/, true, false) #=> 1
p s.scan_full(/\w+/, false, false) #=> 6
p s.scan_full(/\w+/, true, true) #=> "string"
//}
@see StringScanner#scan S......tringScanner#skip StringScanner#check StringScanner#match?... -
StringScanner
# search _ full(regexp , s , f) -> object (21078.0) -
regexp で指定された正規表現とマッチするまで文字列をスキャンします。
...gexp, true, true) は StringScanner#scan_until と同等。
* search_full(regexp, true, false) は StringScanner#skip_until と同等。
* search_full(regexp, false, true) は StringScanner#check_until と同等。
* search_full(regexp, false, false) は StringScanner#exist? と同等。......s = StringScanner.new('test string')
p s.search_full(/t/, true, true) #=> "t"
p s.search_full(/str/, false, true) #=> "est str"
p s.search_full(/string/, true, true) #=> "est string"
//}
@see StringScanner#scan_until StringScanner#skip_until StringScanner#check_until StringScanner#ex... -
NEWS for Ruby 3
. 0 . 0 (24.0) -
NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...et
* Add :connect_timeout to TCPSocket.new 17187
* Net::HTTP
* Net::HTTP#verify_hostname= and Net::HTTP#verify_hostname have been added to skip hostname verification. 16555
* Net::HTTP.get, Net::HTTP.get_response, and Net::HTTP.get_print can take the request headers as a Hash in the s......RubyGems
* Update to RubyGems 3.2.3
* StringIO
* Update to StringIO 3.0.0
* This version is Ractor compatible.
* StringScanner
* Update to StringScanner 3.0.0
* This version is Ractor compatible.
== Compatibility issues
Excluding feature bug fixes.
* Regexp literals and......e size of hot paths by some optimizations and partitioning cold paths.
* Instance variables
* Eliminate some redundant checks.
* Skip checking a class and a object multiple times in a method when possible.
* Optimize accesses in some core classes like Hash and their subcl...