コード例 #1
0
 /**
  * If the specification is lazily resolvable, returns a target that will resolve it on demand.
  * Otherwise it is resolved immediately.
  *
  * @param underlying the underlying resolver to use for resolution
  * @param specification the specification to resolve
  * @return the target
  */
 public static ComputationTarget resolve(
     final ComputationTargetResolver.AtVersionCorrection underlying,
     final ComputationTargetSpecification specification) {
   final Function2<
           ComputationTargetResolver.AtVersionCorrection,
           ComputationTargetSpecification,
           UniqueIdentifiable>
       resolver = s_resolvers.get(specification.getType());
   if (resolver != null) {
     return new ComputationTarget(specification, resolver.execute(underlying, specification));
   } else {
     return underlying.resolve(specification);
   }
 }
コード例 #2
0
 @Override
 public ComputationTarget resolve(final ComputationTargetSpecification specification) {
   return _underlying.resolve(specification);
 }