LSSTApplications  10.0-2-g4f67435,11.0.rc2+1,11.0.rc2+12,11.0.rc2+3,11.0.rc2+4,11.0.rc2+5,11.0.rc2+6,11.0.rc2+7,11.0.rc2+8
LSSTDataManagementBasePackage
Public Member Functions | Public Attributes | List of all members
lsst.log.log.LogContext Class Reference

Public Member Functions

def __init__
 
def __enter__
 
def __exit__
 
def __del__
 
def open
 
def close
 
def setLevel
 
def getLevel
 
def isEnabledFor
 

Public Attributes

 name
 
 level
 

Detailed Description

Definition at line 114 of file log.py.

Constructor & Destructor Documentation

def lsst.log.log.LogContext.__init__ (   self,
  name = None,
  level = None 
)

Definition at line 116 of file log.py.

117  def __init__(self, name=None, level=None):
118  self.name = name
119  self.level = level
def lsst.log.log.LogContext.__del__ (   self)

Definition at line 127 of file log.py.

128  def __del__(self):
129  self.close()

Member Function Documentation

def lsst.log.log.LogContext.__enter__ (   self)

Definition at line 120 of file log.py.

121  def __enter__(self):
122  self.open()
123  return self
def lsst.log.log.LogContext.__exit__ (   self,
  type,
  value,
  traceback 
)

Definition at line 124 of file log.py.

125  def __exit__(self ,type, value, traceback):
126  self.close()
def lsst.log.log.LogContext.close (   self)

Definition at line 136 of file log.py.

137  def close(self):
138  if self.name is not None:
139  popContext()
140  self.name = None
def popContext
Definition: log.py:58
def lsst.log.log.LogContext.getLevel (   self)

Definition at line 144 of file log.py.

145  def getLevel(self):
146  return getLevel("")
def lsst.log.log.LogContext.isEnabledFor (   self,
  level 
)

Definition at line 147 of file log.py.

148  def isEnabledFor(self, level):
149  return isEnabledFor("", level)
def lsst.log.log.LogContext.open (   self)

Definition at line 130 of file log.py.

131  def open(self):
132  if self.name is not None:
133  pushContext(self.name)
134  if self.level is not None:
135  setLevel("", self.level)
def pushContext
Definition: log.py:55
def lsst.log.log.LogContext.setLevel (   self,
  level 
)

Definition at line 141 of file log.py.

142  def setLevel(self, level):
143  setLevel("", level)

Member Data Documentation

lsst.log.log.LogContext.level

Definition at line 118 of file log.py.

lsst.log.log.LogContext.name

Definition at line 117 of file log.py.


The documentation for this class was generated from the following file: