VFSContainer container = new OlatRootFolderImpl(FolderConfig.getUserHomes() + File.separator + ureq.getIdentity().getName() + "/private/archive", null);
// append export timestamp to avoid overwriting previous export
Date tmp = new Date(System.currentTimeMillis());
java.text.SimpleDateFormat formatter = new java.text.SimpleDateFormat("yyyy-MM-dd'T'HH_mm_ss");
String folder = "forum_" + forum.getKey().toString()+"_"+formatter.format(tmp);
VFSItem vfsItem = container.resolve(folder);
if (vfsItem == null || !(vfsItem instanceof VFSContainer)) {
vfsItem = container.createChildContainer(folder);
}
container = (VFSContainer) vfsItem;
return container;