class MetadataResponseFormatter {

    public static MetadataResponse formatResponse(List<Metadata> metadataList, String path) throws IOException {
        /* print the fragment list to log when in debug level */
        if (LOG.isDebugEnabled()) {
            MetadataResponseFormatter.printMetadata(metadataList, path);
        }

        return new MetadataResponse(metadataList);
    }

}