private List<Resource> resourcesOf(JsonNode resourceNodes) {
        List<Resource> resources = new LinkedList<Resource>();

        if (resourceNodes.isArray()) {
            for (JsonNode resource : resourceNodes) {
                resources.add(new Resource(resource.asText()));
            }
        } else {
            resources.add(new Resource(resourceNodes.asText()));
        }

        return resources;
    }
private List < Resource > resourcesOf ( JsonNode resourceNodes ) { List < Resource > resources = new LinkedList < Resource > ( ) ; if ( resourceNodes . isArray ( ) ) { for ( JsonNode resource : resourceNodes ) { resources . add ( new Resource ( resource . asText ( ) ) ) ; } } else { resources . add ( new Resource ( resourceNodes . asText ( ) ) ) ; } return resources ; }
Generates a list of resources from the Resource Json Node.

@param resourceNodes
the resource Json node to be parsed.
@return the list of resources.