parameters: (self, mode)
return_statement: return self
docstring: Set the mode. May be the new mode (os.chmod behavior) or a `symbolic
          mode <http://en.wikipedia.org/wiki/Chmod#Symbolic_modes>`_.
  
          .. seealso:: :func:`os.chmod`
docstring_summary: Set the mode. May be the new mode (os.chmod behavior) or a `symbolic
          mode <http://en.wikipedia.org/wiki/Chmod#Symbolic_modes>`_.
docstring_tokens: Set the mode . May be the new mode ( os . chmod behavior ) or a symbolic mode <http : // en . wikipedia . org / wiki / Chmod#Symbolic_modes > _ .
function: def chmod(self, mode):
          """
          Set the mode. May be the new mode (os.chmod behavior) or a `symbolic
          mode <http://en.wikipedia.org/wiki/Chmod#Symbolic_modes>`_.
  
          .. seealso:: :func:`os.chmod`
          """
          if isinstance(mode, string_types):
              mask = _multi_permission_mask(mode)
              mode = mask(self.stat().st_mode)
          os.chmod(self, mode)
          return self
function_tokens: def chmod ( self , mode ) : if isinstance ( mode , string_types ) : mask = _multi_permission_mask ( mode ) mode = mask ( self . stat ( ) . st_mode ) os . chmod ( self , mode ) return self