Libraryless. Click here for Pure Java version (31L/1K).
1 | static <A> long getOrCreate_long(Map<A, Long> map, A key) {
|
2 | Long b = map.get(key); |
3 | if (b == null) |
4 | map.put(key, b = 0L); |
5 | ret b; |
6 | } |
Began life as a copy of #1024526
download show line numbers debug dex old transpilations
Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1025545 |
| Snippet name: | getOrCreate_long |
| Eternal ID of this version: | #1025545/13 |
| Text MD5: | 0f0ae1a808541bbfa768a0eafb562e44 |
| Transpilation MD5: | 9e0e3310d21325cd8feb790baf21c516 |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2019-10-03 13:05:13 |
| Source code size: | 143 bytes / 6 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 455 / 644 |
| Version history: | 12 change(s) |
| Referenced in: | [show references] |