Download Jar. Uses 3874K of libraries. Click here for Pure Java version (5556L/40K).
1 | !7 |
2 | |
3 | p-exp {
|
4 | final L<VF1<O>> analyzers = ll( |
5 | voidfunc(O o) { if (o instanceof S) emit("It's a string"); },
|
6 | voidfunc(O o) { if (o instanceof Number) emit("It's a number"); },
|
7 | voidfunc(O o) { emit("className=" + className(o)); },
|
8 | voidfunc(O o) { if (o == null) emit("It's null"); },
|
9 | ); |
10 | |
11 | for (fO o : ll("hello", 123)) {
|
12 | print(o + " - " + getEmits(r { for (O analyzer : analyzers) callF(analyzer, o); }));
|
13 | } |
14 | } |
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: | #1017054 |
| Snippet name: | Inspecting objects |
| Eternal ID of this version: | #1017054/7 |
| Text MD5: | b474330dd63a540fe76aece002e3a93b |
| Transpilation MD5: | e7eed1e24996ed190caf6c8af2ad5d05 |
| Author: | stefan |
| Category: | javax / parsing |
| Type: | JavaX source code (desktop) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2018-07-11 15:23:54 |
| Source code size: | 449 bytes / 14 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 717 / 1795 |
| Version history: | 6 change(s) |
| Referenced in: | [show references] |