Libraryless. Click here for Pure Java version (13682L/93K).
1 | static <A extends Concept> A nuLike lowestConceptByField(Class<A> c, S field) {
|
2 | ret lowestConceptByField(db_mainConcepts(), c, field); |
3 | } |
4 | |
5 | static <A extends Concept> A lowestConceptByField(Concepts concepts, Class<A> c, S field) {
|
6 | // indexed |
7 | IFieldIndex<A, O> index = concepts.getFieldIndex(c, field); |
8 | if (index cast ConceptFieldIndexDesc) {
|
9 | Map.Entry e = ((NavigableMap) index.valueToObject.data).lastEntry(); |
10 | ret e == null ? null : (A) first((Cl) e.getValue()); |
11 | } |
12 | ret lowestByField(field, concepts.list(c)); |
13 | } |
Began life as a copy of #1029652
download show line numbers debug dex old transpilations
Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1029654 |
| Snippet name: | lowestConceptByField |
| Eternal ID of this version: | #1029654/5 |
| Text MD5: | f02a0e13a2329d6b6a81d63f8cdcd3c3 |
| Transpilation MD5: | d82abe66c700a5a905b6f9c7fa0166a9 |
| Author: | stefan |
| Category: | javax / concepts |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2020-09-04 22:05:46 |
| Source code size: | 542 bytes / 13 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 390 / 523 |
| Version history: | 4 change(s) |
| Referenced in: | [show references] |