|
|
1.1 misha 1: @main[]
2:
3: <pre>
4: ^json:string[
5: $.h[
6: $.a[aa]
7: $.b[bb]
8: $.c(33)
9: ]
10:
11: $.string[s]
12: $.number(1)
13:
14: $.c_object[^c::create[]]
15: $.d_object[^d::create[]]
16:
17: $.x_class[$x:CLASS]
18: $.x_object[^x::create[]]
19:
20: $.y_class[$y:CLASS]
21: $.y_object[^y::create[]]
22:
23: $.yy_class[$yy:CLASS]
24: $.yy_object[^yy::create[]]
25:
26: $.z_object1[^z::create[object_z_value1]]
27: $.z_object2[^z::create[object_z_value2]]
1.2 ! moko 28:
! 29: $.buggy_string[test ‧
‰ string - testing bug #1023]
1.1 misha 30: ;
31: $.indent(true)
32: $.c[$serialization_method]
33: $._default[json]
34: ]
35: </pre>
36:
37:
38: @serialization_method[key;value;params]
39: "object of class $value.CLASS_NAME" ($value.class_c/$value.object_c/$value.class_d)
40:
41:
42: @CLASS
43: c
44:
45: @auto[]
46: $self.class_c[class_c_value]
47:
48: @create[]
49: $self.object_c[object_c_value]
50:
51:
52: @CLASS
53: d
54:
55: @BASE
56: c
57:
58: @auto[]
59: $self.class_d[class_d_value]
60:
61:
62: @CLASS
63: x
64:
65: @auto[]
66: $self.class_x[class_x_value]
67:
68: @create[]
69: $self.object_x[object_x_value]
70:
71: # no json method in class so use default hash-serialization
72: #@json[]
73:
74:
75: @CLASS
76: y
77:
78: @auto[]
79: $self.class_y[class_y_value]
80:
81: @create[]
82:
83: @json[k;o]
84: "^if(^reflection:dynamical[]){obj}{class} of $self.CLASS_NAME ($self.class_y)"
85:
86:
87:
88: @CLASS
89: yy
90:
91: @BASE
92: y
93:
94:
95: @CLASS
96: z
97:
98: @BASE
99: y
100:
101: @create[value]
102: ^BASE:create[]
103: $self.object_z[$value]
104:
105: @json[k;o]
106: "^if(^reflection:dynamical[]){obj}{class} of $self.CLASS_NAME ($self.class_y/$self.object_z)"
107: