} else
throw new ResolvedFailedException(Messages.WorkspaceSnapshotSCM_IncorrectJobType(jobName));
}
PermalinkList permalinks = job.getPermalinks();
Permalink p = permalinks.get(permalink);
if(p==null)
throw new ResolvedFailedException(Messages.WorkspaceSnapshotSCM_NoSuchPermalink(permalink,jobName));
AbstractBuild<?,?> b = (AbstractBuild<?,?>)p.resolve(job);
if(b==null)
throw new ResolvedFailedException(Messages.WorkspaceSnapshotSCM_NoBuild(permalink,jobName));
WorkspaceSnapshot snapshot = b.getAction(WorkspaceSnapshot.class);
if(snapshot==null)