public GeneratedContentCleaner() {
repository = PentahoSystem.get( IUnifiedRepository.class );
}
private void findGeneratedContent( List<RepositoryFile> generatedContentList, RepositoryFileTree parent ) {
RepositoryFile parentFile = parent.getFile();
if ( !parentFile.isFolder() ) {
long createTime = parentFile.getCreatedDate().getTime();
if ( createTime <= ( System.currentTimeMillis() - ( age * 1000 ) ) ) {
// now check metadata for RESERVEDMAPKEY_LINEAGE_ID (all generated content has)
Map<String, Serializable> metadata = repository.getFileMetadata( parentFile.getId() );
if ( metadata.containsKey( QuartzScheduler.RESERVEDMAPKEY_LINEAGE_ID ) ) {
generatedContentList.add( parentFile );
}
}
} else {