@Test public void resource_to_json() throws JsonProcessingException { Dummy info = new Dummy("1.0.0"); Resource<Dummy> resource = Resource.of(info, URI.create("http: assertResourceJson( mapper, object() .with("_self", "http: .with("version", "1.0.0") .with("connectors", "http: .end(), resource ); }
public static <R> Resource<R> of(R data, URI self) { return new Resource<>(data, self); }
Resource extends LinkContainer<Resource<T>> implements ViewSupplier { public static <R> Resource<R> of(R data, URI self) { return new Resource<>(data, self); } }
Resource extends LinkContainer<Resource<T>> implements ViewSupplier { public static <R> Resource<R> of(R data, URI self) { return new Resource<>(data, self); } @ConstructorProperties({"data", "_self"}) protected  Resource(T data, URI self); private  Resource(T data, URI self, Class<?> view); }
Resource extends LinkContainer<Resource<T>> implements ViewSupplier { public static <R> Resource<R> of(R data, URI self) { return new Resource<>(data, self); } @ConstructorProperties({"data", "_self"}) protected  Resource(T data, URI self); private  Resource(T data, URI self, Class<?> view); static Resource<R> of(R data, URI self); Resource<T> withView(Class<?> view); }
Resource extends LinkContainer<Resource<T>> implements ViewSupplier { public static <R> Resource<R> of(R data, URI self) { return new Resource<>(data, self); } @ConstructorProperties({"data", "_self"}) protected  Resource(T data, URI self); private  Resource(T data, URI self, Class<?> view); static Resource<R> of(R data, URI self); Resource<T> withView(Class<?> view);  }