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

9
LINES

< > BotCompany Repo | #1006323 // collectHashSet

JavaX fragment (include)

1  
static HashSet collectHashSet(Collection c, S field) {
2  
  new HashSet set;
3  
  for (O a : c) {
4  
    O val = getOpt(a, field);
5  
    if (val != null)
6  
      set.add(val);
7  
  }
8  
  ret set;
9  
}

Author comment

Began life as a copy of #1002504

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1006323
Snippet name: collectHashSet
Eternal ID of this version: #1006323/1
Text MD5: 3dbb3116adf829cbd20d35d4c6051fa8
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2016-12-28 19:57:12
Source code size: 187 bytes / 9 lines
Pitched / IR pitched: No / No
Views / Downloads: 399 / 421
Referenced in: [show references]