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

13
LINES

< > BotCompany Repo | #1028974 - mmGetAllAsSet

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

Libraryless. Click here for Pure Java version (2805L/17K).

1  
static <A, B> Set<B> mmGetAllAsSet(MultiMap<A, B> mm, A... keys) {
2  
  new Set<B> l;
3  
  for (A key : keys)
4  
    l.addAll(mm.get(key));
5  
  ret l;
6  
}
7  
8  
static <A, B> Set<B> mmGetAllAsSet(MultiMap<A, B> mm, Iterable<A> keys) {
9  
  new Set<B> l;
10  
  fOr (A key : keys)
11  
    l.addAll(mm.get(key));
12  
  ret l;
13  
}

Author comment

Began life as a copy of #1014562

download  show line numbers  debug dex   

Travelled to 5 computer(s): bhatertpkbcr, mqqgnosmbjvj, pzhvpgtvlbxg, tvejysmllsmz, xrpafgyirdlv

No comments. add comment

Snippet ID: #1028974
Snippet name: mmGetAllAsSet
Eternal ID of this version: #1028974/1
Text MD5: 0213e2ffeac6cf9f7d0964a9b306b68a
Transpilation MD5: cea4ac51f77cab650eb67833d01bb8f2
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2020-07-15 01:48:06
Source code size: 303 bytes / 13 lines
Pitched / IR pitched: No / No
Views / Downloads: 13 / 32
Referenced in: [show references]

Formerly at http://tinybrain.de/1028974 & http://1028974.tinybrain.de