Contents   Class: FormattingContext
<<Method: FormattingContext.isFunction<<   >>Method: FormattingContext.isClass>>

Method: FormattingContext.get_label

Synopsis: get_label( self )

A context is a unique identification of a particular Python code element like modules, classes, functions, or methods. This method produces a string for identifying this element that as used throughout the documentation as label for hyper targets. Since this format is relevant for using the resulting documents as online documentation, here are the relevant code fragments:

Labels for modules:
 "module_" +only_letters_digits( self.moduleName() )
Labels for classes:
 "class_"+only_letters_digits( self.className() )
     +"_"+only_letters_digits( self.moduleName() )
Labels for methods:
 "function_"+only_letters_digits( self.moduleName() )
            +"_"+only_letters_digits( self.className() )
            +"_"+only_letters_digits( self.memberName() )
Labels for global functions:
 "function_"+only_letters_digits(self.moduleName())
        +"_"+only_letters_digits(self.memberName())



Elements:

none

 

Generated by pymanual (c) 2005-2006 on August 02, 2006.