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

6
LINES

< > BotCompany Repo | #1010811 // uniqueByField_favorLast

JavaX fragment (include)

static <A> L<A> uniqueByField_favorLast(Collection<A> l, S field) {
  new LinkedHashMap<O, A> map;
  if (l != null) for (A a : l)
    map.put(getOpt(a, field), a);
  ret asList(values(map));
}

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: #1010811
Snippet name: uniqueByField_favorLast
Eternal ID of this version: #1010811/1
Text MD5: 40f16adfc8ab40755a80d989ee7d53f4
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-10-03 22:41:22
Source code size: 197 bytes / 6 lines
Pitched / IR pitched: No / No
Views / Downloads: 503 / 498
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)