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

10
LINES

< > BotCompany Repo | #1026270 // shallowCloneToUnlistedConcept

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (23701L/143K).

1  
static <A extends Concept> A nuLike shallowCloneToUnlistedConcept(Class<A> c, Concept o) {
2  
  if (o == null) null;
3  
  A cc = unlisted(c);
4  
  ccopyFields(o, cc);
5  
  ret cc;
6  
}
7  
8  
static <A extends Concept> A shallowCloneToUnlistedConcept(A o) {
9  
  ret o == null ? null : (A) shallowCloneToUnlistedConcept(o.getClass(), o);
10  
}

Author comment

Began life as a copy of #1026269

download  show line numbers  debug dex  old transpilations   

Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv

No comments. add comment

Snippet ID: #1026270
Snippet name: shallowCloneToUnlistedConcept
Eternal ID of this version: #1026270/9
Text MD5: 02be482a2eaaac1553f832dd97af28fb
Transpilation MD5: 33b0d97d4080bd7e7f9cd641c1d1fb2a
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2023-11-18 22:41:02
Source code size: 326 bytes / 10 lines
Pitched / IR pitched: No / No
Views / Downloads: 211 / 342
Version history: 8 change(s)
Referenced in: [show references]