コード例 #1
0
 public void download(final Artifact artifact, final BuildableArtifactResolveResult result) {
   cacheLockingManager.longRunningOperation(
       String.format("Download %s using repository %s", artifact, getId()),
       new Runnable() {
         public void run() {
           repository.download(artifact, result);
         }
       });
 }
コード例 #2
0
 public ModuleVersionDescriptor getDependency(final DependencyDescriptor dd)
     throws ModuleVersionResolveException {
   return cacheLockingManager.longRunningOperation(
       String.format("Resolve %s using repository %s", dd, getId()),
       new Factory<ModuleVersionDescriptor>() {
         public ModuleVersionDescriptor create() {
           return repository.getDependency(dd);
         }
       });
 }