@classmethod
def walk(cls, level):
    """Walk along a Hilbert curve at the given level.

        This function does not exist in the SWIG bindings of the original C++
        library. It provides a more Pythonic way to iterate over cells.

        :returns:
            Iterator over instances of :class:`CellId` s.
        """
    cellid_int = cls.begin(level).id()
    endid_int = cls.end(level).id()
    increment = cls.begin(level).lsb() << 1
    while cellid_int != endid_int:
        yield cls(cellid_int)
        cellid_int += increment
