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

7
LINES

< > BotCompany Repo | #1035434 // toTimestamp

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

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

static Timestamp toTimestamp(long unixTime) {
  ret unixTime == 0 ? null : Timestamp(unixTime);
}

static Timestamp toTimestamp(java.nio.file.attribute.FileTime fileTime) {
  ret fileTime == null ?: toTimestamp(fileTime.toMillis());
}

download  show line numbers  debug dex  old transpilations   

Travelled to 2 computer(s): mowyntqkapby, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1035434
Snippet name: toTimestamp
Eternal ID of this version: #1035434/5
Text MD5: 54894c9b6489c0448799a00675e6fb48
Transpilation MD5: 574c2e480db8f80f7ee8a0e376801868
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-12-11 19:40:59
Source code size: 240 bytes / 7 lines
Pitched / IR pitched: No / No
Views / Downloads: 83 / 125
Version history: 4 change(s)
Referenced in: [show references]