Package schrodinger :: Package application :: Package desmond :: Package packages :: Package msys :: Class IndexedFileLoader
[hide private]
[frames] | no frames]

Class IndexedFileLoader

object --+
         |
        IndexedFileLoader

Supports random access to multi-structure files

Instance Methods [hide private]
 
__init__(self, path, idx_path=None)
Open an indexed file loader, creating an index file if needed.
 
__len__(self)
number of entries
 
__getitem__(self, index)
Get structure at given index

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

Properties [hide private]
  path
path to source file

Inherited from object: __class__

Method Details [hide private]

__init__(self, path, idx_path=None)
(Constructor)

 
Open an indexed file loader, creating an index file if needed.
Args:
    path (str): file path.  File type is inferred from the extension.
    idx_path (str): index file path.  Defaults to $path.idx.

Note:
    You need write permission to the location of the index file.

Overrides: object.__init__

__getitem__(self, index)
(Indexing operator)

 
Get structure at given index

Args:
    index (int): 0-based index

Returns:
    mol (System): msys System


Property Details [hide private]

path

path to source file

Get Method:
unreachable.path(self) - path to source file