Reference rootReference = references.get(0);
File rootFile = new File(new URI(rootReference.getDataStoreReference()));
if (rootFile.isDirectory())
{
// Add the directory and all of its contents.
zipFile.addFolder(rootFile, parameters);
}
else
{
// Add each file in the list of references.
for (Reference reference : references)