JSONPointer { public static JSONPointer.Builder builder() { return new Builder(); } private  JSONPointer();  JSONPointer(String query); private  JSONPointer(String section, JSONPointer nextNode); @Override String toString(); String toURIFragment(); static JSONPointer compile(String query); Object queryFrom(Object object); static JSONPointer.Builder builder();  }
@Test public void builder(){ JSONPointer pointer = JSONPointer .builder() .append("foo") .append(4) .append("n~t") .append("bar/1") .build(); assertEquals(new JSONPointer("/foo/4/n~0t/bar/1").toString(), pointer.toString()); }