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

14
LINES

< > BotCompany Repo | #1005537 // snippetsWithTitles - uses cached version of titles

JavaX fragment (include)

1  
// A = S or Snippet
2  
static <A> L<S> snippetsWithTitles(L<A> l) {
3  
  ifclass Snippet
4  
    if (first(l) instanceof Snippet)
5  
      ret map snippetWithTitle_cached((L<Snippet>) l);
6  
  endif
7  
  L<S> ids = cast l;
8  
  final SS map = getSnippetTitles_cached(ids);
9  
  ret map(func(S id) -> S { fsI(id) + " - " + map.get(fsI(id)) }, ids);
10  
}
11  
12  
static S snippetsWithTitles(S... ids) {
13  
  ret join(", ", snippetsWithTitles(asList(ids)));
14  
}

Author comment

Began life as a copy of #1004807

download  show line numbers  debug dex  old transpilations   

Travelled to 15 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, ddnzoavkxhuk, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1005537
Snippet name: snippetsWithTitles - uses cached version of titles
Eternal ID of this version: #1005537/7
Text MD5: ddfcb94531adc0af1b1dbdaefb616a96
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-12-18 14:00:39
Source code size: 431 bytes / 14 lines
Pitched / IR pitched: No / No
Views / Downloads: 525 / 543
Version history: 6 change(s)
Referenced in: [show references]