1 | static <A extends Concept> A nuLike findConceptWhereCI(Class<A> c, O... params) { |
2 | ret findConceptWhereCI(db_mainConcepts(), c, params); |
3 | } |
4 | |
5 | static <A extends Concept> A findConceptWhereCI(Concepts concepts, Class<A> c, O... params) { |
6 | params = expandParams(c, params); |
7 | |
8 | // indexed |
9 | if (concepts.ciFieldIndices != null) |
10 | for (int i = 0; i < l(params); i += 2) { |
11 | IFieldIndex<A, O> index = concepts.getCIFieldIndex(c, (S) params[i]); |
12 | if (index != null) { |
13 | for (A x : index.getAll(params[i+1])) |
14 | if (checkConceptFieldsIC(x, params)) ret x; |
15 | null; |
16 | } |
17 | } |
18 | |
19 | // table scan |
20 | for (A x : concepts.list(c)) if (checkConceptFieldsIC(x, params)) ret x; |
21 | null; |
22 | } |
23 | |
24 | static Concept findConceptWhereCI(Concepts concepts, S c, O... params) { |
25 | for (Concept x : concepts.list(c)) if (checkConceptFieldsIC(x, params)) ret x; |
26 | null; |
27 | } |
Began life as a copy of #1023276
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt
No comments. add comment
Snippet ID: | #1031012 |
Snippet name: | findConceptWhereCI - backup |
Eternal ID of this version: | #1031012/1 |
Text MD5: | 55746883f1a5bc63bf15abce770a815d |
Author: | stefan |
Category: | javax / concepts |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2021-04-20 18:41:35 |
Source code size: | 900 bytes / 27 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 159 / 194 |
Referenced in: | [show references] |