Search in sources :

Example 1 with BuildTargetPatternTargetNodeParser

use of com.facebook.buck.parser.BuildTargetPatternTargetNodeParser in project buck by facebook.

the class AbstractCommand method parseArgumentsAsTargetNodeSpecs.

public ImmutableList<TargetNodeSpec> parseArgumentsAsTargetNodeSpecs(BuckConfig config, Iterable<String> targetsAsArgs) {
    ImmutableList.Builder<TargetNodeSpec> specs = ImmutableList.builder();
    CommandLineTargetNodeSpecParser parser = new CommandLineTargetNodeSpecParser(config, new BuildTargetPatternTargetNodeParser());
    for (String arg : targetsAsArgs) {
        specs.addAll(parser.parse(config.getCellPathResolver(), arg));
    }
    return specs.build();
}
Also used : ImmutableList(com.google.common.collect.ImmutableList) BuildTargetPatternTargetNodeParser(com.facebook.buck.parser.BuildTargetPatternTargetNodeParser) TargetNodeSpec(com.facebook.buck.parser.TargetNodeSpec)

Aggregations

BuildTargetPatternTargetNodeParser (com.facebook.buck.parser.BuildTargetPatternTargetNodeParser)1 TargetNodeSpec (com.facebook.buck.parser.TargetNodeSpec)1 ImmutableList (com.google.common.collect.ImmutableList)1