Annotation of parser3/tests/224.html, revision 1.2
1.1 misha 1: @USE
2: 224.p
3:
4:
5: @main[]
6: $h[^reflection:classes[]]
7: $hi[^h.intersection[
8: $.hash[]
9: $.env[]
10: $.cookie[]
11: $.table[]
12: $.test[]
13: $.test1[]
14: $.test2[]
15: ]]
1.2 ! misha 16: $t[^hi._keys[]]
! 17: ^t.sort{$t.key}
! 18: ^t.menu{$t.key^if(def $hi.[$t.key]){ - $hi.[$t.key]}}[<br />]
1.1 misha 19: <hr />
20:
21: ^do{$d[^reflection:create[date;create]]}
22: ^do{$d[^reflection:create[date;calendar]]}
23: ^do{$d[^reflection:create[date;now](-2;1)]}
24: ^do{$d[^reflection:create[date;now](-2)]}
25:
26: ^do{$o[^reflection:create[test;create](-1)]}
27: ^do{$o1[^reflection:create[test1;create1](1)]}
28: ^do{$o2[^reflection:create[test2;create2]]}
29: <hr />
30:
31: ^reflection:class_name[$hash:CLASS]<br />
32: ^reflection:class_name[$cookie:CLASS]<br />
33: ^reflection:class_name[$env:CLASS]<br />
34: <hr />
35:
36: ^print[test;$o]
37: ^print[test1;$o1]
38: ^print[test2;$o2]
39: ^print[date;$d]
40: ^print[env;$env:CLASS]
41: ^print[unknown]
42: done.
43:
44:
45:
46: @do[code]
47: ^try{
48: $code
49: }{
50: $exception.handled(1)
51: $exception.source
52: $exception.comment
53: <br />
54: }
55:
56:
57:
1.2 ! misha 58: @print[class;o][m;k;v;h;i;t]
1.1 misha 59: ^do{
60: $m[^reflection:methods[$class]]
1.2 ! misha 61: $t[^m._keys[]]
! 62: ^t.sort{$t.key}
! 63: ^t.menu{
! 64: $k[$t.key]
! 65: $v[$m.$k]
1.1 misha 66: $h[^reflection:method_params[$class;$k]]
67: ^@${k}[^if($v eq "native"){^if($h.min_params != $h.max_params){^h.min_params.int(0)-}^h.max_params.int(0)}{^for[i](0;^h._count[]){$h.$i}[^;]}]^if(def $h.call_type){ {$h.call_type}}
68: }[<br />]
69: }
70: ^if(def $o){
71: ^if($m){<br /><br />}
72: '$class' object class name: '^reflection:class_name[$o]/^reflection:class_name[^reflection:class[$o]]'<br />
73: '$class' object base class name: '^reflection:base_name[$o]/^if(^reflection:base[$o] is "void"){;^reflection:class_name[^reflection:base[$o]]}'<br />
74: }
75: <hr />
76:
E-mail: