@Test public void readDeepMap() { String h212 = "##0136ST=32;CN=2011;PW=123456;MN=LD130133000015;CP=" + "&&DataTime=20160824003817;B01-Rtd=36.91;011-Rtd=231.0,011-Flag=N;060-Rtd=1.803,060-Flag=N&&" + "4980\r\n"; T212Mapper mapper = new T212Mapper() .enableDefaultParserFeatures() .enableDefaultVerifyFeatures(); try { Map<String,Object> data = mapper.readDeepMap(h212); assertEquals(data.get("ST"),"32"); assertEquals(data.get("CN"),"2011"); assertEquals(data.get("PW"),"123456"); assertEquals(data.get("MN"),"LD130133000015"); Map<String,String> cp = (Map<String, String>) data.get("CP"); assertEquals(cp.get("DataTime"),"20160824003817"); assertEquals(cp.get("B01-Rtd"),"36.91"); assertEquals(cp.get("011-Rtd"),"231.0"); assertEquals(cp.get("011-Flag"),"N"); assertEquals(cp.get("060-Rtd"),"1.803"); assertEquals(cp.get("060-Flag"),"N"); } catch (Exception e) { e.printStackTrace(); assert false; } }
public Map<String,Object> readDeepMap(InputStream is) throws IOException, T212FormatException { applyConfigurator(); return _readValueAndClose(factory.parser(is),getDeepMapGenericType().get(),Map.class); }
T212Mapper { public Map<String,Object> readDeepMap(InputStream is) throws IOException, T212FormatException { applyConfigurator(); return _readValueAndClose(factory.parser(is),getDeepMapGenericType().get(),Map.class); } }
T212Mapper { public Map<String,Object> readDeepMap(InputStream is) throws IOException, T212FormatException { applyConfigurator(); return _readValueAndClose(factory.parser(is),getDeepMapGenericType().get(),Map.class); } T212Mapper(); }
T212Mapper { public Map<String,Object> readDeepMap(InputStream is) throws IOException, T212FormatException { applyConfigurator(); return _readValueAndClose(factory.parser(is),getDeepMapGenericType().get(),Map.class); } T212Mapper(); T212Mapper enableDefaultParserFeatures(); T212Mapper enableDefaultVerifyFeatures(); T212Mapper enable(SegmentParserFeature feature); T212Mapper enable(ParserFeature feature); T212Mapper enable(VerifyFeature feature); T212Mapper disable(SegmentParserFeature feature); T212Mapper disable(ParserFeature feature); T212Mapper disable(VerifyFeature feature); T212Mapper configurator(T212Configurator configurator); ObjectMapper objectMapper(); T readValue(InputStream is, Class<T> value); T readValue(byte[] bytes, Class<T> value); T readValue(Reader reader, Class<T> value); T readValue(String data, Class<T> value); void writeValueAsStream(T value, Class<T> type, OutputStream outputStream); void writeValueAsWriter(T value, Class<T> type, Writer writer); Map<String,String> readMap(InputStream is); Map<String,String> readMap(byte[] bytes); Map<String,String> readMap(Reader reader); Map<String,String> readMap(String data); Map<String,Object> readDeepMap(InputStream is); Map<String,Object> readDeepMap(byte[] bytes); Map<String,Object> readDeepMap(Reader reader); Map<String,Object> readDeepMap(String data); Data readData(InputStream is); Data readData(byte[] bytes); Data readData(Reader reader); Data readData(String data); String writeMapAsString(Map data); char[] writeMapAsCharArray(Map data); String writeDataAsString(Data data); char[] writeDataAsCharArray(Data data); }
T212Mapper { public Map<String,Object> readDeepMap(InputStream is) throws IOException, T212FormatException { applyConfigurator(); return _readValueAndClose(factory.parser(is),getDeepMapGenericType().get(),Map.class); } T212Mapper(); T212Mapper enableDefaultParserFeatures(); T212Mapper enableDefaultVerifyFeatures(); T212Mapper enable(SegmentParserFeature feature); T212Mapper enable(ParserFeature feature); T212Mapper enable(VerifyFeature feature); T212Mapper disable(SegmentParserFeature feature); T212Mapper disable(ParserFeature feature); T212Mapper disable(VerifyFeature feature); T212Mapper configurator(T212Configurator configurator); ObjectMapper objectMapper(); T readValue(InputStream is, Class<T> value); T readValue(byte[] bytes, Class<T> value); T readValue(Reader reader, Class<T> value); T readValue(String data, Class<T> value); void writeValueAsStream(T value, Class<T> type, OutputStream outputStream); void writeValueAsWriter(T value, Class<T> type, Writer writer); Map<String,String> readMap(InputStream is); Map<String,String> readMap(byte[] bytes); Map<String,String> readMap(Reader reader); Map<String,String> readMap(String data); Map<String,Object> readDeepMap(InputStream is); Map<String,Object> readDeepMap(byte[] bytes); Map<String,Object> readDeepMap(Reader reader); Map<String,Object> readDeepMap(String data); Data readData(InputStream is); Data readData(byte[] bytes); Data readData(Reader reader); Data readData(String data); String writeMapAsString(Map data); char[] writeMapAsCharArray(Map data); String writeDataAsString(Data data); char[] writeDataAsCharArray(Data data);  }