Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

12
LINES

< > BotCompany Repo | #1016527 // clockTimeLiveValue

JavaX fragment (include)

1  
static LiveValue<S> clockTimeLiveValue() {
2  
  SimpleLiveValue<S> lv = stringLiveValue();
3  
  clockTimeLiveValue_update(new WeakReference(lv));
4  
  ret lv;
5  
}
6  
7  
svoid clockTimeLiveValue_update(final WeakReference<SimpleLiveValue<S>> lvRef) {
8  
  SimpleLiveValue<S> lv = lvRef!;
9  
  if (lv == null) ret;
10  
  lv.set(localTime_24());
11  
  doLater((timeToNextLocalMinute()+100) % 60000, r { clockTimeLiveValue_update(lvRef) });
12  
}

Author comment

Began life as a copy of #1016170

download  show line numbers  debug dex  old transpilations   

Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1016527
Snippet name: clockTimeLiveValue
Eternal ID of this version: #1016527/4
Text MD5: 5ac01afe2c9f6d6397de9e00924401e4
Author: stefan
Category: javax / gui
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-06-21 22:57:50
Source code size: 419 bytes / 12 lines
Pitched / IR pitched: No / No
Views / Downloads: 294 / 329
Version history: 3 change(s)
Referenced in: [show references]