<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def abort(self):
 """ Immediately close the stream, without sending remaining buffers or performing a proper shutdown. """

        if self._state == _State.CLOSED:
            self._invalid_state("abort() called")
            return

        self._force_close(None)