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

9
LINES

< > BotCompany Repo | #1005019 // urlSize - get size of a file behind a URL [=getURLSizeByHEAD]

JavaX fragment (include)

// retrieves url with HEAD. returns content length,
// or -1 in case of error.
static long urlSize(S url) {
  ret getURLSizeByHEAD(url);
}

static long urlSize(URL url) {
  ret urlSize(str(url));
}

Author comment

Began life as a copy of #1004757

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1005019
Snippet name: urlSize - get size of a file behind a URL [=getURLSizeByHEAD]
Eternal ID of this version: #1005019/3
Text MD5: e12688963d9b4451b9d467b6fb790b9e
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-02-03 01:22:38
Source code size: 205 bytes / 9 lines
Pitched / IR pitched: No / No
Views / Downloads: 462 / 477
Version history: 2 change(s)
Referenced in: [show references]