CMS 3D CMS Logo

Public Member Functions | Private Attributes

pileupParser::pileupParser Class Reference

List of all members.

Public Member Functions

def __init__
def numls
def numruns
def runs
def runsandls
def runsandlsStr

Private Attributes

 __result
 __strresult

Detailed Description

Definition at line 3 of file pileupParser.py.


Constructor & Destructor Documentation

def pileupParser::pileupParser::__init__ (   self,
  selectStr 
)

Definition at line 4 of file pileupParser.py.

00005                                 :
00006         self.__result={}
00007         self.__strresult={}
00008         strresult=json.loads(selectStr)
00009         for k,v in strresult.items():
00010 #            expandedvalues=[]
00011 #            print v
00012             ldict={}
00013             for elems in v:
00014                 llist = [ elems[1],elems[2],elems[3] ]
00015                 ldict[int(elems[0])] = llist
00016 
00017 
00018 #            for w in v:
00019 #                if len(w)==0:
00020 #                    self.__result[int(k)]=expandedvalues
00021 #                    self.__strresult[k]=[]
00022 #                    continue
00023             ###weed out [10]-like stuff just in case they exist
00024 #                elif len(w)==1:
00025 #                    expandedvalues.append(w[0])
00026             ##weed out [10,10]-like stuff
00027 #                elif len(w)==2 and w[0]==w[1]:
00028 #                    expandedvalues.append(w[0])
00029 #                else:
00030 #                    for i in range(w[0],w[1]+1):
00031 #                        expandedvalues.append(i)
00032             self.__result[int(k)]=ldict
#            self.__strresult[k]=[str(x) for x in expandedvalues]

Member Function Documentation

def pileupParser::pileupParser::numls (   self,
  run 
)

Definition at line 45 of file pileupParser.py.

00046                        :
        return len(self.__result[run])
def pileupParser::pileupParser::numruns (   self)

Definition at line 43 of file pileupParser.py.

00044                      :
        return len(self.__result.keys())
def pileupParser::pileupParser::runs (   self)

Definition at line 33 of file pileupParser.py.

00034                   :
        return self.__result.keys()
def pileupParser::pileupParser::runsandls (   self)
return expanded {run:lslist}

Definition at line 35 of file pileupParser.py.

00036                        :
00037         '''return expanded {run:lslist}
00038         '''
        return self.__result
def pileupParser::pileupParser::runsandlsStr (   self)
return expanded {'run':lslist}

Definition at line 39 of file pileupParser.py.

00040                           :
00041         '''return expanded {'run':lslist}
00042         '''
        return self.__strresult

Member Data Documentation

Definition at line 4 of file pileupParser.py.

Definition at line 4 of file pileupParser.py.