Example usage for com.google.common.collect ImmutableList of

List of usage examples for com.google.common.collect ImmutableList of

Introduction

In this page you can find the example usage for com.google.common.collect ImmutableList of.

Prototype

public static <E> ImmutableList<E> of(E e1, E e2, E e3, E e4) 

Source Link

Usage

From source file:org.onosproject.attack.cli.AttackTypeCommandCompleter.java

@Override
public List<String> choices() {
    return ImmutableList.of("NB-DeviceAdminService", "NB-FlowRuleService", "SB-LinkProviderService",
            "SC-SystemExit");
}

From source file:org.sonar.plugins.fsharp.FSharpUnitTestResultsProvider.java

public static List extensions() {
    return ImmutableList.of(FSharpUnitTestResultsAggregator.class, FSharpUnitTestResultsImportSensor.class,
            PropertyDefinition.builder(VISUAL_STUDIO_TEST_RESULTS_PROPERTY_KEY)
                    .name("Visual Studio Test Reports Paths")
                    .description("Example: \"report.trx\", \"report1.trx,report2.trx\" or \"C:/report.trx\"")
                    .category(CATEGORY).subCategory(SUBCATEGORY)
                    .onlyOnQualifiers(Qualifiers.PROJECT, Qualifiers.MODULE).build(),
            PropertyDefinition.builder(NUNIT_TEST_RESULTS_PROPERTY_KEY).name("NUnit Test Reports Paths")
                    .description(/*from  w  w  w  .j a va 2 s  .com*/
                            "Example: \"TestResult.xml\", \"TestResult1.xml,TestResult2.xml\" or \"C:/TestResult.xml\"")
                    .category(CATEGORY).subCategory(SUBCATEGORY)
                    .onlyOnQualifiers(Qualifiers.PROJECT, Qualifiers.MODULE).build());
}

From source file:com.proofpoint.launcher.Processes.java

static void kill(int pid, boolean graceful) {
    if (System.getProperty("os.name").startsWith("Windows")) {
        List<String> args = ImmutableList.of("taskkill", "/f", "/pid", Integer.toString(pid));
        try {//from www. ja v a 2  s . c om
            new ProcessBuilder(args).redirectInput(Redirect.from(NULL_FILE)).redirectOutput(Redirect.INHERIT)
                    .redirectError(Redirect.INHERIT).start().waitFor();
        } catch (IOException | InterruptedException ignored) {
        }
    } else {
        int signal = new Signal(graceful ? "TERM" : "KILL").getNumber();
        posix.kill(pid, signal);
    }
}

From source file:com.android.tools.idea.uibuilder.handlers.SeekBarHandler.java

@Override
@NotNull
public List<String> getInspectorProperties() {
    return ImmutableList.of(ATTR_STYLE, ATTR_THUMB, ATTR_MAXIMUM, ATTR_PROGRESS);
}

From source file:com.android.tools.idea.uibuilder.handlers.ToggleButtonHandler.java

@Override
@NotNull
public List<String> getInspectorProperties() {
    return ImmutableList.of(ATTR_STYLE, ATTR_TEXT_OFF, ATTR_TEXT_ON, ATTR_CHECKED);
}

From source file:org.sonar.plugins.coverage.generic.GenericCoveragePlugin.java

private static ImmutableList<PropertyDefinition> pluginProperties() {
    return ImmutableList.of(

            PropertyDefinition.builder(REPORT_PATHS_PROPERTY_KEY).name("Coverage report paths")
                    .description(//from  ww w  .  ja v  a 2 s.c  o m
                            "List of comma-separated paths (absolute or relative) containing coverage report.")
                    .category(CATEGORY).onQualifiers(Qualifiers.PROJECT).build(),

            PropertyDefinition.builder(IT_REPORT_PATHS_PROPERTY_KEY)
                    .name("Integration tests coverage report paths")
                    .description(
                            "List of comma-separated paths (absolute or relative) containing integration tests coverage report.")
                    .category(CATEGORY).onQualifiers(Qualifiers.PROJECT).build(),

            PropertyDefinition.builder(UNIT_TEST_REPORT_PATHS_PROPERTY_KEY).name("Unit tests report paths")
                    .description(
                            "List of comma-separated paths (absolute or relative) containing unit tests report.")
                    .category(CATEGORY).onQualifiers(Qualifiers.PROJECT).build(),

            deprecatedPropertyDefinition(OLD_REPORT_PATH_PROPERTY_KEY));
}

From source file:org.onosproject.cli.app.ApplicationCommandCompleter.java

@Override
public List<String> choices() {
    return ImmutableList.of(INSTALL, UNINSTALL, ACTIVATE, DEACTIVATE);
}

From source file:com.facebook.buck.cxx.ClangCompiler.java

@Override
public Optional<ImmutableList<String>> debugCompilationDirFlags(String debugCompilationDir) {
    return Optional.of(ImmutableList.of("-Xclang", "-fdebug-compilation-dir", "-Xclang", debugCompilationDir));
}

From source file:org.onosproject.cli.security.PermissionCommandCompleter.java

@Override
protected List<String> choices() {
    return ImmutableList.of(ADD, REMOVE, CLEAR, LIST);
}