JsonApiResource extends JsonApiResourceIdentifier implements JsonLinks, JsonApiData { @JsonIgnoreProperties(value = {"id", "type"}) @JsonProperty("attributes") public Object getEntity() { return entity; } JsonApiResource(JsonApiIdentifiable entity, URI uri); @JsonIgnoreProperties(value = {"id", "type"}) @JsonProperty("attributes") Object getEntity(); @JsonInclude(JsonInclude.Include.NON_EMPTY) Map<String, JsonApiRelationship> getRelationships(); @Override Map<String, URI> getLinks(); @Override void addLink(String name, URI ref); @Override URI getURI(); @Override boolean hasRelationshipTo(JsonApiIdentifiable related); @Override void setResourceCollectionURI(URI collectionURI); @Override JsonApiResource asSingleResource(); @Override JsonApiResourceCollection asResourceCollection(); @Override URI getRelationshipUri(JsonApiIdentifiable related); @Override JsonApiResource addRelationship(String name, JsonApiIdentifiable related, URI location); @Override JsonApiResource addRelationship(String name, Collection<? extends JsonApiIdentifiable> relatedCollection, URI location); @Override JsonApiResource restrictTo(String attribute); @Override boolean equals(Object o); @Override int hashCode();  }
@Test public void testGetEntity() { JsonApiResource result = new JsonApiResource(dummyObj, uri); Assert.assertEquals(dummyObj, result.getEntity()); }