def key(self, o):
        if o is None:
            return 'null'

        # If the object is already mapped, use existing key
        key = self._objectKeyMap.get(o)
        if key is not None:
            return key

        # If the object is not yet mapped, map it
        self._lastKey += 1
        key = str(self._lastKey)
        self._objectKeyMap[o] = key
        self._keyObjectMap[key] = o
        return key
Gets key for an object.
dataset/ETHPy150Open rwl/muntjac/muntjac/terminal/key_mapper.py/KeyMapper.key