IDiseaseExporter
Configuration
Initialise #
Configure dependencies required for the exporter.
Signature:
Public Sub Initialise(ByVal workbookManager As IDiseaseExportWorkbook, ByVal appGuard As IDiseaseApplicationState)
Parameters:
workbookManager: IDiseaseExportWorkbook responsible for workbook lifecycle.appGuard: IDiseaseApplicationState guarding Application state toggles.
Disease Export
BuildDiseaseWorkbook #
Build an export workbook in-memory for the supplied disease worksheet.
Signature:
Public Function BuildDiseaseWorkbook(ByVal diseaseSheet As Worksheet, _
ByVal translationTable As ListObject, _
ByVal ribbonTranslations As ITranslationObject, _
ByVal diseaseName As String, _
ByVal languageTag As String, _
Optional ByVal diseaseCode As String = vbNullString) As Workbook
Parameters:
diseaseSheet: Worksheet containing the disease table and metadata.translationTable: ListObject providing translation values to copy.ribbonTranslations: ITranslationObject translating choice headers (may be Nothing).diseaseName: String disease identifier used in metadata.languageTag: String language captured in metadata.diseaseCode: Optional String disease tag/code for metadata.
Returns: Workbook populated with export worksheets. Caller owns lifecycle.
ExportDisease #
Export a disease workbook to disk.
Signature:
Public Function ExportDisease(ByVal exportFolder As String, _
ByVal diseaseSheet As Worksheet, _
ByVal translationTable As ListObject, _
ByVal ribbonTranslations As ITranslationObject, _
ByVal diseaseName As String, _
ByVal languageTag As String, _
Optional ByVal diseaseCode As String = vbNullString) As String
Parameters:
exportFolder: String folder path where the workbook is saved.diseaseSheet: Worksheet containing the disease table.translationTable: ListObject providing translation values.ribbonTranslations: ITranslationObject translating choice headers.diseaseName: String disease identifier used in metadata and file name.languageTag: String disease language stored in metadata.diseaseCode: Optional String disease tag/code for metadata.
Returns: String file path of the saved workbook.
Migration Export
BuildMigrationWorkbook #
Build a migration workbook aggregating multiple diseases.
Signature:
Public Function BuildMigrationWorkbook(ByVal sourceWorkbook As Workbook, _
ByVal diseaseNames As BetterArray) As Workbook
Parameters:
sourceWorkbook: Workbook hosting dictionary/choices/translation sheets.diseaseNames: BetterArray listing disease worksheet names to export.
Returns: Workbook populated with migration data. Caller owns lifecycle.
ExportForMigration #
Export the migration workbook to disk.
Signature:
Public Function ExportForMigration(ByVal exportFolder As String, _
ByVal sourceWorkbook As Workbook, _
ByVal diseaseNames As BetterArray) As String
Parameters:
exportFolder: String folder path where the workbook is saved.sourceWorkbook: Workbook hosting dictionary resources.diseaseNames: BetterArray listing disease worksheet names to export.
Returns: String file path of the saved workbook.