@Override public JsonPointer getResourcePath() { final String path = "/entries/" + label + "/resources" + resource.getPath(); return JsonPointer.of(path); }
@Override public JsonPointer getResourcePath() { final String path = "/entries/" + label + "/resources" + resource.getPath(); return JsonPointer.of(path); }
@Override public JsonPointer getResourcePath() { final String path = "/entries/" + label + "/resources" + resource.getPath(); return JsonPointer.of(path); }
@Override public JsonPointer getResourcePath() { final String path = "/entries/" + label + "/resources" + resource.getPath(); return JsonPointer.of(path); }
/** * Returns a new instance of {@code Resources} with the given resources. * * @param resources the {@link Resource}s of the new Resources. * @return the new {@code Resources}. * @throws NullPointerException if {@code resources} is {@code null}. */ public static ImmutableResources of(final Iterable<Resource> resources) { checkNotNull(resources, "resources"); final Map<ResourceKey, Resource> resourcesMap = new HashMap<>(); resources.forEach(resource -> { final Resource existingResource = resourcesMap.put(resource.getResourceKey(), resource); if (null != existingResource) { final String msgTemplate = "There is more than one Resource with the path <{0}>!"; throw new IllegalArgumentException(MessageFormat.format(msgTemplate, resource.getPath())); } }); return new ImmutableResources(resourcesMap); }
return child; }); addResourceSubTree(rootChild, resource, resource.getPath());