All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.contek.zeus.IndexSymbol Maven / Gradle / Ivy

The newest version!
package io.contek.zeus;

import com.google.common.collect.ImmutableSet;

import javax.annotation.concurrent.Immutable;
import java.util.Collection;

import static com.google.common.collect.ImmutableSet.toImmutableSet;

@Immutable
public final class IndexSymbol extends StringKey {

  private IndexSymbol(String stringValue) {
    super(stringValue);
  }

  public static IndexSymbol of(String symbol) {
    return new IndexSymbol(symbol);
  }

  public static ImmutableSet setOf(Collection stringValues) {
    return stringValues.stream().map(IndexSymbol::of).collect(toImmutableSet());
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy