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

8
LINES

< > BotCompany Repo | #1019864 // setVar_returnPrevious

JavaX fragment (include)

static <A> A setVar_returnPrevious(IVar<A> v, A value) {
  if (v == null) null;
  synchronized(v) {
    A prev = v!;
    v.set(value);
    ret prev;
  }
}

Author comment

Began life as a copy of #1016371

download  show line numbers  debug dex  old transpilations   

Travelled to 9 computer(s): bhatertpkbcr, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1019864
Snippet name: setVar_returnPrevious
Eternal ID of this version: #1019864/1
Text MD5: 7624e238ae17614ac35878a5ee884b40
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-11-29 09:14:02
Source code size: 161 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 281 / 300
Referenced in: [show references]