public class Object2FloatOpenHashMapWritable<K extends org.apache.hadoop.io.Writable>
extends it.unimi.dsi.fastutil.objects.Object2FloatOpenHashMap<K>
implements org.apache.hadoop.io.Writable
it.unimi.dsi.fastutil.objects.AbstractObject2FloatMap.BasicEntry<K>| Constructor and Description |
|---|
Object2FloatOpenHashMapWritable()
Creates a
String2IntOpenHashMapWritable object. |
| Modifier and Type | Method and Description |
|---|---|
static <K extends org.apache.hadoop.io.Writable> |
create(byte[] bytes)
Creates object from serialized representation.
|
static <K extends org.apache.hadoop.io.Writable> |
create(DataInput in)
Creates object from serialized representation.
|
int |
dot(Object2FloatOpenHashMapWritable<K> m)
Computes the dot product of this map with another map.
|
void |
increment(K key)
Increments the key.
|
void |
plus(Object2FloatOpenHashMapWritable<K> m)
Adds values of keys from another map to this map.
|
void |
readFields(DataInput in)
Deserializes the map.
|
byte[] |
serialize()
Returns the serialized representation of this object as a byte array.
|
void |
write(DataOutput out)
Serializes the map.
|
add, addTo, clear, clone, containsKey, containsValue, getFloat, growthFactor, growthFactor, hashCode, isEmpty, keySet, object2FloatEntrySet, put, put, rehash, rehash, remove, removeFloat, shiftKeys, size, trim, trim, valuescontainsValue, entrySet, equals, putAll, toStringdefaultReturnValue, defaultReturnValue, getfinalize, getClass, notify, notifyAll, wait, wait, waitdefaultReturnValue, defaultReturnValuecompute, computeIfAbsent, computeIfPresent, forEach, get, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAllpublic Object2FloatOpenHashMapWritable()
String2IntOpenHashMapWritable object.public void readFields(DataInput in) throws IOException
readFields in interface org.apache.hadoop.io.Writablein - source for raw byte representationIOExceptionpublic void write(DataOutput out) throws IOException
write in interface org.apache.hadoop.io.Writableout - where to write the raw byte representationIOExceptionpublic byte[] serialize()
throws IOException
IOExceptionpublic static <K extends org.apache.hadoop.io.Writable> Object2FloatOpenHashMapWritable<K> create(DataInput in) throws IOException
in - source of serialized representationIOExceptionpublic static <K extends org.apache.hadoop.io.Writable> Object2FloatOpenHashMapWritable<K> create(byte[] bytes) throws IOException
bytes - source of serialized representationIOExceptionpublic void plus(Object2FloatOpenHashMapWritable<K> m)
m - the other mappublic int dot(Object2FloatOpenHashMapWritable<K> m)
m - the other mappublic void increment(K key)
key - key to incrementCopyright © 2018. All rights reserved.