### Question:
JsonTemplateMapper { public static <T extends JsonTemplate> T readJson(InputStream jsonStream, Class<T> templateClass) throws IOException { return objectMapper.readValue(jsonStream, templateClass); } private  JsonTemplateMapper(); static T readJsonFromFile(Path jsonFile, Class<T> templateClass); static T readJsonFromFileWithLock(
      Path jsonFile, Class<T> templateClass); static T readJson(InputStream jsonStream, Class<T> templateClass); static T readJson(String jsonString, Class<T> templateClass); static T readJson(byte[] jsonBytes, Class<T> templateClass); static List<T> readListOfJson(
      String jsonString, Class<T> templateClass); static String toUtf8String(JsonTemplate template); static String toUtf8String(List<? extends JsonTemplate> templates); static byte[] toByteArray(JsonTemplate template); static byte[] toByteArray(List<? extends JsonTemplate> templates); static void writeTo(JsonTemplate template, OutputStream out); static void writeTo(List<? extends JsonTemplate> templates, OutputStream out);  }### Answer:
@Test public void testReadJson_inputStream() throws IOException { String testJson = "{\"number\":3, \"text\":\"cool\"}"; ByteArrayInputStream in = new ByteArrayInputStream(testJson.getBytes(StandardCharsets.UTF_8)); TestJson json = JsonTemplateMapper.readJson(in, TestJson.class); Assert.assertEquals(3, json.number); Assert.assertEquals("cool", json.text); }