Using dir to investigate a module : dir « Buildin Function « Python Tutorial






dir() on an class instance shows the instance variables as well as the methods and class attributes defined and all its base classes.
dir() on a class shows the contents of the __dict__ of the class and all its base classes. 
dir() on a module shows the contents of the module's __dict__. 
dir() without arguments shows the caller's local variables.








13.12.dir
13.12.1.Using dir to investigate a module
13.12.2.dir function returns a list of the attributes and methods of any object
13.12.3.apply the dir() function to a type as well as a variable
13.12.4.dir() list the entities stored within a Python object