MS3RecordList

class pymseed.mstracelist.MS3RecordList(cffi_ptr, parent_tracelist)[source]

Bases: object

Wrapper around CFFI MS3RecordList structure

This class supports list-like access to the record pointers:

  • len(record_list) returns the number of records

  • record_list[i] returns the i-th record pointer

  • record_list[start:end] returns a slice of record pointers

  • for record_ptr in record_list: iterates over all record pointers

Invalidated when the owning MS3TraceList is closed; using it afterward raises ValueError instead of reading freed memory.

Parameters:
  • cffi_ptr (Any)

  • parent_tracelist (Any)

__len__()[source]

Return number of records

Return type:

int

__getitem__(key)[source]

Enable indexing and slicing access to record pointers

Parameters:

key (int | slice)

Return type:

Any

__iter__()[source]

Return iterator over record pointers

Return type:

Iterator[MS3RecordPtr]

records()[source]

Alias for __iter__()

Return type:

Iterator[MS3RecordPtr]

property recordcnt: int

Return record count