pidibble.baserecord module¶
- class pidibble.baserecord.BaseRecord(input_dict)[source]¶
Bases:
objectA class representing a base record with fields and methods for parsing and displaying.
- empty()[source]¶
Check if the record is empty, meaning all fields are empty strings.
- Returns:
True if all fields are empty strings, False otherwise.
- Return type:
- class pidibble.baserecord.BaseRecordParser(fmtdict, typemap, allowed={})[source]¶
Bases:
StringParserA parser for fixed-width string records that generates BaseRecord instances. Inherits from
StringParser.- add_fields(fields)[source]¶
Add fields to the parser’s field map.
- Parameters:
fields (dict) – A dictionary of fields to add to the parser’s field map.