public class BuildPackagePathToUnconfiguredTargetNodePackageComputation extends Object implements GraphComputation<BuildPackagePathToUnconfiguredTargetNodePackageKey,UnconfiguredTargetNodeWithDepsPackage>
UnconfiguredTargetNodeWithDepsPackage
public static BuildPackagePathToUnconfiguredTargetNodePackageComputation of(UnconfiguredTargetNodeToTargetNodeFactory unconfiguredTargetNodeToTargetNodeFactory, Cells cells, Cell cell, boolean throwOnValidationError)
BuildPackagePathToUnconfiguredTargetNodePackageComputation
unconfiguredTargetNodeToTargetNodeFactory
- A factory that does translation from raw
target node to configured target node. We use configured target node to infer target
dependencies, but in the future we won't need thatcell
- Cell object that owns the package being createdthrowOnValidationError
- If true, computation throws aborting the workflow. Otherwise a
package with no targets and no deps but errors is createdpublic ComputationIdentifier<UnconfiguredTargetNodeWithDepsPackage> getIdentifier()
getIdentifier
in interface GraphComputation<BuildPackagePathToUnconfiguredTargetNodePackageKey,UnconfiguredTargetNodeWithDepsPackage>
ComputeKey.getIdentifier()
public UnconfiguredTargetNodeWithDepsPackage transform(BuildPackagePathToUnconfiguredTargetNodePackageKey key, ComputationEnvironment env)
GraphComputation
Key
into a final type Result
. This
transformation should be performed synchronously.transform
in interface GraphComputation<BuildPackagePathToUnconfiguredTargetNodePackageKey,UnconfiguredTargetNodeWithDepsPackage>
key
- The Key of the requested resultenv
- The execution environment containing results of keys from GraphComputation.discoverDeps(ComputeKey, ComputationEnvironment)
and GraphComputation.discoverPreliminaryDeps(ComputeKey)
public com.google.common.collect.ImmutableSet<? extends ComputeKey<? extends ComputeResult>> discoverDeps(BuildPackagePathToUnconfiguredTargetNodePackageKey key, ComputationEnvironment env)
GraphComputation
GraphComputation.discoverPreliminaryDeps(ComputeKey)
. The results of those computations will be
available in GraphComputation.transform(ComputeKey, ComputationEnvironment)
as a part of ComputationEnvironment
discoverDeps
in interface GraphComputation<BuildPackagePathToUnconfiguredTargetNodePackageKey,UnconfiguredTargetNodeWithDepsPackage>
key
- the current key to transformenv
- The execution environment containing results of keys from GraphComputation.discoverPreliminaryDeps(ComputeKey)
public com.google.common.collect.ImmutableSet<? extends ComputeKey<? extends ComputeResult>> discoverPreliminaryDeps(BuildPackagePathToUnconfiguredTargetNodePackageKey key)
GraphComputation
GraphComputation.discoverDeps(ComputeKey, ComputationEnvironment)
as
a part of ComputationEnvironment
, and GraphComputation.transform(ComputeKey,
ComputationEnvironment)
discoverPreliminaryDeps
in interface GraphComputation<BuildPackagePathToUnconfiguredTargetNodePackageKey,UnconfiguredTargetNodeWithDepsPackage>
key
- the current key to transformGraphComputation.discoverDeps(ComputeKey, ComputationEnvironment)
and
GraphComputation.transform(ComputeKey, ComputationEnvironment)
of the current key depends on