use of com.facebook.buck.distributed.thrift.BuildJobStateBuildTarget in project buck by facebook.
the class DistBuildTargetGraphCodec method encodeBuildTarget.
public static BuildJobStateBuildTarget encodeBuildTarget(BuildTarget buildTarget) {
BuildJobStateBuildTarget remoteTarget = new BuildJobStateBuildTarget();
remoteTarget.setShortName(buildTarget.getShortName());
remoteTarget.setBaseName(buildTarget.getBaseName());
if (buildTarget.getCell().isPresent()) {
remoteTarget.setCellName(buildTarget.getCell().get());
}
remoteTarget.setFlavors(buildTarget.getFlavors().stream().map(Object::toString).collect(Collectors.toSet()));
return remoteTarget;
}
Aggregations