Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Mail Systems
Eclipse Documentation

How To Guides
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Problem Solutions
Privacy Policy




Special Attribute Names

As part of creating a class definition, Python adds a number of special attributes. These are informational in nature, and cannot not be easily be changed except by redefining the class or function, or reimporting the module.


The class name.


The module in which the class was defined.


The dictionary which contains the object's attributes and methods.


The base classes for this class. These are also called superclasses.


The documentation string. This is part of the response produced by the help function.

Here's an example of how the class docstring is used to produce the help results for a class.

import random
print random.Random.__doc__

  Published under the terms of the Open Publication License Design by Interspire