static S ai_html_renderWebShort(Web web) {
try {
int n = l(web_nodes(web));
if (n == 0) ret "Empty web";
WebNode a = web_firstNode(web);
if (n == 1) ret join(" = ", map html_encyclopediaTopic(web_texts(a)));
if (n == 2) {
WebNode b = web_secondNode(web);
WebRelation r= web_getRelationOpt(a, b);
if (r != null) ret ai_html_renderTriple(r);
}
ret "Includes " + joinWithComma(map html_encyclopediaTopic(map web_text(web_nodes(web))));
} catch print e {
ret "Error";
}
}Began life as a copy of #1011390
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1011565 |
| Snippet name: | ai_html_renderWebShort |
| Eternal ID of this version: | #1011565/1 |
| Text MD5: | da9a5481090b68ccea9c51e747894a75 |
| Author: | stefan |
| Category: | javax / a.i. |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2017-10-31 17:10:06 |
| Source code size: | 538 bytes / 16 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 871 / 881 |
| Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |