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

9
LINES

< > BotCompany Repo | #1012468 // assertIsStringArrayList

JavaX fragment (include)

static ArrayList<S> assertIsStringArrayList(O o) {
  if (!o instanceof ArrayList)
    fail("Not an ArrayList: " + className(o));
  ArrayList l = cast o;
  for (O x : l)
    if (!x instanceof S)
      fail("Not a string: " + className(x));
  ret l;
}

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1012468
Snippet name: assertIsStringArrayList
Eternal ID of this version: #1012468/3
Text MD5: 918b215791d3c429fb4af65a2dc83cff
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-12-03 21:24:43
Source code size: 257 bytes / 9 lines
Pitched / IR pitched: No / No
Views / Downloads: 367 / 379
Version history: 2 change(s)
Referenced in: [show references]