'Replace an existing value with another one
>>> d=Dict( (("two", "deux"), ("one", "un")) )
>>> d.replace("one", "three", 3)
>>> d
{\'two\': \'deux\', \'three\': 3}
You can also use the classic form:
>>> d[\'three\'] = 4
>>> d
{\'two\': \'deux\', \'three\': 4}'

def replace(self, oldkey, newkey, new_value):

    index = self._index[oldkey]
    self._value_list[index] = new_value
    if (oldkey != newkey):
        del self._index[oldkey]
        self._index[newkey] = index
        self._key_list[index] = newkey
