Package schrodinger :: Package infra :: Module mmlist :: Class mmlist
[hide private]
[frames] | no frames]

Class mmlist

       object --+    
                |    
mmobject.MmObject --+
                    |
                   mmlist

Wrap an anderlying mmlist "instance" and provides access to its members through the python sequence syntax.

Instance Methods [hide private]
 
__init__(self, handle_or_list, manage_handle=True)
Initialize an object with an existing mmlist handle or python list of ints.
 
_delete(self)
A function to terminate this object.
 
__repr__(self)
Programmer-readable representation, prints the mmlist handle
 
__len__(self)
Return the number of elements in the mmlist.
 
__getitem__(self, index)
Return an item from the underlying mmlist library.
 
__setitem__(self, index, value)
Set an item in the underlying mmlist library.
 
__delitem__(self, index)
 
__iter__(self)
Provide an iterator over the list.
 
__contains__(self, value)
Returns True if the list contains the specified value, False otherwise

Inherited from mmobject.MmObject: __del__, __int__

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __str__, __subclasshook__

Static Methods [hide private]
 
initialize(error_handler=None)
Initialize mmlist.
 
terminate()
Terminate mmlist.
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, handle_or_list, manage_handle=True)
(Constructor)

 

Initialize an object with an existing mmlist handle or python list of ints.

Overrides: object.__init__

_delete(self)

 

A function to terminate this object. Required for MmObject interface.

__repr__(self)
(Representation operator)

 

Programmer-readable representation, prints the mmlist handle

Overrides: object.__repr__

__iter__(self)

 

Provide an iterator over the list. This also allows one to create a python list by invoking list() on an instantiated mmlist object.