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

@SuppressWarnings("unchecked")
    public static <E> ImmutableList<E> of() 

Source Link

Usage

From source file:com.proofpoint.galaxy.agent.MockDeploymentManagerFactory.java

@Override
public List<DeploymentManager> loadSlots() {
    return ImmutableList.of();
}

From source file:com.addthis.hydra.task.output.WritableRootPaths.java

/**
 * List of paths that will be written to.
 */
default @Nonnull ImmutableList<Path> writableRootPaths() {
    return ImmutableList.of();
}

From source file:com.google.errorprone.bugpatterns.argumentselectiondefects.Changes.java

static Changes empty() {
    return new AutoValue_Changes(ImmutableList.of(), ImmutableList.of(), ImmutableList.of());
}

From source file:ro.cosu.vampires.server.values.jobs.metrics.Metrics.java

public static Metrics empty() {

    return new AutoValue_Metrics.Builder().id("empty").metrics(ImmutableList.of()).metadata(ImmutableMap.of())
            .build();//  ww w.j  av a  2s  .  co m
}

From source file:com.spotify.heroic.metadata.FindKeys.java

public static FindKeys of(final Set<String> keys, int size, int duplicates) {
    return new FindKeys(ImmutableList.of(), keys, size, duplicates);
}

From source file:org.jclouds.scriptbuilder.domain.Statements.java

public static Statement rm(final String path) {
    return new Statement() {

        @Override//  w  w  w.j  a  va2 s .  com
        public Iterable<String> functionDependencies(OsFamily family) {
            return ImmutableList.of();
        }

        @Override
        public String render(OsFamily family) {
            if (family == OsFamily.WINDOWS)
                return exec(String.format("{rm} %s 2{closeFd}", path)).render(family);
            else
                return exec(String.format("{rm} %s", path)).render(family);
        }

    };
}

From source file:com.spotify.heroic.metadata.FindSeriesIds.java

public static FindSeriesIds of(final Set<String> ids, final boolean limited) {
    return new FindSeriesIds(ImmutableList.of(), ids, limited);
}

From source file:org.apache.james.transport.mailets.remoteDelivery.AddressesArrayToMailAddressListConverter.java

public static List<MailAddress> getAddressesAsMailAddress(Address[] addresses, final Logger logger) {
    if (addresses == null) {
        return ImmutableList.of();
    }//from   www  . j  a v  a2 s .c  o  m
    return FluentIterable.from(Arrays.asList(addresses))
            .transform(new Function<Address, Optional<MailAddress>>() {
                @Override
                public Optional<MailAddress> apply(Address input) {
                    try {
                        return Optional.of(new MailAddress(input.toString()));
                    } catch (AddressException e) {
                        logger.debug("Can't parse unsent address: {}", e.getMessage());
                        return Optional.absent();
                    }
                }
            }).filter(new Predicate<Optional<MailAddress>>() {
                @Override
                public boolean apply(Optional<MailAddress> input) {
                    return input.isPresent();
                }
            }).transform(new Function<Optional<MailAddress>, MailAddress>() {
                @Override
                public MailAddress apply(Optional<MailAddress> input) {
                    return input.get();
                }
            }).toList();
}

From source file:com.spotify.heroic.suggest.TagKeyCount.java

public static TagKeyCount of(final List<Suggestion> suggestions, final boolean limited) {
    return new TagKeyCount(ImmutableList.of(), suggestions, limited);
}

From source file:ro.cosu.vampires.server.values.jobs.metrics.Stats.java

public static Stats empty() {
    return builder().histograms(ImmutableMap.of()).values(ImmutableMap.of()).meters(ImmutableMap.of())
            .counters(ImmutableMap.of()).resources(ImmutableList.of()).build();
}