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

3
LINES

< > BotCompany Repo | #1037260 // threadAsCloseable

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

Libraryless. Click here for Pure Java version (10699L/59K).

static CloseableWrapper<Thread> threadAsCloseable(Thread t) {
  ret t == null ?: new CloseableWrapper<Thread>(t, -> cancelThread(t));
}

download  show line numbers  debug dex  old transpilations   

Travelled to 2 computer(s): gjtlkbvenryc, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1037260
Snippet name: threadAsCloseable
Eternal ID of this version: #1037260/4
Text MD5: 1c27562eb9d86f6f94a5004f86180bc9
Transpilation MD5: ff4f327b0a4705964185d247066f813e
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2023-10-22 15:55:00
Source code size: 137 bytes / 3 lines
Pitched / IR pitched: No / No
Views / Downloads: 48 / 80
Version history: 3 change(s)
Referenced in: [show references]