(self)
String giving the file mode
String giving the file mode
String giving the file mode
def mode(self):
        """String giving the file mode"""
        if self._created:
            if self._readable:
                return 'xb+'
            else:
                return 'xb'
        elif self._appending:
            if self._readable:
                return 'ab+'
            else:
                return 'ab'
        elif self._readable:
            if self._writable:
                return 'rb+'
            else:
                return 'rb'
        else:
            return 'wb'
def mode ( self ) : if self . _created : if self . _readable : return 'xb+' else : return 'xb' elif self . _appending : if self . _readable : return 'ab+' else : return 'ab' elif self . _readable : if self . _writable : return 'rb+' else : return 'rb' else : return 'wb'