use of com.alibaba.fastjson.parser.JSONReaderScanner in project fastjson by alibaba.
the class JSONReaderScannerTest_type method test_true.
@SuppressWarnings("rawtypes")
public void test_true() throws Exception {
DefaultJSONParser parser = new DefaultJSONParser(new JSONReaderScanner("{\"@type\":\"java.util.LinkedHashMap\",\"name\":\"张三\"}"));
LinkedHashMap json = (LinkedHashMap) parser.parse();
Assert.assertEquals("张三", json.get("name"));
parser.close();
}
Aggregations