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

14
LINES

< > BotCompany Repo | #1036573 // steppableOnce

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (10059L/55K).

srecord noeq SteppableOnce(Runnable action) is Steppable {
  public bool step() {
    Runnable r = action;
    if (r != null) {
      action = null;
      r.run();
    }
    false;
  }
}

static Steppable steppableOnce(Runnable action) {
  ret new SteppableOnce(action);
}

download  show line numbers  debug dex  old transpilations   

Travelled to 2 computer(s): mqqgnosmbjvj, wnsclhtenguj

No comments. add comment

Snippet ID: #1036573
Snippet name: steppableOnce
Eternal ID of this version: #1036573/4
Text MD5: 1210fc9e2fee2465ae2b42201259f393
Transpilation MD5: e5f318706872412d53262575fc128552
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2023-03-14 19:00:35
Source code size: 285 bytes / 14 lines
Pitched / IR pitched: No / No
Views / Downloads: 140 / 205
Version history: 3 change(s)
Referenced in: [show references]