# ImportBase `class ImportBase` Defined in [import_base.hpp:16](../../../../src/imports/import_base.hpp#L16) Base class for importing data from a file. This class provides a foundation for parsing files and managing system parts and signals. Derived classes must implement the ``parse`` method. method. ## Protected Attributes ### `Parts * prts` ๐Ÿ“ [import_base.hpp:19](../../../../src/imports/import_base.hpp#L19) Pointer to the [Parts](../classes/Parts.md) object. object. ### `std::fstream file_lines` ๐Ÿ“ [import_base.hpp:20](../../../../src/imports/import_base.hpp#L20) File stream for reading the input file. ## Public Functions ### `ImportBase(std::string file_name)` ๐Ÿ“ [import_base.hpp:30](../../../../src/imports/import_base.hpp#L30) Constructor for [ImportBase](../classes/ImportBase.md).. Initializes the file stream and creates new [Parts](../classes/Parts.md) and and [Signals](../classes/Signals.md) objects. objects. **Parameters** - `file_name` โ€” Name of the file to be imported. ### `void parse(Signals *signals)=0` ๐Ÿ“ [import_base.hpp:42](../../../../src/imports/import_base.hpp#L42) Pure virtual method for parsing the file. Derived classes must implement this method to define how the file is parsed. **Parameters** - `signals` โ€” Pointer to the signals object to be completed. ### `Parts * parts()` ๐Ÿ“ [import_base.hpp:48](../../../../src/imports/import_base.hpp#L48) Retrieves the [Parts](../classes/Parts.md) object. object. **Returns** Pointer to the [Parts](../classes/Parts.md) object. ### `~ImportBase()=default` ๐Ÿ“ [import_base.hpp:58](../../../../src/imports/import_base.hpp#L58) Virtual destructor for [ImportBase](../classes/ImportBase.md).. Ensures proper cleanup of derived classes. --- โ† [Back to classes](index.md) ยท [Top](../index.md)