CMS 3D CMS Logo

Public Member Functions | Private Attributes | Static Private Attributes

editorTools::ChangeSource Class Reference

Inherits FWCore::GuiBrowsers::ConfigToolBase::ConfigToolBase.

List of all members.

Public Member Functions

def __call__
def __init__
def getDefaultParameters
def toolCode

Private Attributes

 _comment
 _parameters

Static Private Attributes

tuple _defaultParameters = dicttypes.SortedKeysDict()
string _label = 'changeSource'

Detailed Description

Tool for changing the source of a Process;
    Implemented for testing purposes.

Definition at line 31 of file editorTools.py.


Constructor & Destructor Documentation

def editorTools::ChangeSource::__init__ (   self)

Definition at line 39 of file editorTools.py.

00040                       :
00041         ConfigToolBase.__init__(self)
00042         self.addParameter(self._defaultParameters,'source','No default value. Set your own', ' Source filenames')
00043         self._parameters=copy.deepcopy(self._defaultParameters)
00044         self._comment = ""
        

Member Function Documentation

def editorTools::ChangeSource::__call__ (   self,
  process,
  source = None 
)

Definition at line 48 of file editorTools.py.

00049                                            :
00050         if source is None:
00051            source=self._defaultParameters['source'].value 
00052         self.setParameter('source',source)
00053         self.apply(process) 
        
def editorTools::ChangeSource::getDefaultParameters (   self)

Definition at line 45 of file editorTools.py.

00046                                   :
00047         return self._defaultParameters
   
def editorTools::ChangeSource::toolCode (   self,
  process 
)

Definition at line 54 of file editorTools.py.

00055                                :
00056         source=self._parameters['source'].value
00057         process.source.fileNames=cms.untracked.vstring(source)
00058     
00059 changeSource=ChangeSource()


Member Data Documentation

Definition at line 39 of file editorTools.py.

tuple editorTools::ChangeSource::_defaultParameters = dicttypes.SortedKeysDict() [static, private]

Definition at line 38 of file editorTools.py.

string editorTools::ChangeSource::_label = 'changeSource' [static, private]

Definition at line 37 of file editorTools.py.

Definition at line 39 of file editorTools.py.