HDDS-1979. Fix checkstyle errors (#1312)

This commit is contained in:
Vivek Ratnavel Subramanian 2019-08-17 21:53:12 -07:00 committed by Bharat Viswanadham
parent d873ddd656
commit e61825682a

View File

@ -38,14 +38,16 @@ public class ListPipelinesSubcommand implements Callable<Void> {
@CommandLine.ParentCommand
private SCMCLI parent;
@CommandLine.Option( names = {"-ffc", "--filterByFactor"},
description = "Filter listed pipelines by Factor(ONE/one)", defaultValue = "",
required = false)
@CommandLine.Option(names = {"-ffc", "--filterByFactor"},
description = "Filter listed pipelines by Factor(ONE/one)",
defaultValue = "",
required = false)
private String factor;
@CommandLine.Option( names = {"-fst", "--filterByState"},
description = "Filter listed pipelines by State(OPEN/CLOSE)", defaultValue = "",
required = false)
@CommandLine.Option(names = {"-fst", "--filterByState"},
description = "Filter listed pipelines by State(OPEN/CLOSE)",
defaultValue = "",
required = false)
private String state;
@ -56,9 +58,12 @@ public Void call() throws Exception {
scmClient.listPipelines().forEach(System.out::println);
} else {
scmClient.listPipelines().stream()
.filter(p -> ((isNullOrEmpty(factor) || (p.getFactor().toString().compareToIgnoreCase(factor) == 0))
&& (isNullOrEmpty(state) || (p.getPipelineState().toString().compareToIgnoreCase(state) == 0))))
.forEach(System.out::println);
.filter(p -> ((isNullOrEmpty(factor) ||
(p.getFactor().toString().compareToIgnoreCase(factor) == 0))
&& (isNullOrEmpty(state) ||
(p.getPipelineState().toString().compareToIgnoreCase(state)
== 0))))
.forEach(System.out::println);
}
return null;
}