public abstract class FromStringInterner<T> extends Object
It doesn't guantee it will always return the same object, nor that different threads will return the same object, though the contents should always be the same.
While not technically thread safe, it should still behave correctly.
| Modifier and Type | Field and Description |
|---|---|
protected net.openhft.chronicle.wire.internal.FromStringInterner.InternerEntry<T>[] |
entries |
protected int |
mask |
protected int |
shift |
protected boolean |
toggle |
| Modifier | Constructor and Description |
|---|---|
protected |
FromStringInterner(int capacity) |
| Modifier and Type | Method and Description |
|---|---|
protected abstract T |
getValue(String s) |
T |
intern(@NotNull String s) |
protected boolean |
toggle() |
protected final net.openhft.chronicle.wire.internal.FromStringInterner.InternerEntry<T>[] entries
protected final int mask
protected final int shift
protected boolean toggle
protected FromStringInterner(int capacity)
throws IllegalArgumentException
IllegalArgumentExceptionpublic T intern(@NotNull @NotNull String s) throws IllegalArgumentException, net.openhft.chronicle.core.io.IORuntimeException, BufferUnderflowException
IllegalArgumentExceptionnet.openhft.chronicle.core.io.IORuntimeExceptionBufferUnderflowException@NotNull protected abstract T getValue(String s) throws net.openhft.chronicle.core.io.IORuntimeException
net.openhft.chronicle.core.io.IORuntimeExceptionprotected boolean toggle()
Copyright © 2023. All rights reserved.