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

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

Introduction

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

Prototype

public static <E> ImmutableList<E> copyOf(E[] elements) 

Source Link

Usage

From source file:org.apache.james.AggregateGuiceModuleTestRule.java

public static AggregateGuiceModuleTestRule of(GuiceModuleTestRule... subrule) {
    return new AggregateGuiceModuleTestRule(ImmutableList.copyOf(subrule));
}

From source file:com.mysema.query.collections.CollQueryFactory.java

/**
 * Create a new query//from www.ja v a2  s  .c o m
 * 
 * @param path source expression
 * @param arr source array
 * @return
 */
public static <A> CollQuery from(Path<A> path, A... arr) {
    return new CollQuery().from(path, ImmutableList.copyOf(arr));
}

From source file:org.onos.yangtools.yang.parser.stmt.reactor.EffectiveModelContext.java

public EffectiveModelContext(List<DeclaredStatement<?>> rootStatements) {
    this.rootStatements = ImmutableList.copyOf(rootStatements);
}

From source file:com.axemblr.service.cm.models.clusters.ActivityList.java

public ActivityList(Activity... items) {
    this(ImmutableList.copyOf(items));
}

From source file:org.apache.james.transport.util.MailAddressUtils.java

public static List<MailAddress> from(InternetAddress[] internetAddresses) throws AddressException {
    return from(ImmutableList.copyOf(internetAddresses));
}

From source file:org.mule.api.registry.SPIServiceRegistry.java

/**
 * {@inheritDoc}//  ww  w  . ja  v a  2 s  .  co m
 */
@Override
public <T> Collection<T> lookupProviders(Class<T> providerClass, ClassLoader classLoader) {
    return ImmutableList.copyOf(ServiceLoader.load(providerClass, classLoader).iterator());
}

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

static InvocationInfo createFromMethodInvocation(MethodInvocationTree tree, MethodSymbol symbol,
        VisitorState state) {/*from w  w w.  ja  va  2  s .  c  o m*/
    return new AutoValue_InvocationInfo(tree, symbol, ImmutableList.copyOf(tree.getArguments()),
            getFormalParametersWithoutVarArgs(symbol), state);
}

From source file:com.opengamma.financial.aggregation.PortfolioAggregationFunctions.java

/**
 * Creates an instance.//from  ww  w. j a  va  2 s  .  c o m
 * 
 * @param functions  the functions, not null
 */
public PortfolioAggregationFunctions(Iterable<AggregationFunction<?>> functions) {
    _functions = ImmutableList.copyOf(functions);
}

From source file:me.lucko.luckperms.common.locale.command.Argument.java

public static ImmutableList<Argument> list(Argument... args) {
    return ImmutableList.copyOf(args);
}

From source file:com.facebook.data.types.JsonListDatum.java

public JsonListDatum(Iterable<Datum> datumList) {
    super(ImmutableList.copyOf(datumList));
}