static L<S> splitAtJavaTokens(S s, S... splitTokens) {
L<S> tok = javaTok(s);
new L<S> l;
int i = 1;
while (i < l(tok)) {
int j = smartIndexOfAny(tok, i, splitTokens);
l.add(join(subList(tok, i, j-1)));
i = j+2;
}
ret l;
}Began life as a copy of #1002271
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: | #1012192 |
| Snippet name: | splitAtJavaTokens - allows each of the tokens to be a separator |
| Eternal ID of this version: | #1012192/1 |
| Text MD5: | 38e30ab9fe02e3fe217c5e2ad3bd2f9b |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2017-11-23 18:23:49 |
| Source code size: | 256 bytes / 11 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 873 / 841 |
| Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |