return this.manager.createQuery("select new de.sosd.mediaserver.bean.ui.FrontendFolderBean(dir.id, dir.path, dir.lastScan, dir.scanInterval, dir.scanState,dir.folderCount, dir.fileCount, dir.overallSize) from Folder as dir").getResultList();
}
@Transactional(propagation = Propagation.REQUIRED)
public StringKeyValuePair createDirectory(final ScanFolderDomain scanFolder, final String usn) {
final SystemDomain systemProperties = systemDao.getSystem(usn);
scanFolder.setSystem(systemProperties);
systemProperties.getScanFolder().add(scanFolder);
this.manager.persist(systemProperties);
return new StringKeyValuePair(scanFolder.getId(), scanFolder.getPath());
}