parameters: (self, pathname)
return_statement: return modName
docstring: @type  pathname: str
          @param pathname: Pathname to a module.
  
          @rtype:  str
          @return: Module name.
docstring_summary: @type  pathname: str
          @param pathname: Pathname to a module.
docstring_tokens: @type pathname : str @param pathname : Pathname to a module .
function: def __filename_to_modname(self, pathname):
          """
          @type  pathname: str
          @param pathname: Pathname to a module.
  
          @rtype:  str
          @return: Module name.
          """
          filename = PathOperations.pathname_to_filename(pathname)
          if filename:
              filename = filename.lower()
              filepart, extpart = PathOperations.split_extension(filename)
              if filepart and extpart:
                  modName = filepart
              else:
                  modName = filename
          else:
              modName = pathname
          return modName
function_tokens: def __filename_to_modname ( self , pathname ) : filename = PathOperations . pathname_to_filename ( pathname ) if filename : filename = filename . lower ( ) filepart , extpart = PathOperations . split_extension ( filename ) if filepart and extpart : modName = filepart else : modName = filename else : modName = pathname return modName