TTMSFNCJSONToClass.ExportToDelphiFromFile Method
Generates Delphi class source from JSON stored in a file using default options.
API unit family: TMSFNCPersistence
Declaring type: TTMSFNCJSONToClass
Overloads
Overload 1
Generates Delphi class source from JSON stored in a file using default options.
class function ExportToDelphiFromFile(AFileName: string; ACallBack: TTMSFNCJSONToClassExportEvent = nil): string; overload;
__classmethod System::UnicodeString __fastcall ExportToDelphiFromFile(System::UnicodeString AFileName, _di_TTMSFNCJSONToClassExportEvent ACallBack = _di_TTMSFNCJSONToClassExportEvent())/* overload */;
Parameters
| Name | Description |
|---|---|
AFileName |
Path to the JSON file used as the source schema. |
ACallBack |
Optional callback that can adjust generated property names and types. |
Returns
The generated Delphi source text.
Overload 2
Generates Delphi class source from JSON stored in a file using the specified options.
class function ExportToDelphiFromFile(AFileName: string; AOptions: TTMSFNCJSONToClassOptions; ACallBack: TTMSFNCJSONToClassExportEvent = nil): string; overload;
__classmethod System::UnicodeString __fastcall ExportToDelphiFromFile(System::UnicodeString AFileName, const TTMSFNCJSONToClassOptions &AOptions, _di_TTMSFNCJSONToClassExportEvent ACallBack = _di_TTMSFNCJSONToClassExportEvent())/* overload */;
Parameters
| Name | Description |
|---|---|
AFileName |
Path to the JSON file used as the source schema. |
AOptions |
Generation options for class names, members, unit output, and implementation output. |
ACallBack |
Optional callback that can adjust generated property names and types. |
Returns
The generated Delphi source text.