List of usage examples for com.google.common.collect Lists asList
public static <E> List<E> asList(@Nullable E first, E[] rest)
From source file:io.crate.sql.tree.QualifiedName.java
public static QualifiedName of(String first, String... rest) { Preconditions.checkNotNull(first, "first is null"); return new QualifiedName(ImmutableList.copyOf(Lists.asList(first, rest))); }
From source file:google.registry.util.DateTimeUtils.java
/** Returns the earliest of a number of given {@link DateTime} instances. */ public static DateTime earliestOf(DateTime first, DateTime... rest) { return earliestOf(Lists.asList(first, rest)); }
From source file:com.b2international.snowowl.datastore.remotejobs.RemoteJobState.java
public boolean oneOf(RemoteJobState firstState, RemoteJobState... restStates) { return Lists.asList(firstState, restStates).contains(this); }
From source file:eu.artist.reusevol.repo.server.util.JcrPathUtil.java
public static String getCategoryPath(CategoryName name) { Preconditions.checkNotNull(name);//from w ww .j a va 2 s . c o m StringBuilder path = new StringBuilder(CATEGORY_BASE_PATH); path.append("/"); Joiner joiner = Joiner.on(CATEGORY_COLLECTION_NODE_NAME); path.append(joiner.join(Lists.asList("root", name.getSegments().toArray()))); return path.toString(); }
From source file:org.elasticsearch.common.logging.Loggers.java
public static ESLogger getLogger(Class clazz, Settings settings, ShardId shardId, String... prefixes) { return getLogger(clazz, settings, shardId.index(), Lists.asList(Integer.toString(shardId.id()), prefixes).toArray(new String[0])); }
From source file:eu.numberfour.n4js.ui.internal.CompositeValidationIssueProcessor.java
/** * Creates a new composite issue processor with the given sub processor arguments. * * @param first//from w w w . j a v a 2 s. co m * the first sub processor. * @param others * the other processor; */ public CompositeValidationIssueProcessor(final IValidationIssueProcessor first, final IValidationIssueProcessor... others) { processors = Lists.asList(first, others); }
From source file:org.elasticsearch.util.logging.Loggers.java
public static Logger getLogger(Class clazz, Settings settings, ShardId shardId, String... prefixes) { return getLogger(clazz, settings, shardId.index(), Lists.asList(Integer.toString(shardId.id()), prefixes).toArray(new String[0])); }
From source file:google.registry.util.DateTimeUtils.java
/** Returns the latest of a number of given {@link DateTime} instances. */ public static DateTime latestOf(DateTime first, DateTime... rest) { return latestOf(Lists.asList(first, rest)); }
From source file:dagger2.internal.codegen.writer.Modifiable.java
public void addModifiers(Modifier first, Modifier... rest) { addModifiers(Lists.asList(first, rest)); }
From source file:org.workhorse.dependency.GuiceDependencyManager.java
/** * Creates the Guice dependency manager with the configuration * modules./*from w w w. ja va2s .c om*/ * @param modules The configuration modules */ public GuiceDependencyManager(Module... modules) { final DependencyManager dp = this; injector = Guice.createInjector(Lists.asList(new AbstractModule() { @Override protected void configure() { bind(DependencyManager.class).toInstance(dp); } }, modules)); }