Libraryless. Click here for Pure Java version (7978L/45K).
sbool isPersistableClass(Class c) { S name = c.getName(); if (isSubtypeOf(c, TransientObject)) false; if (isAnonymousClassName(name)) false; if (isBoxedType(c)) true; if (isArrayType(c)) true; if (c == Class.class || c == S || c == File || c == Color.class) true; if (name.startsWith("java.util.Collections$Synchronized")) true; if (hasThisDollarFields(c)) ret hasSingleArgumentConstructor(c); else ret getDefaultConstructor(c) != null; }
Began life as a copy of #1031499
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, ekrmjmnbrukm, mowyntqkapby, mqqgnosmbjvj
No comments. add comment
| Snippet ID: | #1033879 |
| Snippet name: | isPersistableClass |
| Eternal ID of this version: | #1033879/18 |
| Text MD5: | d7aed1c4177bc5ba25bce24fd289cb7b |
| Transpilation MD5: | 6a06e4e8d2f10da87a5818b0fcb96467 |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2022-05-01 21:03:57 |
| Source code size: | 480 bytes / 14 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 548 / 746 |
| Version history: | 17 change(s) |
| Referenced in: | [show references] |