def set_data(self, column, value, role):
        """Set the data for the given column to value

        The default implementation returns False

        :param column: the column to set
        :type column: int
        :param value: the value to set
        :param role: the role, usually EditRole
        :type role: :class:`QtCore.Qt.ItemDataRole`
        :returns: True, if editing was successfull
        :rtype: :class:`bool`
        :raises: None
        """
        if role == QtCore.Qt.EditRole or role == QtCore.Qt.DisplayRole:
            self._list[column] = value
            return True
        else:
            return False
def set_data ( self , column , value , role ) : if role == QtCore . Qt . EditRole or role == QtCore . Qt . DisplayRole : self . _list [ column ] = value return True else : return False
Set the data for the given column to value

        The default implementation returns False

        :param column: the column to set
        :type column: int
        :param value: the value to set
        :param role: the role, usually EditRole
        :type role: :class:`QtCore.Qt.ItemDataRole`
        :returns: True, if editing was successfull
        :rtype: :class:`bool`
        :raises: None