}
private void doPurgeAllRelated( ArtifactReference reference, String version )
throws LayoutException
{
ArtifactReference artifact = new ArtifactReference();
artifact.setGroupId( reference.getGroupId() );
artifact.setArtifactId( reference.getArtifactId() );
artifact.setVersion( version );
artifact.setClassifier( reference.getClassifier() );
artifact.setType( reference.getType() );
try
{
Set<ArtifactReference> related = repository.getRelatedArtifacts( artifact );
purge( related, repository );