{
purgeConfig = purgeConfigService.getPurgeConfiguration( purgeConfigId );
if ( purgeConfig instanceof RepositoryPurgeConfiguration )
{
RepositoryPurgeConfiguration repoPurge = (RepositoryPurgeConfiguration) purgeConfig;
this.purgeType = PURGE_TYPE_REPOSITORY;
this.daysOlder = repoPurge.getDaysOlder();
this.retentionCount = repoPurge.getRetentionCount();
this.deleteAll = repoPurge.isDeleteAll();
this.deleteReleasedSnapshots = repoPurge.isDeleteReleasedSnapshots();
this.enabled = repoPurge.isEnabled();
this.defaultPurgeConfiguration = repoPurge.isDefaultPurge();
this.description = repoPurge.getDescription();
if ( repoPurge.getRepository() != null )
{
this.repositoryId = repoPurge.getRepository().getId();
}
if ( repoPurge.getSchedule() != null )
{
this.scheduleId = repoPurge.getSchedule().getId();
}
}
else if ( purgeConfig instanceof DirectoryPurgeConfiguration )
{
DirectoryPurgeConfiguration dirPurge = (DirectoryPurgeConfiguration) purgeConfig;