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

6
LINES

< > BotCompany Repo | #1011024 // mapFromKeyAndValueField

JavaX fragment (include)

static Map mapFromKeyAndValueField(Collection l, S keyField, S valueField) {
  new LinkedHashMap map;
  for (O o : l)
    mapPut(map, getOpt(o, keyField), getOpt(o, valueField));
  ret 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: #1011024
Snippet name: mapFromKeyAndValueField
Eternal ID of this version: #1011024/1
Text MD5: 7563a127fdab21677324c34090f01af7
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-10-11 19:04:05
Source code size: 196 bytes / 6 lines
Pitched / IR pitched: No / No
Views / Downloads: 457 / 477
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)
#1020014 - ciMapFromKeyAndValueField