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

11
LINES

< > BotCompany Repo | #1016881 // pred_fileSizeChanged - predicate that becomes true once when file size changes

JavaX fragment (include)

static F0<Bool> pred_fileSizeChanged(final File f) {
  ret new F0<Bool>() {
    long lastSize = fileSize(f);
    
    public Bool get() {
      long size = fileSize(f);
      if (size == lastSize) false;
      ret true with lastSize = size;
    }
  };
}

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1016881
Snippet name: pred_fileSizeChanged - predicate that becomes true once when file size changes
Eternal ID of this version: #1016881/2
Text MD5: 1e49df40b1c2a044fbd4bf11e87c2112
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-07-06 16:10:14
Source code size: 263 bytes / 11 lines
Pitched / IR pitched: No / No
Views / Downloads: 248 / 285
Version history: 1 change(s)
Referenced in: [show references]