Interner

@SerialVersionUID(1L) class Interner[T] extends T => T with Serializable

Class that mimics Java's string interner, but for anything. Threadsafe.

Companion
object
trait Serializable
trait T => T
class Object
trait Matchable
class Any

Value members

Concrete methods

override def apply(t: T): T
Definition Classes
Function1
def clear(): Unit
def intern(t: T): T
def internAll(c: List[T]): List[T]
def internAll(c: Array[T])(implicit ct: ClassTag[T]): Array[T]
def internAll(c: Set[T]): Set[T]
def internKeys[V](c: Map[T, V]): Map[T, V]
def internValues[K](c: Map[K, T]): Map[K, T]
def size: Int

Inherited methods

@unspecialized
def andThen[A](g: T => A): T => A
Inherited from
Function1
@unspecialized
def compose[A](g: A => T): A => T
Inherited from
Function1
override def toString(): String
Definition Classes
Function1 -> Any
Inherited from
Function1