Libraryless. Click here for Pure Java version (2524L/16K).
1 | static <A, B> L<A> cloneAndClearKeys(Map<A, B> map) { |
2 | if (map == null) ret emptyList(); |
3 | synchronized(collectionMutex(map)) { |
4 | L<A> out = keysList(map); |
5 | map.clear(); |
6 | ret out; |
7 | } |
8 | } |
Began life as a copy of #1016570
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv
No comments. add comment
Snippet ID: | #1029538 |
Snippet name: | cloneAndClearKeys |
Eternal ID of this version: | #1029538/3 |
Text MD5: | e025ef3ffecbb0d731a8b592ec8f9ed4 |
Transpilation MD5: | baea31d49ff71e8f45a1a208ea9ca09a |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2020-08-18 14:15:24 |
Source code size: | 201 bytes / 8 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 236 / 332 |
Version history: | 2 change(s) |
Referenced in: | [show references] |