def set_data(self, data):
if not isinstance(data, basestring):<EOL><INDENT>raise ValueError("<STR_LIT>")<EOL><DEDENT>self._data = data<EOL>self._current = <NUM_LIT:0><EOL>
Set a new data buffer.

:Parameters:

    `data` : a basestring object 
        New data buffer.