Libraryless. Click here for Pure Java version (1988L/13K).
sS makeAGIDomainPart(S s) { // OLD version: LS tok = unquoteAll(wordTokC_noBrackets(trim(s))); LS tok = cloneList(wordTok2(s)); for (int i = 2; i < l(tok)-2; i += 2) tok.set(i, containsNewLine(tok.get(i)) ? "--" : "-"); setFirstAndLast(tok, ""); ret replaceAll(join(tok), "'", ""); }
Began life as a copy of #1023575
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, cfunsshuasjs, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1023590 |
Snippet name: | makeAGIDomainPart - convert any string into an AGI domain part |
Eternal ID of this version: | #1023590/7 |
Text MD5: | e7046deae40b38b0b7de7ccc26546db8 |
Transpilation MD5: | bbd70fed137948d79785da8b67255de9 |
Author: | stefan |
Category: | javax / a.i. |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-07-04 21:40:13 |
Source code size: | 304 bytes / 8 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 373 / 469 |
Version history: | 6 change(s) |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |