Skip to content

Commit 1868cd0

Browse files
authored
docs: add example properties (and classes)
1 parent 6e63802 commit 1868cd0

File tree

1 file changed

+101
-1
lines changed

1 file changed

+101
-1
lines changed

README.md

Lines changed: 101 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,101 @@
1-
# vd-from-properties-parser
1+
# vd-from-properties-parser
2+
3+
## examples
4+
5+
### Collection
6+
7+
* inline
8+
```
9+
collection=a,b,c
10+
```
11+
* using integer index
12+
13+
```
14+
collection.0=a
15+
collection.1=b
16+
collection.3=c
17+
```
18+
* using any index
19+
```
20+
collection.a=a
21+
collection.b=b
22+
collection.z=c
23+
```
24+
* with recursion
25+
```
26+
collection.0.string=a
27+
collection.1.string=b
28+
```
29+
<details>
30+
<summary>view classes</summary>
31+
32+
### MyObject
33+
```js
34+
public class MyObject {
35+
public Collection<MySubObject> collection;
36+
}
37+
```
38+
39+
### MySubObject
40+
```js
41+
public class MySubObject {
42+
public String string;
43+
}
44+
```
45+
</details>
46+
47+
48+
### Map
49+
50+
* inline
51+
```
52+
map.abc=123
53+
```
54+
* using any index and explicit key and value
55+
```
56+
map.0.key=abc
57+
map.0.value=123
58+
```
59+
* with recursion
60+
```
61+
map.0.key.string=a
62+
map.0.value.string=1
63+
```
64+
<details>
65+
<summary>view classes</summary>
66+
67+
### MyObject
68+
```js
69+
public class MyObject {
70+
public Map<MySubObject, MySubObject> map;
71+
}
72+
```
73+
74+
### MySubObject
75+
```js
76+
public class MySubObject {
77+
public String string;
78+
}
79+
```
80+
</details>
81+
82+
### inheritance
83+
84+
* specify implementing Class for an interface
85+
```
86+
object.class=MyImplementation
87+
object.string=abc
88+
```
89+
<details>
90+
<summary>view classes</summary>
91+
92+
### MyInterface
93+
```js
94+
public interface MyInterface {}
95+
```
96+
97+
### MyImplementation
98+
```js
99+
public class MyImplementation implements MyInterface {}
100+
```
101+
</details>

0 commit comments

Comments
 (0)