Libraryless. Click here for Pure Java version (2707L/16K).
1 | static <A> void syncReplaceCollection(Cl<A> dest, Cl<A> src) { |
2 | if (dest == src) ret; |
3 | synchronized(collectionMutex(dest)) { |
4 | dest.clear(); |
5 | if (src != null) dest.addAll(src); |
6 | } |
7 | } |
Began life as a copy of #1002097
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt
No comments. add comment
Snippet ID: | #1030657 |
Snippet name: | syncReplaceCollection - replaceCollection synchronizing on target collection |
Eternal ID of this version: | #1030657/1 |
Text MD5: | 65497e723754e4fd95efc779118f5599 |
Transpilation MD5: | 86c3ee756acd4abba87dd5bbf578b6b8 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2021-02-20 16:15:06 |
Source code size: | 195 bytes / 7 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 173 / 239 |
Referenced in: | [show references] |