Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

6
LINES

< > BotCompany Repo | #1008641 // ai_makeSubjectAction

JavaX fragment (include)

static S ai_makeSubjectAction(S text, IntRange r) {
  if (r == null) null;
  int i = trimIndexRight(text, r.start);
  int j = trimIndexLeft(text, r.end);
  ret j <= i ? null : "subject=" + quote(substring(text, i, j)) + " (" + i + "/" + (j-i) + ")";
}

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: #1008641
Snippet name: ai_makeSubjectAction
Eternal ID of this version: #1008641/1
Text MD5: c92839a136fa7a10fbcc61f18fb81d27
Author: stefan
Category: javax / a.i.
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-05-26 17:09:41
Source code size: 256 bytes / 6 lines
Pitched / IR pitched: No / No
Views / Downloads: 439 / 461
Referenced in: [show references]