public final class

InternCache

extends LinkedHashMap<K, V>
java.lang.Object
   ↳ java.util.AbstractMap<K, V>
     ↳ java.util.HashMap<K, V>
       ↳ java.util.LinkedHashMap<K, V>
         ↳ com.fasterxml.jackson.core.util.InternCache

Class Overview

Singleton class that adds a simple first-level cache in front of regular String.intern() functionality. This is done as a minor performance optimization, to avoid calling native intern() method in cases where same String is being interned multiple times.

Note: that this class extends LinkedHashMap is an implementation detail -- no code should ever directly call Map methods.

Summary

Fields
public static final InternCache instance
Public Methods
synchronized String intern(String input)
Protected Methods
boolean removeEldestEntry(Entry<StringString> eldest)
[Expand]
Inherited Methods
From class java.util.LinkedHashMap
From class java.util.HashMap
From class java.util.AbstractMap
From class java.lang.Object
From interface java.util.Map

Fields

public static final InternCache instance

Public Methods

public synchronized String intern (String input)

Protected Methods

protected boolean removeEldestEntry (Entry<StringString> eldest)