diff options
Diffstat (limited to 'src/org/json/simple/parser/ContainerFactory.java')
-rw-r--r-- | src/org/json/simple/parser/ContainerFactory.java | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/org/json/simple/parser/ContainerFactory.java b/src/org/json/simple/parser/ContainerFactory.java new file mode 100644 index 0000000..182a899 --- /dev/null +++ b/src/org/json/simple/parser/ContainerFactory.java | |||
@@ -0,0 +1,26 @@ | |||
1 | package org.json.simple.parser; | ||
2 | |||
3 | import java.util.List; | ||
4 | import java.util.Map; | ||
5 | |||
6 | /** | ||
7 | * Container factory for creating containers for JSON object and JSON array. | ||
8 | * | ||
9 | * @see org.json.simple.parser.JSONParser#parse(java.io.Reader, | ||
10 | * ContainerFactory) | ||
11 | * | ||
12 | * @author FangYidong<fangyidong@yahoo.com.cn> | ||
13 | */ | ||
14 | public interface ContainerFactory { | ||
15 | /** | ||
16 | * @return A Map instance to store JSON object, or null if you want to use | ||
17 | * org.json.simple.JSONObject. | ||
18 | */ | ||
19 | Map<?, ?> createObjectContainer(); | ||
20 | |||
21 | /** | ||
22 | * @return A List instance to store JSON array, or null if you want to use | ||
23 | * org.json.simple.JSONArray. | ||
24 | */ | ||
25 | List<?> creatArrayContainer(); | ||
26 | } | ||