Libraryless. Click here for Pure Java version (3356L/18K).
1 | static <A> A withSaveTime(Timed dest, IF0<A> f) { |
2 | long time = nanos(); |
3 | A a = f.get(); |
4 | time = nanos()-time; |
5 | if (dest != null) |
6 | dest.ms = nsToMS(time); |
7 | ret a; |
8 | } |
download show line numbers debug dex old transpilations
Travelled to 3 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx
No comments. add comment
Snippet ID: | #1032039 |
Snippet name: | withSaveTime |
Eternal ID of this version: | #1032039/1 |
Text MD5: | a5462d182c938870a309ae9c5c90076f |
Transpilation MD5: | 39b999d02c952a5eaf44db6cb4a662cc |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2021-08-11 04:51:57 |
Source code size: | 178 bytes / 8 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 159 / 222 |
Referenced in: | [show references] |