|
34 | 34 | import com.google.devtools.build.lib.cmdline.RepositoryMapping;
|
35 | 35 | import com.google.devtools.build.lib.events.Event;
|
36 | 36 | import com.google.devtools.build.lib.events.EventHandler;
|
37 |
| -import com.google.devtools.build.lib.graph.Digraph; |
38 |
| -import com.google.devtools.build.lib.graph.Node; |
39 | 37 | import com.google.devtools.build.lib.packages.AggregatingAttributeMapper;
|
40 | 38 | import com.google.devtools.build.lib.packages.Attribute;
|
41 | 39 | import com.google.devtools.build.lib.packages.AttributeFormatter;
|
|
61 | 59 | import com.google.devtools.build.lib.query2.proto.proto2api.Build.QueryResult;
|
62 | 60 | import com.google.devtools.build.lib.query2.proto.proto2api.Build.SourceFile;
|
63 | 61 | import com.google.devtools.build.lib.query2.query.aspectresolvers.AspectResolver;
|
64 |
| -import com.google.devtools.build.lib.query2.query.output.QueryOptions.OrderOutput; |
65 | 62 | import com.google.protobuf.CodedOutputStream;
|
66 | 63 | import java.io.IOException;
|
67 | 64 | import java.io.OutputStream;
|
@@ -169,16 +166,6 @@ public ThreadSafeOutputFormatterCallback<Target> createStreamCallback(
|
169 | 166 | createPostFactoStreamCallback(out, options, env.getMainRepoMapping()));
|
170 | 167 | }
|
171 | 168 |
|
172 |
| - private static Iterable<Target> getSortedLabels(Digraph<Target> result) { |
173 |
| - return Iterables.transform( |
174 |
| - result.getTopologicalOrder(new FormatUtils.TargetOrdering()), Node::getLabel); |
175 |
| - } |
176 |
| - |
177 |
| - @Override |
178 |
| - protected Iterable<Target> getOrderedTargets(Digraph<Target> result, QueryOptions options) { |
179 |
| - return options.orderOutput == OrderOutput.FULL ? getSortedLabels(result) : result.getLabels(); |
180 |
| - } |
181 |
| - |
182 | 169 | /** Converts a logical {@link Target} object into a {@link Build.Target} protobuffer. */
|
183 | 170 | public Build.Target toTargetProtoBuffer(Target target) throws InterruptedException {
|
184 | 171 | return toTargetProtoBuffer(target, /*extraDataForAttrHash=*/ "");
|
|
0 commit comments