JsonStringToMap extends EvalFunc<Map<String, String>> { @Override public Schema outputSchema(Schema input) { try { return Utils.getSchemaFromString("json: [chararray]"); } catch (ParserException e) { throw new RuntimeException(e); } }  @Override Schema outputSchema(Schema input); @Override Map<String, String> exec(Tuple input);  }
@Test public void testSchema() { Schema schema = udf_.outputSchema(null); assertNotNull(schema); assertEquals("{json: map[chararray]}", schema.toString()); }