List of usage examples for com.google.common.collect ImmutableList of
public static <E> ImmutableList<E> of(E element)
From source file:no.ssb.vtl.model.AbstractUnaryDatasetOperation.java
protected AbstractUnaryDatasetOperation(Dataset child) { super(ImmutableList.of(child)); }
From source file:com.google.errorprone.names.NamingConventions.java
/** * Split a Java name into terms based on either Camel Case or Underscores. We also split digits at * the end of the name into a separate term so as to treat PERSON1 and PERSON_1 as the same thing. * * @param identifierName to split//from w w w .j a v a2 s .c om * @return a list of the terms in the name, in order and converted to lowercase */ public static ImmutableList<String> splitToLowercaseTerms(String identifierName) { if (ONLY_UNDERSCORES.matcher(identifierName).matches()) { // Degenerate case of names which contain only underscore return ImmutableList.of(identifierName); } return Arrays.stream(TERM_SPLITTER.split(identifierName)).map(String::toLowerCase) .collect(toImmutableList()); }
From source file:io.prestosql.plugin.mongodb.MongoPlugin.java
@Override public Iterable<Type> getTypes() { return ImmutableList.of(OBJECT_ID); }
From source file:com.cisco.cta.taxii.adapter.httpclient.HttpHeadersAppender.java
public void appendTo(HttpHeaders headers) { headers.setContentType(MediaType.APPLICATION_XML); headers.setAccept(ImmutableList.of(MediaType.APPLICATION_XML)); headers.set("X-Taxii-Accept", "urn:taxii.mitre.org:message:xml:1.1"); headers.set("X-TAXII-Content-Type", "urn:taxii.mitre.org:message:xml:1.1"); headers.set("X-Taxii-Protocol", "urn:taxii.mitre.org:protocol:https:1.0"); headers.set("X-TAXII-Services", "urn:taxii.mitre.org:services:1.1"); headers.set("User-Agent", "taxii-log-adapter-" + Version.getImplVersion()); }
From source file:com.palantir.atlasdb.table.description.TableDefinitions.java
private static final TableMetadata singleColumn(String colName) { return new TableMetadata( NameMetadataDescription/* ww w .j a v a 2s . co m*/ .create(ImmutableList.of(new NameComponentDescription("row", ValueType.STRING))), new ColumnMetadataDescription(new DynamicColumnDescription( NameMetadataDescription .create(ImmutableList.of(new NameComponentDescription(colName, ValueType.STRING))), ColumnValueDescription.forType(ValueType.BLOB))), ConflictHandler.SERIALIZABLE); }
From source file:org.apache.beam.sdk.io.kudu.KuduTestUtils.java
static CreateTableOptions createTableOptions() { return new CreateTableOptions().setRangePartitionColumns(ImmutableList.of(COL_ID)).setNumReplicas(1); }
From source file:org.apache.tajo.type.Char.java
Char(int length) { super(CHAR, ImmutableList.of(length)); }