'Erases a line in a specific way.
:param int type_of: defines the way the line should be erased in:
* ``0`` -- Erases from cursor to end of line, including cursor
position.
* ``1`` -- Erases from beginning of line to cursor,
including cursor position.
* ``2`` -- Erases complete line.
:param bool private: when ``True`` character attributes are left
unchanged **not implemented**.'

def erase_in_line(self, type_of=0, private=False):

    interval = (range(self.cursor.x, self.columns), range(0, (self.cursor.x + 1)), range(0, self.columns))[type_of]
    for column in interval:
        self.buffer[self.cursor.y][column] = self.cursor.attrs
