BasicPriorityJsonParser implements JsonParser<BasicPriority> { @Override public BasicPriority parse(JSONObject json) throws JSONException { final String name = json.getString("name"); final URI selfUri = JsonParseUtil.getSelfUri(json); return new BasicPriority(selfUri, name); }  @Override BasicPriority parse(JSONObject json);  }
@Test public void testParse() throws Exception { final BasicPriorityJsonParser parser = new BasicPriorityJsonParser(); final BasicPriority basicPriority = parser.parse(ResourceUtil.getJsonObjectFromResource("/json/priority/valid.json")); Assert.assertEquals(new BasicPriority(TestUtil.toUri("http: }