CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
helpers.GatherAllModulesVisitor Class Reference
Inheritance diagram for helpers.GatherAllModulesVisitor:

Public Member Functions

def __init__ (self, gatheredInstance=cms._Module)
 
def enter (self, visitee)
 
def leave (self, visitee)
 
def modules (self)
 

Private Attributes

 _gatheredInstance
 
 _modules
 

Detailed Description

Visitor that travels within a cms.Sequence, and returns a list of objects of type gatheredInance(e.g. modules) that have it

Definition at line 137 of file helpers.py.

Constructor & Destructor Documentation

def helpers.GatherAllModulesVisitor.__init__ (   self,
  gatheredInstance = cms._Module 
)

Definition at line 139 of file helpers.py.

139  def __init__(self, gatheredInstance=cms._Module):
140  self._modules = []
141  self._gatheredInstance= gatheredInstance
def __init__(self, gatheredInstance=cms._Module)
Definition: helpers.py:139

Member Function Documentation

def helpers.GatherAllModulesVisitor.enter (   self,
  visitee 
)

Definition at line 142 of file helpers.py.

References helpers.GatherAllModulesVisitor._gatheredInstance.

142  def enter(self,visitee):
143  if isinstance(visitee,self._gatheredInstance):
144  self._modules.append(visitee)
def enter(self, visitee)
Definition: helpers.py:142
def helpers.GatherAllModulesVisitor.leave (   self,
  visitee 
)

Definition at line 145 of file helpers.py.

145  def leave(self,visitee):
146  pass
def leave(self, visitee)
Definition: helpers.py:145
def helpers.GatherAllModulesVisitor.modules (   self)

Definition at line 147 of file helpers.py.

147  def modules(self):
148  return self._modules
149 

Member Data Documentation

helpers.GatherAllModulesVisitor._gatheredInstance
private
helpers.GatherAllModulesVisitor._modules
private

Definition at line 140 of file helpers.py.

Referenced by helpers.GatherAllModulesVisitor.modules().