IMP logo
Public Member Functions | Public Attributes
IMP.isd.utils.Pipe Class Reference

Detailed Description

implements a FIFO pipe that merges lists (see self.put)

List of all members.

Public Member Functions

def __init__
def __getitem__
def __len__
def __str__
def append
 x must be a list and will be appended to the end of the pipe, dropping rightmost elements if necessary
def get
 returns the oldest element, without popping it out of the pipe.
def is_full
def put
 if x is subscriptable, insert its contents at the beginning of the pipe.

Public Attributes

 length
 pipe

Member Function Documentation

def IMP.isd.utils.Pipe.append (   self,
  x 
)

x must be a list and will be appended to the end of the pipe, dropping rightmost elements if necessary

def IMP.isd.utils.Pipe.get (   self)

returns the oldest element, without popping it out of the pipe.

Popping occurs in the put() method

def IMP.isd.utils.Pipe.put (   self,
  x 
)

if x is subscriptable, insert its contents at the beginning of the pipe.

Else insert the element itself. If the pipe is full, drop the oldest element.


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

Generated on Tue May 22 2012 23:33:36 for IMP by doxygen 1.8.1