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

21
LINES

< > BotCompany Repo | #1006288 // done2 - print elapsed time (expects parameter taken from sysNow())

JavaX fragment (include)

static int done2_minPrint = 10;

static long done2(long startTime, S desc) {
  ret done2(startTime, desc, done2_minPrint);
}

static long done2(long startTime, S desc, int minPrint) {
  long time = sysNow()-startTime;
  saveTiming_noPrint(time);
  if (time >= minPrint)
    print(desc + " [" + time + " ms]");
  ret time;
}

static long done2(S desc, long startTime) {
  ret done2(startTime, desc);
}

static long done2(long startTime) {
  ret done2(startTime, "");
}

Author comment

Began life as a copy of #1003960

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1006288
Snippet name: done2 - print elapsed time (expects parameter taken from sysNow())
Eternal ID of this version: #1006288/7
Text MD5: 2eb0b7c26de2a63a6e89d12a45475853
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-07-10 15:08:51
Source code size: 487 bytes / 21 lines
Pitched / IR pitched: No / No
Views / Downloads: 519 / 544
Version history: 6 change(s)
Referenced in: [show references]