Logo Search packages:      
Sourcecode: cclib version File versions  Download package

def cclib::method::calculationmethod::Method::__init__ (   self,
  data,
  progress = None,
  loglevel = logging.INFO,
  logname = "Log" 
)
Initialise the Logfile object.

Typically called by subclasses in their own __init__ methods.

Reimplemented in cclib::method::fragments::FragmentAnalysis.

Definition at line 21 of file calculationmethod.py.

                                                      :
        """Initialise the Logfile object.

        Typically called by subclasses in their own __init__ methods.
        """

        self.data = data
        self.progress = progress
        self.loglevel = loglevel
        self.logname = logname

        # Set up the logger.
        self.logger = logging.getLogger('%s %s' % (self.logname, self.data))
        self.logger.setLevel(self.loglevel)
        handler = logging.StreamHandler(sys.stdout)
        handler.setFormatter(logging.Formatter(
                             "[%(name)s %(levelname)s] %(message)s"))
        self.logger.addHandler(handler)



Generated by  Doxygen 1.6.0   Back to index