This method is a convenience for testing. Code should call Segment#newEntry directly.
(K key, int hash, @Nullable ReferenceEntry<K, V> next)
| 1881 | */ |
| 1882 | |
| 1883 | @VisibleForTesting |
| 1884 | ReferenceEntry<K, V> newEntry(K key, int hash, @Nullable ReferenceEntry<K, V> next) { |
| 1885 | Segment<K, V> segment = segmentFor(hash); |
| 1886 | segment.lock(); |
| 1887 | try { |
| 1888 | return segment.newEntry(key, hash, next); |
| 1889 | } finally { |
| 1890 | segment.unlock(); |
| 1891 | } |
| 1892 | } |
| 1893 | |
| 1894 | /** |
| 1895 | * This method is a convenience for testing. Code should call {@link Segment#copyEntry} directly. |
no test coverage detected