Libraryless. Click here for Pure Java version (18305L/131K).
!7 sclass MatchInput > DynPrintLogWithInput { start { dm_useLocallyCopiedMechLists(); } void update(S s) { print("\n> " + s); L<S> tok = printStruct(javaTokWithAngleBracketsC(s)); PlanInMotion<S> plan = new(mech_englishSentencePatterns()); L<Pair<S, L<PairS>>> results = new L; // pattern + match for (S pat : plan.master()) ai_matchAngleBracketPattern_toResults(pat, tok, results); for (Pair<S, L<PairS>> p : sortedByLengthOfPairBList(results)) print(" Result: Choose pattern " + quote(p.a) + " for input " + quote(s) + " if match: " + ai_renderMatch(p.b)); } }
Began life as a copy of #1017205
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1017207 |
| Snippet name: | Match Input With Pattern v3 shortened |
| Eternal ID of this version: | #1017207/19 |
| Text MD5: | 6eb7113255d849065b9300b6554b0e67 |
| Transpilation MD5: | b270291d56db7f11f7fd6140deaf3048 |
| Author: | stefan |
| Category: | javax / a.i. |
| Type: | JavaX source code (Dynamic Module) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2018-07-16 14:20:13 |
| Source code size: | 627 bytes / 17 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 720 / 1244 |
| Version history: | 18 change(s) |
| Referenced in: | [show references] |