MCPcopy Index your code
hub / github.com/EdwardRaff/JSAT / get

Method get

JSAT/src/jsat/utils/IntDoubleMap.java:165–174  ·  view source on GitHub ↗

Returns the value to which the specified key is mapped, or Double#NaN if this map contains no mapping for the key. @param key the key whose associated value is to be returned @return the value to which the specified key is mapped, or Double#NaN if this map contains no mapping for th

(int key)

Source from the content-addressed store, hash-verified

163 * {@link Double#NaN} if this map contains no mapping for the key
164 */
165 public double get(int key)
166 {
167 long pair_index = getIndex(key);
168 int valOrFreeIndex = (int) (pair_index & INT_MASK);
169
170 if(status[valOrFreeIndex] == OCCUPIED)//easy case
171 return table[valOrFreeIndex];
172 //else, return NaN for missing
173 return Double.NaN;
174 }
175
176 @Override
177 public Double get(Object key)

Callers

nothing calls this directly

Calls 1

getIndexMethod · 0.95

Tested by

no test coverage detected