X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;ds=inline;f=src%2Forg%2Fjson%2Fsimple%2Fparser%2FContainerFactory.java;fp=src%2Forg%2Fjson%2Fsimple%2Fparser%2FContainerFactory.java;h=0bb7baf2d554e404d670cfd01dc168eb6da7a282;hb=6e56c166e45d1af37c5531b4cbe909a3e110927e;hp=0000000000000000000000000000000000000000;hpb=a38d5e32a02c5c470ea2a75bba26ac8f67b72ea2;p=jalview.git diff --git a/src/org/json/simple/parser/ContainerFactory.java b/src/org/json/simple/parser/ContainerFactory.java new file mode 100644 index 0000000..0bb7baf --- /dev/null +++ b/src/org/json/simple/parser/ContainerFactory.java @@ -0,0 +1,23 @@ +package org.json.simple.parser; + +import java.util.List; +import java.util.Map; + +/** + * Container factory for creating containers for JSON object and JSON array. + * + * @see org.json.simple.parser.JSONParser#parse(java.io.Reader, ContainerFactory) + * + * @author FangYidong + */ +public interface ContainerFactory { + /** + * @return A Map instance to store JSON object, or null if you want to use org.json.simple.JSONObject. + */ + Map createObjectContainer(); + + /** + * @return A List instance to store JSON array, or null if you want to use org.json.simple.JSONArray. + */ + List creatArrayContainer(); +}