CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Public Attributes
psClasses.queueNode Class Reference

Public Member Functions

def __init__
 
def append
 
def pendingThreads
 
def queueWeight
 

Public Attributes

 QueueSem
 
 RunningThreads
 
 ThreadLog
 

Detailed Description

Definition at line 182 of file psClasses.py.

Constructor & Destructor Documentation

def psClasses.queueNode.__init__ (   self,
  cores = 4,
  jay = 2 
)

Definition at line 183 of file psClasses.py.

184  def __init__(self,cores = 4,jay = 2):
185  self.QueueSem = BoundedSemaphore(value=cores/jay)
186  self.RunningThreads = []
187  self.ThreadLog = []

Member Function Documentation

def psClasses.queueNode.append (   self,
  item 
)

Definition at line 188 of file psClasses.py.

Referenced by diclist.diclist.add(), Vispa.Views.PropertyView.PropertyView.addProperty(), and BeautifulSoup.Tag.setString().

189  def append(self,item):
190  self.RunningThreads.append(item)
191  t=time.time()
192  self.ThreadLog.append([t,item.BuildNode.LibName,"INFO: %s thread %s added for Library %s" % (t,item.name,item.BuildNode.LibName)])
def psClasses.queueNode.pendingThreads (   self)

Definition at line 193 of file psClasses.py.

References psClasses.queueNode.RunningThreads.

194  def pendingThreads(self):
195  return len([x for x in self.RunningThreads if x.is_alive()])
def psClasses.queueNode.queueWeight (   self)

Definition at line 196 of file psClasses.py.

References psClasses.queueNode.RunningThreads.

197  def queueWeight(self):
198  return sum([x.Weight for x in self.RunningThreads if x.is_alive()])
199 
200 

Member Data Documentation

psClasses.queueNode.QueueSem

Definition at line 184 of file psClasses.py.

psClasses.queueNode.RunningThreads

Definition at line 185 of file psClasses.py.

Referenced by psClasses.queueNode.pendingThreads(), and psClasses.queueNode.queueWeight().

psClasses.queueNode.ThreadLog

Definition at line 186 of file psClasses.py.