Clears (resets) a counter specified by its name.

        :param name: a counter name to clear.

def clear(self, name):
        """
        Clears (resets) a counter specified by its name.

        :param name: a counter name to clear.
        """
        self._lock.acquire()
        try:
            del self._cache[name]
        finally:
            self._lock.release()