1 | static <A> void linkVarsVerbose(IVarWithNotify<A> var1, IVarWithNotify<A> var2) { |
2 | if (var1 == null || var2 == null) ret; |
3 | var2.onChange(value -> { |
4 | print("linkVars: Setting var1 to " + value); |
5 | var1.set(value); |
6 | }); |
7 | var1.onChangeAndNow(value -> { |
8 | print("linkVars: Setting var2 to " + value); |
9 | var2.set(value); |
10 | }); |
11 | } |
Began life as a copy of #1034554
download show line numbers debug dex old transpilations
Travelled to 3 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj
No comments. add comment
Snippet ID: | #1034555 |
Snippet name: | linkVarsVerbose |
Eternal ID of this version: | #1034555/1 |
Text MD5: | 9cbcd4b6f99e54a7324d80a948d83d7c |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2022-02-12 22:54:21 |
Source code size: | 346 bytes / 11 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 172 / 174 |
Referenced in: | [show references] |