Libraryless. Click here for Pure Java version (20247L/122K).
static <A extends Concept> L<A> deleteOldConcepts(Concepts cc default db_mainConcepts(), Class<A> conceptClass, double minAgeInSeconds) { new L<A> deleted; for (A c : cloneList(list(cc, conceptClass))) if (max(c._modified, c.created) < now()-toMS(minAgeInSeconds)) { print("Deleting concept " + c); deleted.add(c); cdelete(c); } ret deleted; }
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, ekrmjmnbrukm, mowyntqkapby, mqqgnosmbjvj
No comments. add comment
Snippet ID: | #1034444 |
Snippet name: | deleteOldConcepts |
Eternal ID of this version: | #1034444/3 |
Text MD5: | 4ae443cf7b004f62ed9c7cfc769a6129 |
Transpilation MD5: | 174243197e2830368fbc7aaf9c111652 |
Author: | stefan |
Category: | javax / concepts |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2022-02-07 22:10:01 |
Source code size: | 387 bytes / 11 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 143 / 222 |
Version history: | 2 change(s) |
Referenced in: | [show references] |