BoxBookmark extends BoxItem { public static BoxBookmark createFromId(String bookmarkId) { JsonObject object = new JsonObject(); object.add(FIELD_ID, bookmarkId); object.add(FIELD_TYPE, TYPE); return new BoxBookmark(object); } BoxBookmark();  BoxBookmark(JsonObject object); static BoxBookmark createFromId(String bookmarkId); String getUrl(); Long getSize(); static final String TYPE; static final String FIELD_URL; static final String FIELD_COMMENT_COUNT; static final String[] ALL_FIELDS; }
@Test public void testCreateFromId() { String expectedId = "5"; String expectedType = BoxBookmark.TYPE; BoxBookmark bookmark = BoxBookmark.createFromId(expectedId); String id = bookmark.getId(); String type = bookmark.getType(); Assert.assertEquals(expectedId, id); Assert.assertEquals(expectedType, type); }