Package transsys :: Class CyclicSequence
[hide private]
[frames] | no frames]

Class CyclicSequence

source code

object --+
         |
        CyclicSequence

A convenience class for use with RandomTranssysParameters. Implements an object from which numerical values can be pulled out indefinitely using the nextval() method. Values are taken sequentially from a list, repeating from the start when the end is reached.

One could subclass from this class in order to design other value generators. But then, this might be of limited use, considering that all methods will have to be overridden anyway.

Instance Methods [hide private]
 
__init__(self, l, start=None)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
__str__(self)
str(x)
source code
 
from_string(self, s) source code
 
currval(self) source code
 
nextval(self) source code
 
reset(self) source code

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, l, start=None)
(Constructor)

source code 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Overrides: object.__init__
(inherited documentation)

__str__(self)
(Informal representation operator)

source code 

str(x)

Overrides: object.__str__
(inherited documentation)