1 | static S regexpFirstGroup_lastMatch(S pat, S s) { |
2 | Matcher m = Pattern.compile(pat).matcher(s); |
3 | S group = null; |
4 | while (m.find()) group = m.group(1); |
5 | ret group; |
6 | } |
Began life as a copy of #1007002
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1009088 |
Snippet name: | regexpFirstGroup_lastMatch - make Java regexp Matcher and return first group matched in last match |
Eternal ID of this version: | #1009088/4 |
Text MD5: | 22220e79b95e91c618d48b82783a2524 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2017-07-02 17:07:18 |
Source code size: | 173 bytes / 6 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 465 / 509 |
Version history: | 3 change(s) |
Referenced in: | [show references] |