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

7
LINES

< > BotCompany Repo | #1034802 // uniquifyUsingHasher

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (20439L/124K).

1  
// A: object type
2  
// B: hash type (e.g. Long)
3  
// The hasher is just for speeding up the process.
4  
// Every object is also checked using eq() among those with the same hash.
5  
static <A, B> L<A> lambdaMapLike uniquifyUsingHasher(IF1<A, B> hasher, Iterable<A> l) {
6  
  ret new UniquifyUsingHasher(hasher).addAll(l)!;
7  
}

Author comment

Began life as a copy of #1034799

download  show line numbers  debug dex  old transpilations   

Travelled to 3 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1034802
Snippet name: uniquifyUsingHasher
Eternal ID of this version: #1034802/2
Text MD5: a7451a11152a63a99870fb8e890bb39b
Transpilation MD5: ad9124b8a22147bb39fc3d8b663cc9b3
Author: stefan
Category: javax / imaging
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-03-10 19:38:07
Source code size: 317 bytes / 7 lines
Pitched / IR pitched: No / No
Views / Downloads: 132 / 191
Version history: 1 change(s)
Referenced in: [show references]