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

6
LINES

< > BotCompany Repo | #1009516 // migrateList - move all elements of one collection to another

JavaX fragment (include)

static <A> void migrateList(Collection<? extends A> a, Collection<A> b) {
  if (b != null && a != null) {
    b.addAll(a);
    a.clear();
  }
}

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: #1009516
Snippet name: migrateList - move all elements of one collection to another
Eternal ID of this version: #1009516/2
Text MD5: 2424be1a6ffa325b0165edeb947e8ec2
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-09-22 18:36:05
Source code size: 148 bytes / 6 lines
Pitched / IR pitched: No / No
Views / Downloads: 461 / 502
Version history: 1 change(s)
Referenced in: [show references]