|
Parsing Engine | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectdanbikel.util.AbstractMapToPrimitive.Entry<K>
danbikel.util.HashMapPrimitive.Entry<K>
public abstract static class HashMapPrimitive.Entry<K>
A still-abstract extension of the AbstractMapToPrimitive.Entry
that
adds a next pointer and an int
to cache the hash value of the
key held by this entry.
Field Summary | |
---|---|
protected int |
keyHash
The hash value of the key of this entry, cached here for efficiency. |
protected HashMapPrimitive.Entry<K> |
next
The next pointer of this entry’s singly-linked list. |
Fields inherited from class danbikel.util.AbstractMapToPrimitive.Entry |
---|
key |
Constructor Summary | |
---|---|
|
HashMapPrimitive.Entry()
Constructs a new entry, with all default values for data members (this no-argument constructor necessary for serialization). |
protected |
HashMapPrimitive.Entry(int keyHash,
K key,
HashMapPrimitive.Entry<K> next)
Constructs a new entry with the specified values for its data members. |
Method Summary | |
---|---|
protected abstract Object |
clone()
Returns a new copy of this type of map entry. |
abstract void |
copyValuesFrom(HashMapPrimitive.Entry copyFrom)
Copies the values from the specified entry to this entry. |
abstract boolean |
equals(Object o)
|
Object |
getValue()
Throws an UnsupportedOperationException . |
abstract int |
hashCode()
|
void |
readExternal(ObjectInput in)
|
protected abstract void |
readValues(ObjectInput in)
|
boolean |
replaceKey(K key)
Replaces the key of this entry with the specified key. |
Object |
setValue(Object value)
Throws an UnsupportedOperationException . |
abstract String |
toString()
|
void |
writeExternal(ObjectOutput out)
|
protected abstract void |
writeValues(ObjectOutput out)
|
Methods inherited from class danbikel.util.AbstractMapToPrimitive.Entry |
---|
add, add, add, add, add, add, add, add, add, add, add, add, getByteValue, getByteValue, getCharValue, getCharValue, getDoubleValue, getDoubleValue, getFloatValue, getFloatValue, getIntValue, getIntValue, getKey, getLongValue, getLongValue, getShortValue, getShortValue, numBytes, numChars, numDoubles, numFloats, numInts, numLongs, numShorts, set, set, set, set, set, set, set |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected transient int keyHash
protected transient HashMapPrimitive.Entry<K> next
Constructor Detail |
---|
public HashMapPrimitive.Entry()
protected HashMapPrimitive.Entry(int keyHash, K key, HashMapPrimitive.Entry<K> next)
keyHash
- the hash value of the specified keykey
- the key of this hash map entrynext
- the next pointer of this entry’s singly-linked list
(can be null
)Method Detail |
---|
protected abstract Object clone()
clone
in class Object
public boolean replaceKey(K key)
equals
method).
replaceKey
in interface MapToPrimitive.Entry<K>
key
- the new key of this entry
public Object getValue()
UnsupportedOperationException
. This default
implementation may be overridden by subclasses, but should be used with
care, as auto-boxing might need to happen.
getValue
in interface Map.Entry<K,Object>
UnsupportedOperationException
- under all circumstancespublic Object setValue(Object value)
UnsupportedOperationException
.
setValue
in interface Map.Entry<K,Object>
value
- ignored
UnsupportedOperationException
- under all circumstancespublic abstract boolean equals(Object o)
equals
in interface Map.Entry<K,Object>
equals
in class Object
public abstract int hashCode()
hashCode
in interface Map.Entry<K,Object>
hashCode
in class Object
public abstract String toString()
toString
in class Object
public abstract void copyValuesFrom(HashMapPrimitive.Entry copyFrom)
ClassCastException
- if the specified entry is not of the same
run-time type as this entrypublic void writeExternal(ObjectOutput out) throws IOException
writeExternal
in interface Externalizable
IOException
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
IOException
ClassNotFoundException
protected abstract void writeValues(ObjectOutput out) throws IOException
IOException
protected abstract void readValues(ObjectInput in) throws IOException, ClassNotFoundException
IOException
ClassNotFoundException
|
Parsing Engine | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |