newR.setVersion( relocation.getVersion() );
newDM.setRelocation( newR );
}
DeploymentRepository repo = dm.getRepository();
if ( repo != null )
{
DeploymentRepository newRepo = new DeploymentRepository();
newRepo.setId( repo.getId() );
newRepo.setLayout( repo.getLayout() );
newRepo.setName( repo.getName() );
newRepo.setUrl( repo.getUrl() );
newRepo.setUniqueVersion( repo.isUniqueVersion() );
newDM.setRepository( newRepo );
}
Site site = dm.getSite();
if ( site != null )
{
Site newSite = new Site();
newSite.setId( site.getId() );
newSite.setName( site.getName() );
newSite.setUrl( site.getUrl() );
newDM.setSite( newSite );
}
DeploymentRepository sRepo = dm.getSnapshotRepository();
if ( sRepo != null )
{
DeploymentRepository newRepo = new DeploymentRepository();
newRepo.setId( sRepo.getId() );
newRepo.setLayout( sRepo.getLayout() );
newRepo.setName( sRepo.getName() );
newRepo.setUrl( sRepo.getUrl() );
newRepo.setUniqueVersion( sRepo.isUniqueVersion() );
newDM.setSnapshotRepository( newRepo );
}
}