diff --git a/.gitignore b/.gitignore index fea46b3..24162a0 100644 --- a/.gitignore +++ b/.gitignore @@ -3,8 +3,7 @@ *.formatted.json /samples-local *.mes -/source/json2pumltest.dpr -/source/json2pumltest.dproj -/source/json2pumltest.dsk -/source/json2pumltest.res *.log +*.dsv + + diff --git a/documentation/changelog.md b/documentation/changelog.md index 7e1a68e..12a6447 100644 --- a/documentation/changelog.md +++ b/documentation/changelog.md @@ -1,7 +1,22 @@ +# **json2puml v2.2.11.107** - 01.01.2024 +## All Editions +### Changed Feature +- Inputlist.description.curlparameter.name handling improved + - Not the names will automatically converted into the ${} format + - This fixes the wrong check if the parameter is defined at runtime which could lead to duplicate curlparameters +- All property name filters which are supporting wildcards are supporting now to exclude a property from a previous found by supporting a remove with a leading "-". + E.g. + "product*" + "-productOffering" + This will allow product and productCharacteristic but not productOffering. +- Internal performance optimization (by caching) when searching in the definition configurations +- Performance optimization by doing one plantuml call to convert all files of the same output format +- Installation uses now PlantUml v1.2023.13 + # **json2puml v2.2.10.106** - 05.09.2023 ## All Editions ### Changed Feature -- Inputlistfile.curlFileNameSuffix handling improved +- Inputlistfile.curlFileNameSuffix handling improved (#12) - Curl Variables with "." are now supported - if the first character is not ".", "-" or "_" a "." will be added diff --git a/documentation/json2puml documentation.docx b/documentation/json2puml documentation.docx index e18717a..aed7f2f 100644 Binary files a/documentation/json2puml documentation.docx and b/documentation/json2puml documentation.docx differ diff --git a/documentation/json2puml documentation.pdf b/documentation/json2puml documentation.pdf index 7796d98..d24486a 100644 Binary files a/documentation/json2puml documentation.pdf and b/documentation/json2puml documentation.pdf differ diff --git a/installation/json2pumlsetup.iss b/installation/json2pumlsetup.iss index 453f484..3cdd107 100644 --- a/installation/json2pumlsetup.iss +++ b/installation/json2pumlsetup.iss @@ -5,9 +5,9 @@ #define MyAppVersion GetVersionNumbersString("..\source\Win64\Release\json2puml.exe") #define MyAppPublisher "Jens Fudickar" #define MyAppExeName "json2puml.exe" -#define plantumljarversion "1.2023.11" -#define plantumljarlink "https://github.com/plantuml/plantuml/releases/download/v1.2023.11/" -#define plantumljarfile "plantuml-1.2023.11.jar" +#define plantumljarversion "1.2023.13" +#define plantumljarlink "https://github.com/plantuml/plantuml/releases/download/v1.2023.13/" +#define plantumljarfile "plantuml-1.2023.13.jar" [Setup] ; NOTE: The value of AppId uniquely identifies this application. @@ -30,7 +30,7 @@ UsePreviousGroup=true WizardStyle=modern AlwaysShowGroupOnReadyPage=True AlwaysShowDirOnReadyPage=True -AppCopyright=(c) by Jens Fudickar in 2023 +AppCopyright=(c) by Jens Fudickar in 2023-2024 VersionInfoVersion={#MyAppVersion} VersionInfoCompany=Softwaredevelopment Jens Fudickar VersionInfoDescription=Json2Puml Installation File diff --git a/samples/tmf/tmf-definition.json b/samples/tmf/tmf-definition.json index 44eda9c..4a0cd85 100644 --- a/samples/tmf/tmf-definition.json +++ b/samples/tmf/tmf-definition.json @@ -15,7 +15,7 @@ "legendShowInfo": null, "legendShowObjectFormats": null, "legendShowFileInfos": null, - "attributeProperties": { + "attributeProperties": { "operation": "replace", "list": [ "id", @@ -50,27 +50,7 @@ "metadata*" ], "pumlHeaderLines": [ - ], - "objectFormats": { - "baseFormat": { - "objectFilter": [], - "iconColor": null, - "skinParams": [], - "captionShowIdent": null, - "captionShowTitle": null, - "captionShowType": null, - "captionSplitCharacter": null, - "captionSplitLength": null, - "showAttributes": null, - "showCharacteristics": null, - "showFromRelations": null, - "showIfEmpty": null, - "showNullValues": null, - "showToRelations": null, - "sortAttributes": null, - "valueSplitLength": null - } - } + ] } }, { @@ -83,13 +63,13 @@ "legendShowInfo": null, "legendShowObjectFormats": null, "legendShowFileInfos": null, - "attributeProperties": { + "attributeProperties": { "operation": "replace", "list": [ "*" ] }, - "objectProperties": { + "objectProperties": { "operation": "replace", "list": [ "geographicAddress", @@ -125,27 +105,7 @@ "metadata*" ], "pumlHeaderLines": [ - ], - "objectFormats": { - "baseFormat": { - "objectFilter": [], - "iconColor": null, - "skinParams": [], - "captionShowIdent": null, - "captionShowTitle": null, - "captionShowType": null, - "captionSplitCharacter": null, - "captionSplitLength": null, - "showAttributes": null, - "showCharacteristics": null, - "showFromRelations": null, - "showIfEmpty": null, - "showNullValues": null, - "showToRelations": null, - "sortAttributes": null, - "valueSplitLength": null - } - } + ] } }, { @@ -222,7 +182,7 @@ "attributeProperties": [ "*" ], - "objectProperties": { + "objectProperties": { "operation": "replace", "list": [ {"objectName": "*","generateWithoutIdentifier": "true"} @@ -284,7 +244,7 @@ "legendShowInfo": null, "legendShowObjectFormats": null, "legendShowFileInfos": null, - "attributeProperties": { + "attributeProperties": { "operation": "replace", "list": [ "id", @@ -292,7 +252,7 @@ "status" ] }, - "objectProperties": { + "objectProperties": { "operation": "replace", "list": [ "product", @@ -307,7 +267,7 @@ ], "objectTitleProperties": [ ], - "objectDetailProperties": { + "objectDetailProperties": { "operation": "replace", "list": [ ] @@ -358,17 +318,19 @@ "legendShowInfo": null, "legendShowObjectFormats": null, "legendShowFileInfos": null, - "attributeProperties": { + "attributeProperties": { "operation": "replace", "list": [ "*" ] }, - "objectProperties": { + "objectProperties": { "operation": "replace", "list": [ "product", "productPrice", + "productOffering", + "productSpecification", "customer" ] }, @@ -380,7 +342,7 @@ ], "objectTitleProperties": [ ], - "objectDetailProperties": { + "objectDetailProperties": { "operation": "replace", "list": [ ] @@ -398,27 +360,7 @@ "hiddenProperties": [ ], "pumlHeaderLines": [ - ], - "objectFormats": { - "baseFormat": { - "objectFilter": [], - "iconColor": null, - "skinParams": [], - "captionShowIdent": null, - "captionShowTitle": null, - "captionShowType": null, - "captionSplitCharacter": null, - "captionSplitLength": null, - "showAttributes": null, - "showCharacteristics": null, - "showFromRelations": null, - "showIfEmpty": null, - "showNullValues": null, - "showToRelations": null, - "sortAttributes": null, - "valueSplitLength": null - } - } + ] } }, { @@ -431,7 +373,7 @@ "legendShowInfo": null, "legendShowObjectFormats": null, "legendShowFileInfos": null, - "attributeProperties": { + "attributeProperties": { "operation": "replace", "list": [ "id", @@ -439,7 +381,7 @@ "status" ] }, - "objectProperties": { + "objectProperties": { "operation": "replace", "list": [ {"objectName": "*","generateWithoutIdentifier": "true"} @@ -502,7 +444,7 @@ "legendShowInfo": null, "legendShowObjectFormats": null, "legendShowFileInfos": null, - "attributeProperties": { + "attributeProperties": { "operation": "replace", "list": [ "id", @@ -603,6 +545,7 @@ "itemPrice", "productPrice", "productOffering", + "productSpecification", "agreement", "agreementItem", "paymentMethod", @@ -621,8 +564,7 @@ "billsummary", "billsummaryItem", "subscription", - "PartyPrivacyProfile", - "partyPrivacyProfileSpecification" + "partyPrivacyProfile" ], "objectTypeProperties": [ "refType", @@ -725,6 +667,7 @@ {"parentProperty": "troubleticket.statusChange", "type": "list", "propertyList": ["changeDate", "status", "*"]}, {"parentProperty": "note", "type": "list", "propertyList": ["date", "author", "text", "*"]}, {"parentProperty": "historyChange", "type": "list", "propertyList": ["operation", "path", "oldValue", "newValue", "*"]}, + {"parentProperty": "actionReason", "type": "list", "propertyList": ["action", "reason", "*"]}, {"parentProperty": "*characteristic", "type": "list", "propertyList": ["name", "value", "*", "-metadataType", "-valueMetadata"]}, "tax*Amount", "exemptAmount", @@ -736,6 +679,7 @@ "presentationMedia", "format", "cycleSpecification", + "partyPrivacyProfileSpecification", "periodCoverage", "taxDefinition", "immediatePayOption", @@ -831,14 +775,6 @@ "skinParams": ["BackgroundColor=deepskyBlue"] } }, - { - "formatName": "productOffering", - "definition": { - "objectFilter": ["productOffering"], - "iconColor": "IndianRed", - "skinParams": ["BackgroundColor=DarkSalmon"] - } - }, { "formatName": "productOrder", "definition": { @@ -852,14 +788,25 @@ "orderTotalPrice" ], "iconColor": "DarkGreen", - "skinParams": ["BackgroundColor=Lime"] + "skinParams": ["BackgroundColor=LimeGreen"] } }, { "formatName": "product", + "definition": { + "objectFilter": ["product"], + "iconColor": "Green", + "skinParams": ["BackgroundColor=LawnGreen"] + } + }, + { + "formatName": "productDetails", "definition": { "objectFilter": [ "product*", + "product.*", + "-productOffering", + "-productSpecification", "Price", "appliedCustomerBillingRate" ], @@ -867,6 +814,17 @@ "skinParams": ["BackgroundColor=LightGreen"] } }, + { + "formatName": "productCatalogue", + "definition": { + "objectFilter": [ + "productOffering", + "productSpecification" + ], + "iconColor": "IndianRed", + "skinParams": ["BackgroundColor=DarkSalmon"] + } + }, { "formatName": "customer", "definition": { @@ -883,8 +841,8 @@ "agreementItem", "commitment" ], - "iconColor": "Crimson", - "skinParams": ["BackgroundColor=red"] + "iconColor": "LimeGreen", + "skinParams": ["BackgroundColor=lime"] } }, { diff --git a/source/.gitignore b/source/.gitignore index 65bb849..3fa5236 100644 --- a/source/.gitignore +++ b/source/.gitignore @@ -1,5 +1,5 @@ # IDE files -*.~*~ +*.~* *.local *.identcache __history @@ -19,9 +19,11 @@ __recovery *.dcp *.o *. +*.dsk # Output Folder /Win32 /Win64 /Linux64 -/*.~dsk + +json2pumltest.* diff --git a/source/json2puml.deployproj b/source/json2puml.deployproj index 985523c..a1b94ce 100644 --- a/source/json2puml.deployproj +++ b/source/json2puml.deployproj @@ -37,7 +37,6 @@ True - json2puml\Assets\ @@ -49,5 +48,4 @@ True - diff --git a/source/json2puml.dproj b/source/json2puml.dproj index bf7ab75..8912e02 100644 --- a/source/json2puml.dproj +++ b/source/json2puml.dproj @@ -1,7 +1,7 @@  {E903A176-7082-4D7A-A892-70F74057713D} - 19.5 + 20.1 None True Debug @@ -13,16 +13,6 @@ true - - true - Base - true - - - true - Base - true - true Base @@ -87,24 +77,16 @@ ..\documentation\icons\json2puml-icon.png ..\documentation\icons\json2puml-icon.png - - CFBundleName=$(MSBuildProjectName);CFBundleDisplayName=$(MSBuildProjectName);CFBundleIdentifier=$(MSBuildProjectName);CFBundleVersion=1.0.0;CFBundleShortVersionString=1.0.0;CFBundlePackageType=APPL;CFBundleSignature=????;CFBundleAllowMixedLocalizations=YES;CFBundleExecutable=$(MSBuildProjectName);NSHighResolutionCapable=true;LSApplicationCategoryType=public.app-category.utilities;NSLocationUsageDescription=The reason for accessing the location information of the user;NSContactsUsageDescription=The reason for accessing the contacts;NSCalendarsUsageDescription=The reason for accessing the calendar data;NSRemindersUsageDescription=The reason for accessing the reminders;NSCameraUsageDescription=The reason for accessing the camera;NSMicrophoneUsageDescription=The reason for accessing the microphone;NSMotionUsageDescription=The reason for accessing the accelerometer;NSDesktopFolderUsageDescription=The reason for accessing the Desktop folder;NSDocumentsFolderUsageDescription=The reason for accessing the Documents folder;NSDownloadsFolderUsageDescription=The reason for accessing the Downloads folder;NSNetworkVolumesUsageDescription=The reason for accessing files on a network volume;NSRemovableVolumesUsageDescription=The reason for accessing files on a removable volume;NSSpeechRecognitionUsageDescription=The reason for requesting to send user data to Apple's speech recognition servers - Debug - - - CFBundleName=$(MSBuildProjectName);CFBundleDisplayName=$(MSBuildProjectName);CFBundleIdentifier=$(MSBuildProjectName);CFBundleVersion=1.0.0;CFBundleShortVersionString=1.0.0;CFBundlePackageType=APPL;CFBundleSignature=????;CFBundleAllowMixedLocalizations=YES;CFBundleExecutable=$(MSBuildProjectName);NSHighResolutionCapable=true;LSApplicationCategoryType=public.app-category.utilities;NSLocationUsageDescription=The reason for accessing the location information of the user;NSContactsUsageDescription=The reason for accessing the contacts;NSCalendarsUsageDescription=The reason for accessing the calendar data;NSRemindersUsageDescription=The reason for accessing the reminders;NSCameraUsageDescription=The reason for accessing the camera;NSMicrophoneUsageDescription=The reason for accessing the microphone;NSMotionUsageDescription=The reason for accessing the accelerometer;NSDesktopFolderUsageDescription=The reason for accessing the Desktop folder;NSDocumentsFolderUsageDescription=The reason for accessing the Documents folder;NSDownloadsFolderUsageDescription=The reason for accessing the Downloads folder;NSNetworkVolumesUsageDescription=The reason for accessing files on a network volume;NSRemovableVolumesUsageDescription=The reason for accessing files on a removable volume;NSSpeechRecognitionUsageDescription=The reason for requesting to send user data to Apple's speech recognition servers - Debug - DBXSqliteDriver;IndyIPCommon;RESTComponents;bindcompdbx;DBXInterBaseDriver;vcl;IndyIPServer;vclactnband;vclFireDAC;IndySystem;bindcompvclsmp;tethering;svnui;bindcompvclwinx;dsnapcon;FireDACADSDriver;FireDACMSAccDriver;fmxFireDAC;vclimg;madBasic_;Jcl;FireDAC;vcltouch;vcldb;bindcompfmx;svn;FireDACSqliteDriver;FireDACPgDriver;inetdb;soaprtl;DbxCommonDriver;fmx;FireDACIBDriver;fmxdae;xmlrtl;soapmidas;vcledge;fmxobj;vclwinx;rtl;DbxClientDriver;CustomIPTransport;vcldsnap;dbexpress;IndyCore;vclx;bindcomp;appanalytics;dsnap;FireDACCommon;IndyIPClient;bindcompvcl;RESTBackendComponents;VCLRESTComponents;soapserver;dbxcds;VclSmp;adortl;JclDeveloperTools;JclVcl;vclie;bindengine;DBXMySQLDriver;CloudService;dsnapxml;FireDACMySQLDriver;dbrtl;IndyProtocols;inetdbxpress;FireDACCommonODBC;FireDACCommonDriver;JclContainers;inet;fmxase;$(DCC_UsePackage) Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace) Debug - FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 1033 true true (None) - 106 + 107 /parameterfile:samples\acrmcurlparameter.json /debug /wait e:\Delphi\Projects\json2puml\ ..\documentation\icons\json2puml_icon.png @@ -112,18 +94,18 @@ none 2 2 - 10 + 11 DBXSqliteDriver;IndyIPCommon;RESTComponents;bindcompdbx;DBXInterBaseDriver;vcl;IndyIPServer;vclactnband;vclFireDAC;IndySystem;bindcompvclsmp;tethering;bindcompvclwinx;dsnapcon;FireDACADSDriver;FireDACMSAccDriver;fmxFireDAC;vclimg;FireDAC;vcltouch;vcldb;bindcompfmx;FireDACSqliteDriver;FireDACPgDriver;inetdb;soaprtl;DbxCommonDriver;fmx;FireDACIBDriver;fmxdae;xmlrtl;soapmidas;vcledge;fmxobj;vclwinx;rtl;DbxClientDriver;CustomIPTransport;vcldsnap;dbexpress;IndyCore;vclx;bindcomp;appanalytics;dsnap;FireDACCommon;IndyIPClient;bindcompvcl;RESTBackendComponents;VCLRESTComponents;soapserver;dbxcds;VclSmp;adortl;vclie;bindengine;DBXMySQLDriver;CloudService;dsnapxml;FireDACMySQLDriver;dbrtl;IndyProtocols;inetdbxpress;FireDACCommonODBC;FireDACCommonDriver;inet;fmxase;$(DCC_UsePackage) true Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;$(DCC_Namespace) Debug - FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 1033 true (None) - 106 + 107 /parameterfile:samples\acrmcurlparameter.json /debug /wait e:\Delphi\Projects\json2puml\ ..\documentation\icons\json2puml_icon.png @@ -131,7 +113,7 @@ none 2 2 - 10 + 11 DEBUG;$(DCC_Define) @@ -151,25 +133,25 @@ true 1033 (Ohne) - 106 + 107 e:\Delphi\Projects\json2puml\ none - FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 2 2 - 10 + 11 3 true 1033 (None) - FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 - 106 + FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + 107 /parameterfile:docker\json2puml\src\json2puml\sample\tmfparameter.json /debug /wait 2 2 - 10 + 11 false @@ -178,21 +160,21 @@ 0 - FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 - 106 + FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + 107 2 2 - 10 + 11 - 106 + 107 e:\Delphi\Projects\json2puml\ 2 true 1033 - FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + FileDescription=$(MSBuildProjectName) Command Line;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 2 - 10 + 11 @@ -372,6 +354,16 @@ 1 + + + res\drawable-anydpi-v21 + 1 + + + res\drawable-anydpi-v21 + 1 + + res\values @@ -392,6 +384,66 @@ 1 + + + res\values-v31 + 1 + + + res\values-v31 + 1 + + + + + res\drawable-anydpi-v26 + 1 + + + res\drawable-anydpi-v26 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-anydpi-v33 + 1 + + + res\drawable-anydpi-v33 + 1 + + res\values @@ -402,6 +454,16 @@ 1 + + + res\values-night-v21 + 1 + + + res\values-night-v21 + 1 + + res\drawable @@ -572,6 +634,56 @@ 1 + + + res\drawable-anydpi-v24 + 1 + + + res\drawable-anydpi-v24 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-night-anydpi-v21 + 1 + + + res\drawable-night-anydpi-v21 + 1 + + + + + res\drawable-anydpi-v31 + 1 + + + res\drawable-anydpi-v31 + 1 + + + + + res\drawable-night-anydpi-v31 + 1 + + + res\drawable-night-anydpi-v31 + 1 + + 1 @@ -1108,8 +1220,6 @@ True - False - False True True diff --git a/source/json2puml.inc b/source/json2puml.inc index 0a7d242..918369a 100644 --- a/source/json2puml.inc +++ b/source/json2puml.inc @@ -1,3 +1,3 @@ {$DEFINE SYNEDIT} {$DEFINE SVGICONIMAGE} - +{.$DEFINE SKIASVG} diff --git a/source/json2puml.res b/source/json2puml.res index fe1fd03..e7542de 100644 Binary files a/source/json2puml.res and b/source/json2puml.res differ diff --git a/source/json2pumlapps.dsk b/source/json2pumlapps.dsk index c833c59..94461c4 100644 --- a/source/json2pumlapps.dsk +++ b/source/json2pumlapps.dsk @@ -1,71 +1,87 @@ [Closed Files] -File_0=TSourceModule,'E:\Delphi\Projects\json2puml\source\json2pumlcommandline.pas',0,1,43,1,65,0,0,, -File_1=TSourceModule,'E:\Delphi\Projects\json2puml\source\json2pumlpuml.pas',0,1,1635,103,1445,0,0,,{7,343,1} -File_2=TSourceModule,'E:\Delphi\Projects\json2puml\source\json2pumlservicecontroller.pas',0,1,210,19,237,0,0,, -File_3=TSourceModule,'E:\Delphi\Projects\json2puml\source\json2pumlservicewebmodule.pas',0,1,1,116,12,0,0,,{7,58,7} -File_4=TSourceModule,'c:\program files (x86)\embarcadero\studio\22.0\SOURCE\RTL\SYS\System.SysUtils.pas',0,1,10879,1,10900,0,0,, -File_5=TSourceModule,'c:\program files (x86)\embarcadero\studio\22.0\source\rtl\common\System.Classes.pas',0,1,9552,43,9564,0,0,, -File_6=TSourceModule,'E:\Delphi\Projects\json2puml\source\json2pumlframe.pas',0,1,75,24,90,0,0,, -File_7=TSourceModule,'E:\Delphi\Projects\json2puml\source\json2pumlconfigframe.pas',0,1,2,51,3,0,0,, -File_8=TSourceModule,'E:\Delphi\Projects\json2puml\source\json2pumlloghandler.pas',0,1,291,20,314,0,0,, -File_9=TSourceModule,'c:\program files (x86)\embarcadero\studio\22.0\SOURCE\RTL\SYS\System.pas',0,1,4902,1,4923,0,0,, -File_10=TSourceModule,'E:\Delphi\Components\QuickLogger\Quick.Logger.pas',0,1,1563,44,1586,0,0,, -File_11=TSourceModule,'e:\Delphi\Components\loggerpro\LoggerPro.pas',0,1,128,5,149,0,0,, -File_12=TSourceModule,'E:\Delphi\Components\delphimvcframework\sources\MVCFramework.Logger.pas',0,1,269,117,293,0,0,, -File_13=TSourceModule,'E:\Delphi\Components\delphimvcframework\sources\MVCFramework.pas',0,1,2304,1,2314,0,0,, -File_14=TSourceModule,'E:\Delphi\Components\loggerpro\LoggerPro.SimpleConsoleAppender.pas',0,1,1,18,42,0,0,, +File_0=TSourceModule,'E:\Delphi\Projects\json2puml\source\json2pumltools.pas',0,1,1232,24,1253,0,0,, +File_1=TSourceModule,'c:\program files (x86)\embarcadero\studio\23.0\SOURCE\RTL\SYS\System.SysUtils.pas',0,1,31589,60,31614,0,0,, +File_2=TSourceModule,'c:\program files (x86)\embarcadero\studio\23.0\source\DUnitX\DUnitX.Assert.Ex.pas',0,1,1,14,38,0,0,, +File_3=TSourceModule,'c:\Program Files (x86)\Embarcadero\Studio\23.0\source\DunitX\DUnitX.Assert.pas',0,1,446,1,471,0,0,, +File_4=TSourceModule,'c:\program files (x86)\embarcadero\studio\23.0\SOURCE\RTL\SYS\System.pas',0,1,39153,1,39176,0,0,, +File_5=TSourceModule,'c:\program files (x86)\embarcadero\studio\23.0\source\DUnitX\DUnitX.CommandLine.Options.pas',0,1,43,1,1,0,0,, +File_6=TSourceModule,'c:\program files (x86)\embarcadero\studio\23.0\source\DUnitX\DUnitX.TestFramework.pas',0,1,762,19,733,0,0,, +File_7=TSourceModule,'c:\Program Files (x86)\Embarcadero\Studio\23.0\source\DunitX\DUnitX.Loggers.GUI.VCL.pas',0,1,1073,62,1101,0,0,, +File_8=TSourceModule,'E:\Delphi\Projects\json2puml\source\json2pumlservicewebmodule.pas',0,1,99,1,37,0,0,, +File_9=TSourceModule,'c:\program files (x86)\embarcadero\studio\23.0\SOURCE\VCL\Vcl.Skia.pas',0,1,175,14,179,0,0,, +File_10=TSourceModule,'E:\Delphi\Components\SynEdit\Source\SynHighlighterMulti.pas',0,1,730,42,731,0,0,, +File_11=TSourceModule,'c:\program files (x86)\embarcadero\studio\22.0\source\rtl\common\System.IOUtils.pas',0,1,3248,24,3268,0,0,, +File_12=TSourceModule,'E:\Delphi\Components\QuickLogger\Quick.Logger.Provider.ADODB.pas',0,1,8,25,10,0,0,, +File_13=TSourceModule,'c:\program files (x86)\embarcadero\studio\22.0\source\rtl\win\Winapi.ActiveX.pas',0,1,6919,1,6942,0,0,, +File_14=TSourceModule,'E:\Delphi\Components\SVGIconImageList\Image32\source\Img32.SVG.Reader.pas',0,1,2135,31,2133,0,0,, [Modules] -Module0=E:\Delphi\Projects\json2puml\source\json2pumltools.pas -Module1=E:\Delphi\Projects\json2puml\source\json2pumlconst.pas -Module2=E:\Delphi\Projects\json2puml\source\json2pumldefinition.pas -Module3=E:\Delphi\Projects\json2puml\source\json2pumlinputhandler.pas -Module4=c:\program files (x86)\embarcadero\studio\22.0\source\rtl\common\System.IOUtils.pas -Module5=E:\Delphi\Projects\json2puml\source\json2pumlconverterdefinition.pas -Module6=E:\Delphi\Projects\json2puml\source\jsontools.pas -Module7=E:\Delphi\Projects\json2puml\source\json2pumlbasedefinition.pas -Module8=E:\Delphi\Projects\json2puml\source\json2pumlform.pas -Module9=E:\Delphi\Projects\json2puml\source\json2pumlconverter.pas -Module10=E:\Delphi\Components\SVGIconImageList\Image32\source\Img32.SVG.Reader.pas -Count=11 +Module0=E:\Delphi\Projects\json2puml\source\json2pumlbasedefinition.pas +Module1=E:\Delphi\Projects\json2puml\source\json2pumlconverterdefinition.pas +Module2=E:\Delphi\Projects\json2puml\unittests\ut.Json2PumlBasePropertyList.pas +Module3=E:\Delphi\Projects\json2puml\source\json2pumlui.dproj +Module4=E:\Delphi\Projects\json2puml\source\json2pumlwindowsservice.dproj +Module5=E:\Delphi\Projects\json2puml\source\json2pumlpuml.pas +Module6=E:\Delphi\Projects\json2puml\source\json2pumlconverter.pas +Module7=E:\Delphi\Projects\json2puml\unittests\uttJson2PumlFormatDefinition.pas +Module8=E:\Delphi\Projects\json2puml\source\json2pumlinputhandler.pas +Module9=E:\Delphi\Projects\json2puml\source\json2pumldefinition.pas +Module10=E:\Delphi\Projects\json2puml\source\json2puml.inc +Module11=E:\Delphi\Projects\json2puml\source\json2pumlframe.pas +Module12=E:\Delphi\Projects\json2puml\source\json2pumlform.pas +Module13=E:\Delphi\Projects\json2puml\source\json2pumlconst.pas +Module14=E:\Delphi\Projects\json2puml\source\jsontools.pas +Count=15 EditWindowCount=1 -[E:\Delphi\Projects\json2puml\source\json2pumltools.pas] +[E:\Delphi\Projects\json2puml\source\json2pumlbasedefinition.pas] ModuleType=TSourceModule -[E:\Delphi\Projects\json2puml\source\json2pumlconst.pas] +[E:\Delphi\Projects\json2puml\source\json2pumlconverterdefinition.pas] ModuleType=TSourceModule -[E:\Delphi\Projects\json2puml\source\json2pumldefinition.pas] +[E:\Delphi\Projects\json2puml\unittests\ut.Json2PumlBasePropertyList.pas] ModuleType=TSourceModule -[E:\Delphi\Projects\json2puml\source\json2pumlinputhandler.pas] +[E:\Delphi\Projects\json2puml\source\json2pumlui.dproj] +ModuleType=TBaseProject + +[E:\Delphi\Projects\json2puml\source\json2pumlwindowsservice.dproj] +ModuleType=TBaseProject + +[E:\Delphi\Projects\json2puml\source\json2pumlpuml.pas] ModuleType=TSourceModule -[c:\program files (x86)\embarcadero\studio\22.0\source\rtl\common\System.IOUtils.pas] +[E:\Delphi\Projects\json2puml\source\json2pumlconverter.pas] ModuleType=TSourceModule -[E:\Delphi\Projects\json2puml\source\json2pumlconverterdefinition.pas] +[E:\Delphi\Projects\json2puml\unittests\uttJson2PumlFormatDefinition.pas] ModuleType=TSourceModule -[E:\Delphi\Projects\json2puml\source\jsontools.pas] +[E:\Delphi\Projects\json2puml\source\json2pumlinputhandler.pas] ModuleType=TSourceModule -[E:\Delphi\Projects\json2puml\source\json2pumlbasedefinition.pas] +[E:\Delphi\Projects\json2puml\source\json2pumldefinition.pas] +ModuleType=TSourceModule + +[E:\Delphi\Projects\json2puml\source\json2puml.inc] +ModuleType=TSourceModule + +[E:\Delphi\Projects\json2puml\source\json2pumlframe.pas] ModuleType=TSourceModule [E:\Delphi\Projects\json2puml\source\json2pumlform.pas] ModuleType=TSourceModule -[E:\Delphi\Projects\json2puml\source\json2pumlconverter.pas] +[E:\Delphi\Projects\json2puml\source\json2pumlconst.pas] ModuleType=TSourceModule -[E:\Delphi\Components\SVGIconImageList\Image32\source\Img32.SVG.Reader.pas] +[E:\Delphi\Projects\json2puml\source\jsontools.pas] ModuleType=TSourceModule [EditWindow0] -ViewCount=11 -CurrentEditView=E:\Delphi\Projects\json2puml\source\json2pumltools.pas +ViewCount=15 +CurrentEditView=E:\Delphi\Projects\json2puml\source\json2pumlbasedefinition.pas View0=0 View1=1 View2=2 @@ -77,6 +93,10 @@ View7=7 View8=8 View9=9 View10=10 +View11=11 +View12=12 +View13=13 +View14=14 PercentageSizes=1 Create=1 Visible=1 @@ -95,13 +115,13 @@ BorlandEditorCodeExplorer=BorlandEditorCodeExplorer@EditWindow0 TopPanelSize=0 LeftPanelSize=1895 LeftPanelClients=PropertyInspector,DockSite3 -LeftPanelData=00000800010100000000831000000000000001670700000000000001000000005A0E000009000000446F636B536974653301000000005A1D00001100000050726F7065727479496E73706563746F72FFFFFFFF +LeftPanelData=00000800010100000000341000000000000001670700000000000001000000005A0E000009000000446F636B53697465330100000000CF1C00001100000050726F7065727479496E73706563746F72FFFFFFFF RightPanelSize=1996 RightPanelClients=DockSite2,DockSite4 -RightPanelData=00000800010100000000831000000000000001CC0700000000000001000000001913000009000000446F636B536974653201000000005A1D000009000000446F636B5369746534FFFFFFFF -BottomPanelSize=1375 +RightPanelData=00000800010100000000341000000000000001CC0700000000000001000000006F16000009000000446F636B53697465320100000000CF1C000009000000446F636B5369746534FFFFFFFF +BottomPanelSize=1514 BottomPanelClients=DockSite1,MessageView -BottomPanelData=0000080001020100000009000000446F636B53697465310345000000000000025F050000000000000100000000034500000F0000004D65737361676556696577466F726DFFFFFFFF +BottomPanelData=0000080001020100000009000000446F636B5369746531034500000000000002EA050000000000000100000000034500000F0000004D65737361676556696577466F726DFFFFFFFF BottomMiddlePanelSize=0 BottomMiddlePanelClients=DockSite0,GraphDrawingModel BottomMiddelPanelData=0000080001020200000009000000446F636B536974653010000000477261706844726177696E67566965779F1D00000000000002F206000000000000FFFFFFFF @@ -109,27 +129,60 @@ BottomMiddelPanelData=0000080001020200000009000000446F636B5369746530100000004772 [View0] CustomEditViewType=TEditView Module=E:\Delphi\Projects\json2puml\source\json2pumldefinition.pas -CursorX=82 -CursorY=1852 -TopLine=1826 +CursorX=19 +CursorY=2900 +TopLine=2875 LeftCol=1 Elisions= -Bookmarks={7,575,1} +Bookmarks= EditViewName=E:\Delphi\Projects\json2puml\source\json2pumldefinition.pas [View1] CustomEditViewType=TEditView Module=E:\Delphi\Projects\json2puml\source\json2pumlform.pas -CursorX=5 -CursorY=855 -TopLine=835 +CursorX=47 +CursorY=848 +TopLine=836 LeftCol=1 Elisions= Bookmarks= -EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlform.pas +EditViewName=Borland.FormDesignerView [View2] CustomEditViewType=TEditView +Module=E:\Delphi\Projects\json2puml\source\json2pumlframe.pas +CursorX=5 +CursorY=29 +TopLine=1 +LeftCol=1 +Elisions= +Bookmarks= +EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlframe.pas + +[View3] +CustomEditViewType=TEditView +Module=E:\Delphi\Projects\json2puml\source\json2puml.inc +CursorX=19 +CursorY=3 +TopLine=1 +LeftCol=1 +Elisions= +Bookmarks= +EditViewName=E:\Delphi\Projects\json2puml\source\json2puml.inc + +[View4] +CustomEditViewType=TEditView +Module=E:\Delphi\Projects\json2puml\source\json2pumlwindowsservice.dpr +CursorX=1 +CursorY=28 +TopLine=11 +LeftCol=1 +Elisions= +Bookmarks= +EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlwindowsservice.dpr + +[View5] +CustomEditViewType=TEditView Module=E:\Delphi\Projects\json2puml\source\jsontools.pas CursorX=15 CursorY=777 @@ -139,102 +192,112 @@ Elisions= Bookmarks={7,43,1} EditViewName=E:\Delphi\Projects\json2puml\source\jsontools.pas -[View3] +[View6] CustomEditViewType=TEditView Module=E:\Delphi\Projects\json2puml\source\json2pumlinputhandler.pas -CursorX=59 -CursorY=1494 -TopLine=1475 +CursorX=112 +CursorY=509 +TopLine=498 LeftCol=1 Elisions= -Bookmarks={7,574,1} +Bookmarks= EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlinputhandler.pas -[View4] +[View7] CustomEditViewType=TEditView Module=E:\Delphi\Projects\json2puml\source\json2pumlconverter.pas -CursorX=42 -CursorY=667 -TopLine=644 +CursorX=90 +CursorY=329 +TopLine=306 LeftCol=1 Elisions= Bookmarks= EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlconverter.pas -[View5] +[View8] +CustomEditViewType=TEditView +Module=E:\Delphi\Projects\json2puml\source\json2pumlpuml.pas +CursorX=65 +CursorY=511 +TopLine=473 +LeftCol=1 +Elisions= +Bookmarks= +EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlpuml.pas + +[View9] CustomEditViewType=TEditView Module=E:\Delphi\Projects\json2puml\source\json2pumlconverterdefinition.pas -CursorX=93 -CursorY=861 -TopLine=818 +CursorX=67 +CursorY=499 +TopLine=493 LeftCol=1 Elisions= Bookmarks= EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlconverterdefinition.pas -[View6] +[View10] CustomEditViewType=TEditView -Module=E:\Delphi\Projects\json2puml\source\json2pumlbasedefinition.pas -CursorX=1 -CursorY=434 -TopLine=413 +Module=E:\Delphi\Projects\json2puml\unittests\uttJson2PumlFormatDefinition.pas +CursorX=36 +CursorY=38 +TopLine=10 LeftCol=1 Elisions= Bookmarks= -EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlbasedefinition.pas +EditViewName=E:\Delphi\Projects\json2puml\unittests\uttJson2PumlFormatDefinition.pas -[View7] +[View11] CustomEditViewType=TEditView -Module=E:\Delphi\Projects\json2puml\source\json2pumltools.pas +Module=E:\Delphi\Projects\json2puml\unittests\ut.Json2PumlBasePropertyList.pas CursorX=1 -CursorY=799 -TopLine=764 +CursorY=1 +TopLine=1 LeftCol=1 Elisions= -Bookmarks={7,798,1} -EditViewName=E:\Delphi\Projects\json2puml\source\json2pumltools.pas +Bookmarks= +EditViewName=E:\Delphi\Projects\json2puml\unittests\ut.Json2PumlBasePropertyList.pas -[View8] +[View12] CustomEditViewType=TEditView -Module=c:\program files (x86)\embarcadero\studio\22.0\source\rtl\common\System.IOUtils.pas -CursorX=24 -CursorY=3268 -TopLine=3248 +Module=E:\Delphi\Projects\json2puml\source\json2pumlui.dpr +CursorX=1 +CursorY=46 +TopLine=1 LeftCol=1 Elisions= Bookmarks= -EditViewName=c:\program files (x86)\embarcadero\studio\22.0\source\rtl\common\System.IOUtils.pas +EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlui.dpr -[View9] +[View13] CustomEditViewType=TEditView -Module=E:\Delphi\Projects\json2puml\source\json2pumlconst.pas -CursorX=61 -CursorY=185 -TopLine=163 +Module=E:\Delphi\Projects\json2puml\source\json2pumlbasedefinition.pas +CursorX=1 +CursorY=1100 +TopLine=1093 LeftCol=1 Elisions= -Bookmarks={7,67,100} -EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlconst.pas +Bookmarks= +EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlbasedefinition.pas -[View10] +[View14] CustomEditViewType=TEditView -Module=E:\Delphi\Components\SVGIconImageList\Image32\source\Img32.SVG.Reader.pas -CursorX=31 -CursorY=2133 -TopLine=2114 +Module=E:\Delphi\Projects\json2puml\source\json2pumlconst.pas +CursorX=64 +CursorY=195 +TopLine=73 LeftCol=1 Elisions= -Bookmarks= -EditViewName=E:\Delphi\Components\SVGIconImageList\Image32\source\Img32.SVG.Reader.pas +Bookmarks={7,67,100} +EditViewName=E:\Delphi\Projects\json2puml\source\json2pumlconst.pas [Watches] -Count=6 -Watch0='SingleRecord.InputFile.InputFileName',256,0,18,1,0,'Watches',1 -Watch1='ExtractFileName(Value)',256,0,18,1,0,'Watches',1 -Watch2='FSummaryFileName',256,0,18,1,0,'Watches',1 -Watch3='ObjectIdent',256,0,18,1,0,'Überwachte Ausdrücke',1 -Watch4='ObjectTitle',256,0,18,1,0,'Überwachte Ausdrücke',1 -Watch5='ObjectType',256,0,18,1,0,'Überwachte Ausdrücke',1 +Count=5 +Watch0='Itemlist[i]',256,0,18,1,0,'Watches',1 +Watch1='self.ident',256,0,18,1,0,'Watches',1 +Watch2='ObjectIdent',256,0,18,1,0,'Überwachte Ausdrücke',1 +Watch3='ObjectTitle',256,0,18,1,0,'Überwachte Ausdrücke',1 +Watch4='ObjectType',256,0,18,1,0,'Überwachte Ausdrücke',1 [WatchWindow] WatchColumnWidth=120 @@ -247,11 +310,11 @@ State=0 Left=0 Top=0 Width=3824 -Height=1020 +Height=1221 MaxLeft=-1 MaxTop=-1 ClientWidth=3824 -ClientHeight=1020 +ClientHeight=1221 TBDockHeight=216 LRDockWidth=13602 Dockable=1 @@ -266,16 +329,13 @@ Breakpoint2='e:\Delphi\Components\QuickLogger\Quick.Logger.pas',1218,'',0,1,'',1 [EmbarcaderoWin32Debugger_AddressBreakpoints] Count=0 -[EmbarcaderoWin64Debugger_AddressBreakpoints] -Count=0 - -[EmbarcaderoLinux64Debugger_AddressBreakpoints] +[EmbarcaderoWin64xDebugger_AddressBreakpoints] Count=0 -[EmbarcaderoOSXArm64Debugger_AddressBreakpoints] +[EmbarcaderoWin64Debugger_AddressBreakpoints] Count=0 -[EmbarcaderoOSX64Debugger_AddressBreakpoints] +[EmbarcaderoLinux64Debugger_AddressBreakpoints] Count=0 [Main Window] @@ -307,11 +367,11 @@ State=0 Left=0 Top=0 Width=1996 -Height=4598 +Height=5481 MaxLeft=-1 MaxTop=-1 ClientWidth=1996 -ClientHeight=4598 +ClientHeight=5481 TBDockHeight=5898 LRDockWidth=2348 Dockable=1 @@ -326,12 +386,12 @@ State=0 Left=0 Top=28 Width=9938 -Height=1221 +Height=1365 MaxLeft=-1 MaxTop=-1 ClientWidth=9938 -ClientHeight=1221 -TBDockHeight=1221 +ClientHeight=1365 +TBDockHeight=1365 LRDockWidth=2770 Dockable=1 StayOnTop=0 @@ -345,11 +405,11 @@ State=0 Left=0 Top=0 Width=1996 -Height=2514 +Height=1487 MaxLeft=-1 MaxTop=-1 ClientWidth=1996 -ClientHeight=2514 +ClientHeight=1487 TBDockHeight=7155 LRDockWidth=1996 Dockable=1 @@ -364,11 +424,11 @@ State=0 Left=0 Top=557 Width=1895 -Height=3772 +Height=3628 MaxLeft=-1 MaxTop=-1 ClientWidth=1895 -ClientHeight=3772 +ClientHeight=3628 TBDockHeight=7004 LRDockWidth=1895 Dockable=1 @@ -425,11 +485,11 @@ State=0 Left=0 Top=0 Width=3824 -Height=1020 +Height=1221 MaxLeft=-1 MaxTop=-1 ClientWidth=3824 -ClientHeight=1020 +ClientHeight=1221 TBDockHeight=409 LRDockWidth=4949 Dockable=1 @@ -444,11 +504,11 @@ State=0 Left=0 Top=0 Width=3824 -Height=1020 +Height=1221 MaxLeft=-1 MaxTop=-1 ClientWidth=3824 -ClientHeight=1020 +ClientHeight=1221 TBDockHeight=216 LRDockWidth=7406 Dockable=1 @@ -467,11 +527,11 @@ State=0 Left=0 Top=0 Width=3824 -Height=1020 +Height=1221 MaxLeft=-1 MaxTop=-1 ClientWidth=3824 -ClientHeight=1020 +ClientHeight=1221 TBDockHeight=1537 LRDockWidth=3484 Dockable=1 @@ -486,16 +546,35 @@ State=0 Left=0 Top=0 Width=3824 -Height=1020 +Height=1221 MaxLeft=-1 MaxTop=-1 ClientWidth=3824 -ClientHeight=1020 +ClientHeight=1221 TBDockHeight=2062 LRDockWidth=3484 Dockable=1 StayOnTop=0 +[PatchForm] +PercentageSizes=1 +Create=1 +Visible=1 +Docked=1 +State=0 +Left=0 +Top=0 +Width=2340 +Height=1279 +MaxLeft=-1 +MaxTop=-1 +ClientWidth=2340 +ClientHeight=1279 +TBDockHeight=2500 +LRDockWidth=3398 +Dockable=1 +StayOnTop=0 + [FindReferencsForm] PercentageSizes=1 Create=1 @@ -524,11 +603,11 @@ State=0 Left=0 Top=0 Width=2340 -Height=2234 +Height=1279 MaxLeft=-1 MaxTop=-1 ClientWidth=2340 -ClientHeight=2234 +ClientHeight=1279 TBDockHeight=3211 LRDockWidth=2824 Dockable=1 @@ -543,11 +622,11 @@ State=0 Left=0 Top=0 Width=2340 -Height=2234 +Height=1279 MaxLeft=-1 MaxTop=-1 ClientWidth=2340 -ClientHeight=2234 +ClientHeight=1279 TBDockHeight=1157 LRDockWidth=3676 Dockable=1 @@ -589,12 +668,12 @@ State=0 Left=501 Top=1099 Width=2855 -Height=2500 +Height=3211 MaxLeft=-1 MaxTop=-1 ClientWidth=2855 -ClientHeight=2500 -TBDockHeight=2500 +ClientHeight=3211 +TBDockHeight=3211 LRDockWidth=2855 Dockable=1 StayOnTop=0 @@ -627,11 +706,11 @@ State=0 Left=0 Top=0 Width=2340 -Height=2234 +Height=1279 MaxLeft=-1 MaxTop=-1 ClientWidth=2340 -ClientHeight=2234 +ClientHeight=1279 TBDockHeight=4835 LRDockWidth=3562 Dockable=1 @@ -646,11 +725,11 @@ State=0 Left=0 Top=0 Width=2340 -Height=2234 +Height=1279 MaxLeft=-1 MaxTop=-1 ClientWidth=2340 -ClientHeight=2234 +ClientHeight=1279 TBDockHeight=4835 LRDockWidth=3562 Dockable=1 @@ -665,11 +744,11 @@ State=0 Left=0 Top=0 Width=3824 -Height=1020 +Height=1221 MaxLeft=-1 MaxTop=-1 ClientWidth=3824 -ClientHeight=1020 +ClientHeight=1221 TBDockHeight=1545 LRDockWidth=8742 Dockable=1 @@ -701,25 +780,85 @@ LRDockWidth=1895 Dockable=1 StayOnTop=0 +[MMXCodeExplorer] +PercentageSizes=1 +Create=1 +Visible=1 +Docked=1 +State=0 +Left=0 +Top=0 +Width=1996 +Height=6803 +MaxLeft=-1 +MaxTop=-1 +ClientWidth=1996 +ClientHeight=6803 +TBDockHeight=5747 +LRDockWidth=1691 +Dockable=1 +StayOnTop=0 +Layout=0 +Split=141 +ContentsClosed=0 + [fmGrepResults] PercentageSizes=1 Create=1 -Visible=0 +Visible=1 Docked=0 State=0 -Left=195 -Top=7083 -Width=3656 +Left=0 +Top=0 +Width=1609 Height=2701 MaxLeft=-4 MaxTop=-7 -ClientWidth=3594 +ClientWidth=1547 ClientHeight=2421 TBDockHeight=2701 LRDockWidth=1609 Dockable=1 StayOnTop=0 +[fmGxBookmarksForm] +PercentageSizes=1 +Create=1 +Visible=0 +Docked=0 +State=0 +Left=0 +Top=0 +Width=1250 +Height=1746 +MaxLeft=-4 +MaxTop=-7 +ClientWidth=1188 +ClientHeight=1466 +TBDockHeight=1746 +LRDockWidth=1250 +Dockable=1 +StayOnTop=0 + +[fmGxInstantGrepForm] +PercentageSizes=1 +Create=1 +Visible=0 +Docked=0 +State=0 +Left=0 +Top=0 +Width=1754 +Height=3190 +MaxLeft=-4 +MaxTop=-7 +ClientWidth=1691 +ClientHeight=2909 +TBDockHeight=3190 +LRDockWidth=1754 +Dockable=1 +StayOnTop=0 + [fmMacroLibrary] PercentageSizes=1 Create=1 @@ -739,27 +878,24 @@ LRDockWidth=1289 Dockable=1 StayOnTop=0 -[MMXCodeExplorer] +[ParnassusBookmarksForm] PercentageSizes=1 Create=1 -Visible=1 -Docked=1 +Visible=0 +Docked=0 State=0 Left=0 Top=0 -Width=1996 -Height=6803 -MaxLeft=-1 -MaxTop=-1 -ClientWidth=1996 -ClientHeight=6803 -TBDockHeight=5747 -LRDockWidth=1996 +Width=2227 +Height=2364 +MaxLeft=-4 +MaxTop=-7 +ClientWidth=2164 +ClientHeight=2083 +TBDockHeight=2364 +LRDockWidth=2227 Dockable=1 StayOnTop=0 -Layout=0 -Split=255 -ContentsClosed=0 [ModelViewTool] PercentageSizes=1 @@ -813,18 +949,18 @@ State=0 Left=8 Top=8 Width=2340 -Height=2435 +Height=1480 MaxLeft=-1 MaxTop=-1 ClientWidth=2340 -ClientHeight=2435 -TBDockHeight=2435 +ClientHeight=1480 +TBDockHeight=1480 LRDockWidth=2340 Dockable=1 StayOnTop=0 TabPosition=1 ActiveTabID=RefactoringForm -TabDockClients=RefactoringForm,FindReferencsForm,ToDo List,MetricsView,QAView +TabDockClients=RefactoringForm,PatchForm,FindReferencsForm,ToDo List,MetricsView,QAView [DockSite1] HostDockSite=DockBottomPanel @@ -837,12 +973,12 @@ State=0 Left=0 Top=28 Width=3824 -Height=1221 +Height=1422 MaxLeft=-1 MaxTop=-1 ClientWidth=3824 -ClientHeight=1221 -TBDockHeight=1221 +ClientHeight=1422 +TBDockHeight=1422 LRDockWidth=3824 Dockable=1 StayOnTop=0 @@ -861,11 +997,11 @@ State=0 Left=0 Top=28 Width=1996 -Height=4799 +Height=5682 MaxLeft=-1 MaxTop=-1 ClientWidth=1996 -ClientHeight=4799 +ClientHeight=5682 TBDockHeight=7004 LRDockWidth=1996 Dockable=1 @@ -907,13 +1043,13 @@ Visible=1 Docked=1 State=0 Left=0 -Top=732 +Top=855 Width=1996 -Height=2514 +Height=1487 MaxLeft=-1 MaxTop=-1 ClientWidth=1996 -ClientHeight=2514 +ClientHeight=1487 TBDockHeight=7004 LRDockWidth=1996 Dockable=1 diff --git a/source/json2pumlapps.groupproj b/source/json2pumlapps.groupproj index f1f5510..683c83b 100644 --- a/source/json2pumlapps.groupproj +++ b/source/json2pumlapps.groupproj @@ -15,6 +15,12 @@ + + + + + + Default.Personality.12 @@ -59,14 +65,32 @@ + + + + + + + + + + + + + + + + + + - + - + - + diff --git a/source/json2pumlbasedefinition.pas b/source/json2pumlbasedefinition.pas index d62e774..1923295 100644 --- a/source/json2pumlbasedefinition.pas +++ b/source/json2pumlbasedefinition.pas @@ -29,6 +29,9 @@ interface uses System.JSON, System.Classes, json2pumlconst, Quick.Logger; type + tJson2PumlPropertySearchMatchType = (psmExactExact, psmExact, psmMatchMatch, psmMatch, psmExcludeExclude, psmExclude, + psmNoMatch); + tJson2PumlCalculateOutputFilenameEvent = function(iFileName, iSourceFileName: string; iNewFileExtension: string = '') : string of object; tJson2PumlNotifyChangeEvent = procedure(Sender: TObject; ProgressValue, ProgressMaxValue: Integer) of object; @@ -166,14 +169,55 @@ tJson2PumlBaseList = class(tJson2PumlBaseObject) property Text: string read GetText write SetText; end; + tJson2PumlBasePropertyListEntry = class(TObject) + private + FFoundCondition: string; + FPropertyIndex: Integer; + protected + public + constructor Create; + property FoundCondition: string read FFoundCondition write FFoundCondition; + property PropertyIndex: Integer read FPropertyIndex write FPropertyIndex default - 1; + end; + + tJson2PumlBasePropertyListCache = class(TObject) + private + FCacheList: TStringList; + protected + property CacheList: TStringList read FCacheList; + function CacheName (const iPropertyName, iParentPropertyName, iParentObjectType: string): string; + public + constructor Create; + destructor Destroy; override; + procedure Clear; + function GetCache (const iPropertyName, iParentPropertyName, iParentObjectType: string; var oFoundCondition: string; + var oPropertyIndex: Integer): boolean; + procedure AddCache (const iPropertyName, iParentPropertyName, iParentObjectType, iFoundCondition: string; + iPropertyIndex: Integer); + end; + tJson2PumlBasePropertyList = class(tJson2PumlBaseList) + private + FConfigurationPropertyName: string; + FPropertyCache: tJson2PumlBasePropertyListCache; + FSearchEmpyAsDefault: boolean; + FUseMatch: boolean; + procedure SetSearchEmpyAsDefault (const Value: boolean); protected function GetIsValid: boolean; override; - function IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, iConfigurationPropertyName: string; - var oFoundCondition: string; iUseMatch: boolean = false; iSearchEmpyAsDefault: boolean = false): Integer; + procedure OnPropertyListChange (Sender: TObject); + property PropertyCache: tJson2PumlBasePropertyListCache read FPropertyCache; public constructor Create; override; - function BuildFoundCondition (iConfigurationPropertyName, iConfiguredValue, iInputValue: string): string; + destructor Destroy; override; + function BuildFoundCondition (iMatchType: tJson2PumlPropertySearchMatchType; + const iConfigurationPropertyName, iConfiguredValue, iSearchValue: string): string; + procedure Clear; override; + function IndexOfProperty (const iPropertyName, iParentPropertyName, iParentObjectType: string; + var oFoundCondition: string): Integer; + property ConfigurationPropertyName: string read FConfigurationPropertyName write FConfigurationPropertyName; + property SearchEmpyAsDefault: boolean read FSearchEmpyAsDefault write SetSearchEmpyAsDefault default false; + property UseMatch: boolean read FUseMatch write FUseMatch default false; end; tJson2PumlBaseObjectClass = class of tJson2PumlBaseObject; @@ -182,7 +226,8 @@ tJson2PumlBaseListClass = class of tJson2PumlBaseList; implementation uses - System.SysUtils, System.IOUtils, json2pumltools, jsontools, System.Masks, System.Generics.Collections; + System.SysUtils, System.IOUtils, json2pumltools, jsontools, System.Masks, + System.Generics.Collections; function tJson2PumlOutputFormatHelper.FileExtension (iLeadingSeparator: boolean = false): string; begin @@ -751,96 +796,190 @@ constructor tJson2PumlBasePropertyList.Create; begin inherited Create; OwnsObjects := true; + FUseMatch := true; + FSearchEmpyAsDefault := false; + FPropertyCache := tJson2PumlBasePropertyListCache.Create (); + ItemList.OnChange := OnPropertyListChange; end; -function tJson2PumlBasePropertyList.BuildFoundCondition (iConfigurationPropertyName, iConfiguredValue, - iInputValue: string): string; +destructor tJson2PumlBasePropertyList.Destroy; begin - if iInputValue.IsEmpty then - Result := Format ('- ["%s" : Configured "%s"]', [iConfigurationPropertyName, iConfiguredValue]) - else if iConfiguredValue.IsEmpty then - Result := Format ('- ["%s" : Not found "%s"]', [iConfigurationPropertyName, iInputValue]) - else - Result := Format ('- ["%s" : Configured "%s" : Input "%s"]', [iConfigurationPropertyName, iConfiguredValue, - iInputValue]); + FPropertyCache.Free; + inherited Destroy; +end; + +function tJson2PumlBasePropertyList.BuildFoundCondition (iMatchType: tJson2PumlPropertySearchMatchType; + const iConfigurationPropertyName, iConfiguredValue, iSearchValue: string): string; +begin + case iMatchType of + psmExactExact, psmExact: + Result := Format ('- ["%s" : Exact Match : Configured "%s" : Search "%s"]', + [iConfigurationPropertyName, iConfiguredValue, iSearchValue]); + psmMatchMatch, psmMatch: + Result := Format ('- ["%s" : Wildcard match : Configured "%s" : Search "%s"]', + [iConfigurationPropertyName, iConfiguredValue, iSearchValue]); + psmExcludeExclude, psmExclude: + Result := Format ('- ["%s" : Excluded : Configured "%s" : Search "%s"]', + [iConfigurationPropertyName, iConfiguredValue, iSearchValue]); + psmNoMatch: + Result := Format ('- ["%s" : Not found "%s"]', [iConfigurationPropertyName, iSearchValue]) + end; +end; + +procedure tJson2PumlBasePropertyList.Clear; +begin + inherited Clear; + PropertyCache.Clear; end; -function tJson2PumlBasePropertyList.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, - iConfigurationPropertyName: string; var oFoundCondition: string; iUseMatch: boolean = false; - iSearchEmpyAsDefault: boolean = false): Integer; +function tJson2PumlBasePropertyList.IndexOfProperty (const iPropertyName, iParentPropertyName, + iParentObjectType: string; var oFoundCondition: string): Integer; var PropertyIndex: Integer; + ExcludeType: tJson2PumlPropertySearchMatchType; + ExcludeIndex: Integer; + ParentPropertyName, ParentName: string; + CurrentMatchType, OverallMatchType: tJson2PumlPropertySearchMatchType; + ParentFilled: boolean; + i: Integer; - function found: boolean; + function ListValue (iIndex: Integer): string; begin - Result := PropertyIndex >= 0; + Result := Names[iIndex]; + if Result.IsEmpty then + Result := ItemList[iIndex]; end; - procedure DirectSearch (iValue: string); + function CalculateMatchType (iIndex: Integer): tJson2PumlPropertySearchMatchType; + var + IndexName: string; + IndexPropertyName: string; + IndexParentName: string; + Splitted: TArray; begin - if not found then - PropertyIndex := IndexOfName (iValue); - if not found then - PropertyIndex := IndexOf (iValue); - if found then - oFoundCondition := iValue; + Result := psmNoMatch; + IndexName := ListValue (iIndex); + if ParentFilled and (IndexName = ParentPropertyName) then + Result := psmExactExact + else if IndexName = iPropertyName then + Result := psmExact + else if UseMatch then + if MatchesMask (iPropertyName, IndexName) then + Result := psmMatch + else if MatchesMask ('-' + iPropertyName, IndexName) then + Result := psmExclude + else if ParentFilled then + begin + Splitted := IndexName.Split (['.'], 2, TStringSplitOptions.None); + if Length (Splitted) > 1 then + begin + IndexPropertyName := Splitted[1]; + IndexParentName := Splitted[0]; + if MatchesMask (ParentName, IndexParentName) and MatchesMask (iPropertyName, IndexPropertyName) then + Result := psmMatchMatch + else if MatchesMask ('-' + ParentName, IndexParentName) and MatchesMask (iPropertyName, IndexPropertyName) + then + Result := psmExcludeExclude + end; + end; end; - procedure MatchSearch (iValue: string); - var - i: Integer; - S: string; + + function found: boolean; begin - if found then - exit; - for i := 0 to Count - 1 do - begin - S := Names[i]; - if S.IsEmpty then - S := ItemList[i]; - if MatchesMask (iValue, S) then - PropertyIndex := i; - if found then - break; - end; - if found then - oFoundCondition := iValue; + Result := (PropertyIndex > - 1) and (ExcludeIndex < 0) end; begin + ExcludeType := psmNoMatch; + ExcludeIndex := - 1; + Result := - 1; PropertyIndex := - 1; if iPropertyName.IsEmpty then exit; - DirectSearch (iPropertyName); - if not found and not iParentPropertyName.IsEmpty then - DirectSearch (iParentPropertyName + '.' + iPropertyName); - if not found and not iParentObjectType.IsEmpty then - DirectSearch (iParentObjectType + '.' + iPropertyName); - if not found and iUseMatch then + + if PropertyCache.GetCache (iPropertyName, iParentPropertyName, iParentObjectType, oFoundCondition, PropertyIndex) then begin - MatchSearch (iPropertyName); - if not found and not iParentPropertyName.IsEmpty then - MatchSearch (iParentPropertyName + '.' + iPropertyName); - if not found and not iParentObjectType.IsEmpty then - MatchSearch (iParentObjectType + '.' + iPropertyName); + Result := PropertyIndex; + exit; + end; + + try + if not iParentPropertyName.IsEmpty then + ParentName := iParentPropertyName + else if not iParentObjectType.IsEmpty then + ParentName := iParentObjectType + else + ParentName := ''; + ParentFilled := not ParentName.IsEmpty; + ParentPropertyName := ParentName + '.' + iPropertyName; + OverallMatchType := psmNoMatch; + for i := 0 to Count - 1 do + begin + CurrentMatchType := CalculateMatchType (i); + case CurrentMatchType of + psmExactExact, psmExact, psmMatchMatch, psmMatch: + begin + if CurrentMatchType < OverallMatchType then + begin + OverallMatchType := CurrentMatchType; + PropertyIndex := i; + oFoundCondition := ListValue (i); + end; + end; + psmExcludeExclude, psmExclude: + begin + ExcludeType := CurrentMatchType; + ExcludeIndex := i; + end; + psmNoMatch: + ; + end; + if OverallMatchType in [psmExactExact] then + break; + end; + + if (OverallMatchType in [psmMatchMatch, psmMatch]) and (ExcludeType <> psmNoMatch) then + begin + OverallMatchType := ExcludeType; + PropertyIndex := - 1; + end; + + if not found and SearchEmpyAsDefault then + begin + oFoundCondition := ''; + PropertyIndex := IndexOf (''); + if found then + oFoundCondition := BuildFoundCondition (psmExact, ConfigurationPropertyName, oFoundCondition, '') + else + oFoundCondition := BuildFoundCondition (OverallMatchType, ConfigurationPropertyName, '', ParentPropertyName); + end + else + case OverallMatchType of + psmExactExact, psmMatchMatch: + oFoundCondition := BuildFoundCondition (OverallMatchType, ConfigurationPropertyName, ListValue(PropertyIndex), + ParentPropertyName); + psmExact, psmMatch: + oFoundCondition := BuildFoundCondition (OverallMatchType, ConfigurationPropertyName, ListValue(PropertyIndex), + iPropertyName); + psmExcludeExclude: + oFoundCondition := BuildFoundCondition (OverallMatchType, ConfigurationPropertyName, ListValue(ExcludeIndex), + ParentName); + psmExclude: + oFoundCondition := BuildFoundCondition (OverallMatchType, ConfigurationPropertyName, ListValue(ExcludeIndex), + iPropertyName); + psmNoMatch: + if ParentFilled then + oFoundCondition := BuildFoundCondition (OverallMatchType, ConfigurationPropertyName, '', iPropertyName) + else + oFoundCondition := BuildFoundCondition (OverallMatchType, ConfigurationPropertyName, '', + ParentPropertyName); + end; + Result := PropertyIndex; + finally + PropertyCache.AddCache(iPropertyName, iParentPropertyName, iParentObjectType, oFoundCondition, Result); end; - if not found and iSearchEmpyAsDefault then - begin - oFoundCondition := ''; - PropertyIndex := IndexOf (''); - if found then - oFoundCondition := BuildFoundCondition (iConfigurationPropertyName, oFoundCondition, ''); - end - else if found then - oFoundCondition := BuildFoundCondition (iConfigurationPropertyName, self[PropertyIndex], oFoundCondition) - else if not iParentObjectType.IsEmpty then - oFoundCondition := BuildFoundCondition (iConfigurationPropertyName, '', iParentObjectType + '.' + iPropertyName) - else if not iParentPropertyName.IsEmpty then - oFoundCondition := BuildFoundCondition (iConfigurationPropertyName, '', iParentPropertyName + '.' + iPropertyName) - else - oFoundCondition := BuildFoundCondition (iConfigurationPropertyName, '', iPropertyName); - Result := PropertyIndex; end; function tJson2PumlBasePropertyList.GetIsValid: boolean; @@ -858,6 +997,16 @@ function tJson2PumlBasePropertyList.GetIsValid: boolean; end; end; +procedure tJson2PumlBasePropertyList.OnPropertyListChange (Sender: TObject); +begin + PropertyCache.Clear; +end; + +procedure tJson2PumlBasePropertyList.SetSearchEmpyAsDefault (const Value: boolean); +begin + FSearchEmpyAsDefault := Value; +end; + procedure tJson2PumlFileNameReplaceHelper.FromString (aValue: string); var dbot: tJson2PumlFileNameReplace; @@ -928,4 +1077,63 @@ procedure tJson2PumlErrorTypeHelper.RenderErrorResponse (oJson: TStringList; iLe WriteObjectEndToJson (oJson, iLevel); end; +constructor tJson2PumlBasePropertyListCache.Create; +begin + inherited Create; + FCacheList := TStringList.Create; + FCacheList.OwnsObjects := true; + FCacheList.Sorted := true; + FCacheList.Duplicates := dupError; +end; + +destructor tJson2PumlBasePropertyListCache.Destroy; +begin + FCacheList.Free; + inherited Destroy; +end; + +procedure tJson2PumlBasePropertyListCache.AddCache (const iPropertyName, iParentPropertyName, iParentObjectType, + iFoundCondition: string; iPropertyIndex: Integer); +var + Entry: tJson2PumlBasePropertyListEntry; +begin + Entry := tJson2PumlBasePropertyListEntry.Create; + Entry.FoundCondition := iFoundCondition; + Entry.PropertyIndex := iPropertyIndex; + CacheList.AddObject (CacheName(iPropertyName, iParentPropertyName, iParentObjectType), Entry); +end; + +function tJson2PumlBasePropertyListCache.CacheName (const iPropertyName, iParentPropertyName, + iParentObjectType: string): string; +begin + Result := string.Join ('#', [iPropertyName, iParentPropertyName, iParentObjectType]); +end; + +procedure tJson2PumlBasePropertyListCache.Clear; +begin + CacheList.Clear; +end; + +function tJson2PumlBasePropertyListCache.GetCache (const iPropertyName, iParentPropertyName, iParentObjectType: string; + var oFoundCondition: string; var oPropertyIndex: Integer): boolean; +var + Index: Integer; + Entry: tJson2PumlBasePropertyListEntry; +begin + index := CacheList.IndexOf (CacheName(iPropertyName, iParentPropertyName, iParentObjectType)); + Result := index >= 0; + if Result then + begin + Entry := tJson2PumlBasePropertyListEntry (CacheList.Objects[index]); + oFoundCondition := Entry.FoundCondition; + oPropertyIndex := Entry.PropertyIndex; + end; +end; + +constructor tJson2PumlBasePropertyListEntry.Create; +begin + inherited Create; + FPropertyIndex := - 1; +end; + end. diff --git a/source/json2pumlconverter.pas b/source/json2pumlconverter.pas index 4dc652b..54f1dcd 100644 --- a/source/json2pumlconverter.pas +++ b/source/json2pumlconverter.pas @@ -795,7 +795,7 @@ function TJson2PumlConverter.GetPropertyValueListProperties (iDefinitionList: tJ end; end; finally - oFoundCondition := iDefinitionList.BuildFoundCondition (iConfigurationPropertyName, + oFoundCondition := iDefinitionList.BuildFoundCondition (psmExact, iConfigurationPropertyName, PropertyName.TrimRight(['.']), Result); oPropertyName := PropertyName.TrimRight (['.']); end; diff --git a/source/json2pumlconverterdefinition.pas b/source/json2pumlconverterdefinition.pas index 4d4d3d9..96f704f 100644 --- a/source/json2pumlconverterdefinition.pas +++ b/source/json2pumlconverterdefinition.pas @@ -81,8 +81,8 @@ tJson2PumlPropertyValueDefinitionList = class(tJson2PumlOperationPropertyList) constructor Create; override; procedure AddDefinition (iPropertyName, iChildPropertyName, iNextValueSeparator: string); procedure Assign (Source: tPersistent); override; - function GetDefinitionByName (iPropertyName, iParentPropertyName, iParentObjectType, iConfigurationPropertyName - : string; var oFoundCondition: string; iUseMatch: boolean = false; iSearchEmpyAsDefault: boolean = false) + function GetDefinitionByName (iPropertyName, iParentPropertyName, iParentObjectType: string; + var oFoundCondition: string; iUseMatch: boolean = false; iSearchEmpyAsDefault: boolean = false) : tJson2PumlPropertyValueDefinition; function GetEnumerator: tJson2PumlPropertyValueDefinitionEnumerator; property Definition[index: Integer]: tJson2PumlPropertyValueDefinition read GetDefinition; default; @@ -141,7 +141,7 @@ tJson2PumlSingleFormatDefinition = class(tJson2PumlBaseObject) FValueSplitLengthStr: string; FFormatName: string; FIconColor: string; - FObjectFilter: tStringList; + FObjectFilter: tJson2PumlBasePropertyList; FShowAttributesStr: string; FSortAttributesStr: string; FShowCharacteristicsStr: string; @@ -206,7 +206,7 @@ tJson2PumlSingleFormatDefinition = class(tJson2PumlBaseObject) property ValueSplitLength: Integer read GetValueSplitLength; property FormatName: string read FFormatName write FFormatName; property IconColor: string read FIconColor write FIconColor; - property ObjectFilter: tStringList read FObjectFilter write FObjectFilter; + property ObjectFilter: tJson2PumlBasePropertyList read FObjectFilter write FObjectFilter; property ShowAttributes: boolean read GetShowAttributes; property SortAttributes: boolean read GetSortAttributes; property ShowCharacteristics: boolean read GetShowCharacteristics; @@ -276,7 +276,7 @@ tJson2PumlCharacteristicDefinition = class(tJson2PumlBaseObject) private FCharacteristicType: tJson2PumlCharacteristicType; FIncludeIndexStr: string; - FPropertyList: tStringList; + FPropertyList: tJson2PumlBasePropertyList; FParentProperty: string; function GetIncludeIndex: boolean; procedure SetIncludeIndexStr (const Value: string); @@ -296,7 +296,7 @@ tJson2PumlCharacteristicDefinition = class(tJson2PumlBaseObject) default jctList; property IncludeIndex: boolean read GetIncludeIndex; property IncludeIndexStr: string read FIncludeIndexStr write SetIncludeIndexStr; - property PropertyList: tStringList read FPropertyList; + property PropertyList: tJson2PumlBasePropertyList read FPropertyList; property ParentProperty: string read FParentProperty write FParentProperty; end; @@ -554,20 +554,39 @@ constructor tJson2PumlConverterDefinition.Create; begin inherited Create; FAttributeProperties := tJson2PumlOperationPropertyList.Create; + FAttributeProperties.UseMatch := True; + FAttributeProperties.ConfigurationPropertyName := 'attributeProperties'; FCharacteristicProperties := tJson2PumlCharacteristicDefinitionList.Create; + FCharacteristicProperties.UseMatch := True; + FCharacteristicProperties.ConfigurationPropertyName := 'characteristicProperties'; FGroupProperties := tJson2PumlOperationPropertyList.Create (); + FGroupProperties.UseMatch := True; + FGroupProperties.ConfigurationPropertyName := 'groupProperties'; FHiddenProperties := tJson2PumlOperationPropertyList.Create; + FHiddenProperties.UseMatch := True; + FHiddenProperties.ConfigurationPropertyName := 'hiddenProperties'; FObjectDetailProperties := tJson2PumlOperationPropertyList.Create; + FObjectDetailProperties.UseMatch := True; + FObjectDetailProperties.ConfigurationPropertyName := 'objectDetailProperties'; FObjectFormats := tJson2PumlFormatDefinition.Create; FObjectIdentifierProperties := tJson2PumlPropertyValueDefinitionList.Create; + FObjectDetailProperties.ConfigurationPropertyName := 'objectIdentifierProperties'; FObjectProperties := tJson2PumlObjectDefinitionList.Create; + FObjectProperties.UseMatch := True; + FObjectProperties.ConfigurationPropertyName := 'objectProperties'; FObjectTitleProperties := tJson2PumlPropertyValueDefinitionList.Create (); FObjectTypeProperties := tJson2PumlPropertyValueDefinitionList.Create; FObjectTypeRenames := tJson2PumlOperationPropertyList.Create; + FObjectTypeRenames.UseMatch := True; + FObjectTypeRenames.ConfigurationPropertyName := 'objectTypeRenames'; FPUMLHeaderLines := tJson2PumlOperationPropertyList.Create (); FRelationshipProperties := tJson2PumlOperationPropertyList.Create; + FRelationshipProperties.UseMatch := True; + FRelationshipProperties.ConfigurationPropertyName := 'relationshipProperties'; FRelationshipTypeArrowFormats := tJson2PumlRelationshipTypeArrowFormatList.Create; FRelationshipTypeProperties := tJson2PumlPropertyValueDefinitionList.Create; + FRelationshipTypeProperties.ConfigurationPropertyName := 'relationshipTypeProperties'; + end; destructor tJson2PumlConverterDefinition.Destroy; @@ -659,7 +678,7 @@ function tJson2PumlConverterDefinition.GetGroupDetailObjectsTogether: boolean; function tJson2PumlConverterDefinition.GetHideDuplicateRelations: boolean; begin - Result := StringToBoolean (HideDuplicateRelationsStr, true); + Result := StringToBoolean (HideDuplicateRelationsStr, True); end; function tJson2PumlConverterDefinition.GetIdent: string; @@ -669,22 +688,22 @@ function tJson2PumlConverterDefinition.GetIdent: string; function tJson2PumlConverterDefinition.GetIdentifyObjectsByTypeAndIdent: boolean; begin - Result := StringToBoolean (IdentifyObjectsByTypeAndIdentStr, true); + Result := StringToBoolean (IdentifyObjectsByTypeAndIdentStr, True); end; function tJson2PumlConverterDefinition.GetLegendShowFileInfos: boolean; begin - Result := StringToBoolean (LegendShowFileInfosStr, true); + Result := StringToBoolean (LegendShowFileInfosStr, True); end; function tJson2PumlConverterDefinition.GetLegendShowInfo: boolean; begin - Result := StringToBoolean (LegendShowInfoStr, true); + Result := StringToBoolean (LegendShowInfoStr, True); end; function tJson2PumlConverterDefinition.GetLegendShowObjectFormats: boolean; begin - Result := StringToBoolean (LegendShowObjectFormatsStr, true); + Result := StringToBoolean (LegendShowObjectFormatsStr, True); end; function tJson2PumlConverterDefinition.GetShowLegend: boolean; @@ -696,7 +715,7 @@ function tJson2PumlConverterDefinition.IsCharacteristicProperty (iPropertyName, iParentObjectType: string; var oFoundCondition: string): boolean; begin Result := CharacteristicProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, - 'characteristicProperties', oFoundCondition, true) >= 0; + oFoundCondition) >= 0; end; function tJson2PumlConverterDefinition.GetIsFilled: boolean; @@ -715,8 +734,7 @@ function tJson2PumlConverterDefinition.IsGroupProperty (iPropertyName, iParentPr var Index: Integer; begin - index := GroupProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, 'groupProperties', - oFoundCondition, true); + index := GroupProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, oFoundCondition); Result := index >= 0; if Result then begin @@ -738,7 +756,7 @@ function tJson2PumlConverterDefinition.IsObjectDetailProperty (iPropertyName, iP iParentObjectType: string; var oFoundCondition: string): boolean; begin Result := ObjectDetailProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, - 'objectDetailProperties', oFoundCondition, true) >= 0; + oFoundCondition) >= 0; end; function tJson2PumlConverterDefinition.IsObjectIdentifierProperty (iPropertyName, iParentPropertyName, @@ -748,7 +766,7 @@ function tJson2PumlConverterDefinition.IsObjectIdentifierProperty (iPropertyName Result := iPropertyName = 'id' else Result := ObjectIdentifierProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, - 'objectIdentifierProperties', oFoundCondition) >= 0; + oFoundCondition) >= 0; end; function tJson2PumlConverterDefinition.IsObjectProperty (iPropertyName: string; @@ -756,9 +774,9 @@ function tJson2PumlConverterDefinition.IsObjectProperty (iPropertyName: string; begin if ObjectProperties.Count > 0 then Result := ObjectProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, - 'objectProperties', oFoundCondition, true) >= 0 + oFoundCondition) >= 0 else - Result := true; + Result := True; end; function tJson2PumlConverterDefinition.IsPropertyAllowed (iPropertyName: string; @@ -766,30 +784,30 @@ function tJson2PumlConverterDefinition.IsPropertyAllowed (iPropertyName: string; begin if AttributeProperties.Count > 0 then Result := AttributeProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, - 'attributeProperties', oFoundCondition, true) >= 0 + oFoundCondition) >= 0 else - Result := true; + Result := True; end; function tJson2PumlConverterDefinition.IsPropertyHidden (iPropertyName: string; iParentPropertyName, iParentObjectType: string; var oFoundCondition: string): boolean; begin - Result := HiddenProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, 'hiddenProperties', - oFoundCondition, true) >= 0; + Result := HiddenProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, + oFoundCondition) >= 0; end; function tJson2PumlConverterDefinition.isRelationshipProperty (iPropertyName: string; iParentPropertyName, iParentObjectType: string; var oFoundCondition: string): boolean; begin Result := RelationshipProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, - 'relationshipProperties', oFoundCondition, true) >= 0; + oFoundCondition) >= 0; end; function tJson2PumlConverterDefinition.IsRelationshipTypeProperty (iPropertyName: string; iParentPropertyName, iParentObjectType: string; var oFoundCondition: string): boolean; begin Result := RelationshipTypeProperties.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, - 'relationshipTypeProperties', oFoundCondition) >= 0; + oFoundCondition) >= 0; end; procedure tJson2PumlConverterDefinition.MergeWith (iMergeDefinition: tJson2PumlBaseObject); @@ -838,7 +856,7 @@ function tJson2PumlConverterDefinition.ReadFromJson (iJsonValue: TJSONValue; iPr DefinitionRecord := GetJsonObject (iJsonValue, iPropertyName); if not Assigned (DefinitionRecord) then exit; - Result := true; + Result := True; if ExistsJsonProperty (DefinitionRecord, 'definition') and ExistsJsonProperty (DefinitionRecord, 'option') then begin OptionName := GetJsonStringValue (DefinitionRecord, 'option'); @@ -876,8 +894,7 @@ function tJson2PumlConverterDefinition.RenameObjectType (iPropertyName, iParentP var Index: Integer; begin - index := ObjectTypeRenames.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, - 'objectTypeRenames', oFoundCondition, true); + index := ObjectTypeRenames.IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, oFoundCondition); Result := ObjectTypeRenames.ValueFromIndex[index]; if Result.IsEmpty then Result := iPropertyName; @@ -1021,7 +1038,7 @@ procedure tJson2PumlConverterDefinition.WriteToJson (oJsonOutPut: TStrings; iPro begin PropertyName := iPropertyName; Level := iLevel; - WriteEmpty := true; + WriteEmpty := True; end; WriteObjectStartToJson (oJsonOutPut, Level, PropertyName); @@ -1114,7 +1131,7 @@ function tJson2PumlOperationPropertyList.ReadFromJson (iJsonValue: TJSONValue; i exit; if not Assigned (JsonValue) then exit; - Result := true; + Result := True; if JsonValue is TJSONArray then inherited ReadFromJson (JsonValue, iPropertyName) else if JsonValue is TJSONObject then @@ -1144,7 +1161,8 @@ procedure tJson2PumlOperationPropertyList.WriteToJson (oJsonOutPut: TStrings; iP constructor tJson2PumlPropertyValueDefinitionList.Create; begin inherited; - OwnsObjects := true; + OwnsObjects := True; + UseMatch := True; end; procedure tJson2PumlPropertyValueDefinitionList.AddDefinition (iPropertyName, iChildPropertyName, @@ -1177,13 +1195,12 @@ function tJson2PumlPropertyValueDefinitionList.GetDefinition (Index: Integer): t end; function tJson2PumlPropertyValueDefinitionList.GetDefinitionByName (iPropertyName, iParentPropertyName, - iParentObjectType, iConfigurationPropertyName: string; var oFoundCondition: string; iUseMatch: boolean = false; + iParentObjectType: string; var oFoundCondition: string; iUseMatch: boolean = false; iSearchEmpyAsDefault: boolean = false): tJson2PumlPropertyValueDefinition; var i: Integer; begin - i := IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, iConfigurationPropertyName, - oFoundCondition, true, false); + i := IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, oFoundCondition); if i >= 0 then Result := Definition[i] else @@ -1243,7 +1260,9 @@ function tJson2PumlPropertyValueDefinitionEnumerator.MoveNext: boolean; constructor tJson2PumlObjectDefinitionList.Create; begin inherited; - OwnsObjects := true; + OwnsObjects := True; + UseMatch := True; + ConfigurationPropertyName := 'objectProperties'; end; procedure tJson2PumlObjectDefinitionList.AddDefinition (iObjectName: string; iGenerateWithoutIdentifier: boolean); @@ -1278,8 +1297,7 @@ function tJson2PumlObjectDefinitionList.GetDefinitionByName (iPropertyName, iPar var i: Integer; begin - i := IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, 'objectProperties', oFoundCondition, - true, false); + i := IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, oFoundCondition); if i >= 0 then Result := Definition[i] else @@ -1334,9 +1352,11 @@ constructor tJson2PumlSingleFormatDefinition.Create; begin inherited Create; FSkinParams := tStringList.Create (); - FSkinParams.OwnsObjects := true; - FObjectFilter := tStringList.Create; - FObjectFilter.OwnsObjects := true; + FSkinParams.OwnsObjects := True; + FObjectFilter := tJson2PumlBasePropertyList.Create; + FObjectFilter.OwnsObjects := True; + FObjectFilter.UseMatch := True; + FObjectFilter.ConfigurationPropertyName := 'formats.definition.objectFilter'; end; destructor tJson2PumlSingleFormatDefinition.Destroy; @@ -1393,17 +1413,17 @@ procedure tJson2PumlSingleFormatDefinition.Clear; function tJson2PumlSingleFormatDefinition.GetCaptionShowIdent: boolean; begin - Result := StringToBoolean (CaptionShowIdentStr, true); + Result := StringToBoolean (CaptionShowIdentStr, True); end; function tJson2PumlSingleFormatDefinition.GetCaptionShowTitle: boolean; begin - Result := StringToBoolean (CaptionShowTitleStr, true); + Result := StringToBoolean (CaptionShowTitleStr, True); end; function tJson2PumlSingleFormatDefinition.GetCaptionShowType: boolean; begin - Result := StringToBoolean (CaptionShowTypeStr, true); + Result := StringToBoolean (CaptionShowTypeStr, True); end; function tJson2PumlSingleFormatDefinition.GetCaptionSplitLength: Integer; @@ -1429,17 +1449,17 @@ function tJson2PumlSingleFormatDefinition.GetIdent: string; function tJson2PumlSingleFormatDefinition.GetShowAttributes: boolean; begin - Result := StringToBoolean (ShowAttributesStr, true); + Result := StringToBoolean (ShowAttributesStr, True); end; function tJson2PumlSingleFormatDefinition.GetShowCharacteristics: boolean; begin - Result := StringToBoolean (ShowCharacteristicsStr, true); + Result := StringToBoolean (ShowCharacteristicsStr, True); end; function tJson2PumlSingleFormatDefinition.GetShowFromRelations: boolean; begin - Result := StringToBoolean (ShowFromRelationsStr, true); + Result := StringToBoolean (ShowFromRelationsStr, True); end; function tJson2PumlSingleFormatDefinition.GetShowIfEmpty: boolean; @@ -1449,14 +1469,14 @@ function tJson2PumlSingleFormatDefinition.GetShowIfEmpty: boolean; function tJson2PumlSingleFormatDefinition.GetShowToRelations: boolean; begin - Result := StringToBoolean (ShowToRelationsStr, true); + Result := StringToBoolean (ShowToRelationsStr, True); end; function tJson2PumlSingleFormatDefinition.GetIsFilled: boolean; begin Result := not CaptionShowIdentStr.IsEmpty or not CaptionShowTitleStr.IsEmpty or not CaptionShowTypeStr.IsEmpty or not CaptionSplitCharacter.IsEmpty or not CaptionSplitLengthStr.IsEmpty or not IconColor.IsEmpty or - not (ObjectFilter.Count > 0) or not ShowAttributesStr.IsEmpty or not ShowCharacteristicsStr.IsEmpty or + (ObjectFilter.Count > 0) or not ShowAttributesStr.IsEmpty or not ShowCharacteristicsStr.IsEmpty or not ShowIfEmptyStr.IsEmpty or not ShowFromRelationsStr.IsEmpty or not ShowNullValuesStr.IsEmpty or not ShowToRelationsStr.IsEmpty or not SortAttributesStr.IsEmpty or (SkinParams.Count > 0) or not ValueSplitLengthStr.IsEmpty; @@ -1469,7 +1489,7 @@ function tJson2PumlSingleFormatDefinition.GetShowNullValues: boolean; function tJson2PumlSingleFormatDefinition.GetSortAttributes: boolean; begin - Result := StringToBoolean (SortAttributesStr, true); + Result := StringToBoolean (SortAttributesStr, True); end; procedure tJson2PumlSingleFormatDefinition.MergeWith (iMergeDefinition: tJson2PumlBaseObject); @@ -1509,7 +1529,7 @@ function tJson2PumlSingleFormatDefinition.ReadFromJson (iJsonValue: TJSONValue; DefinitionRecord := GetJsonObject (iJsonValue, iPropertyName); if not Assigned (DefinitionRecord) then exit; - Result := true; + Result := True; if ExistsJsonProperty (DefinitionRecord, 'definition') and ExistsJsonProperty (DefinitionRecord, 'formatName') then begin FormatName := GetJsonStringValue (DefinitionRecord, 'formatName'); @@ -1610,9 +1630,9 @@ procedure tJson2PumlSingleFormatDefinition.WriteToJson (oJsonOutPut: TStrings; i end; WriteObjectStartToJson (oJsonOutPut, Level, PropertyName); - WriteToJsonValue (oJsonOutPut, 'objectFilter', ObjectFilter, Level + 1, true, iWriteEmpty); + WriteToJsonValue (oJsonOutPut, 'objectFilter', ObjectFilter.ItemList, Level + 1, True, iWriteEmpty); WriteToJsonValue (oJsonOutPut, 'iconColor', IconColor, Level + 1, iWriteEmpty); - WriteToJsonValue (oJsonOutPut, 'skinParams', SkinParams, Level + 1, true, iWriteEmpty); + WriteToJsonValue (oJsonOutPut, 'skinParams', SkinParams, Level + 1, True, iWriteEmpty); WriteToJsonValue (oJsonOutPut, 'captionShowIdent', CaptionShowIdentStr, Level + 1, iWriteEmpty, false); WriteToJsonValue (oJsonOutPut, 'captionShowTitle', CaptionShowTitleStr, Level + 1, iWriteEmpty, false); WriteToJsonValue (oJsonOutPut, 'captionShowType', CaptionShowTypeStr, Level + 1, iWriteEmpty, false); @@ -1659,7 +1679,7 @@ function tJson2PumlFormatDefinitionEnumerator.MoveNext: boolean; constructor tJson2PumlFormatDefinitionList.Create; begin inherited; - OwnsObjects := true; + OwnsObjects := True; end; procedure tJson2PumlFormatDefinitionList.AddDefinition (iDefinition: tJson2PumlSingleFormatDefinition); @@ -1720,7 +1740,6 @@ function tJson2PumlFormatDefinitionList.GetDefinition (Index: Integer): tJson2Pu function tJson2PumlFormatDefinitionList.GetDefinitionByName (iPropertyName, iParentPropertyName: string; var oPriority: Integer; var oFoundCondition: string): tJson2PumlSingleFormatDefinition; var - S: string; Search: string; FormatDefinition: tJson2PumlSingleFormatDefinition; i: Integer; @@ -1748,22 +1767,25 @@ function tJson2PumlFormatDefinitionList.GetDefinitionByName (iPropertyName, iPar begin if MatchesMask (Search, FormatDefinition.FormatName) then begin - oFoundCondition := BuildFoundCondition ('formats.formatName', Search, FormatDefinition.FormatName); + oFoundCondition := BuildFoundCondition (psmMatch, 'formats.formatName', Search, + FormatDefinition.FormatName); Result := FormatDefinition; exit; end; end else - for S in FormatDefinition.ObjectFilter do + begin + if i = 1 then + l3 := FormatDefinition.ObjectFilter.IndexOfProperty (iPropertyName, '', '', oFoundCondition) + else + l3 := FormatDefinition.ObjectFilter.IndexOfProperty (iPropertyName, iParentPropertyName, '', + oFoundCondition); + if l3 >= 0 then begin - Inc (l3); - if MatchesMask (Search, S) then - begin - oFoundCondition := BuildFoundCondition ('formats.definition.objectFilter', Search, S); - Result := FormatDefinition; - exit; - end; + Result := FormatDefinition; + exit; end; + end; end; end; finally @@ -1905,7 +1927,9 @@ function tJson2PumlCharacteristicDefinitionEnumerator.MoveNext: boolean; constructor tJson2PumlCharacteristicDefinitionList.Create; begin inherited; - OwnsObjects := true; + OwnsObjects := True; + UseMatch := True; + ConfigurationPropertyName := 'characteristicProperties'; end; procedure tJson2PumlCharacteristicDefinitionList.AddDefinition (iParentProperty: string; @@ -1926,7 +1950,7 @@ procedure tJson2PumlCharacteristicDefinitionList.AddDefinition (iParentProperty: else intDefinition := Definition[i]; if Assigned (iPropertyList) then - intDefinition.PropertyList.Assign (iPropertyList); + intDefinition.PropertyList.ItemList.Assign (iPropertyList); intDefinition.IncludeIndexStr := iIncludeIndex; intDefinition.CharacteristicType := iCharacteristicType; end; @@ -1939,8 +1963,8 @@ procedure tJson2PumlCharacteristicDefinitionList.Assign (Source: tPersistent); begin Clear; for intDefinition in tJson2PumlCharacteristicDefinitionList (Source) do - AddDefinition (intDefinition.ParentProperty, intDefinition.CharacteristicType, intDefinition.PropertyList, - intDefinition.IncludeIndexStr); + AddDefinition (intDefinition.ParentProperty, intDefinition.CharacteristicType, + intDefinition.PropertyList.ItemList, intDefinition.IncludeIndexStr); end; end; @@ -1954,8 +1978,8 @@ function tJson2PumlCharacteristicDefinitionList.GetDefinitionByName (iPropertyNa var i: Integer; begin - i := IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, 'characteristicProperties', - oFoundCondition, true); + i := IndexOfProperty (iPropertyName, iParentPropertyName, iParentObjectType, + oFoundCondition); if i >= 0 then Result := Definition[i] else @@ -2014,7 +2038,9 @@ constructor tJson2PumlCharacteristicDefinition.Create; begin inherited Create; FCharacteristicType := jctList; - FPropertyList := tStringList.Create (); + FPropertyList := tJson2PumlBasePropertyList.Create (); + FPropertyList.UseMatch := True; + FPropertyList.ConfigurationPropertyName := 'characteristicProperties.propertyList'; end; destructor tJson2PumlCharacteristicDefinition.Destroy; @@ -2050,56 +2076,18 @@ function tJson2PumlCharacteristicDefinition.GetIsValid: boolean; function tJson2PumlCharacteristicDefinition.IsPropertyAllowed (iPropertyName, iParentPropertyName: string; var oFoundCondition: string): boolean; -var - S: string; - PropNameCombi: string; - OnlyNegative: boolean; - Negative: boolean; - l: Integer; begin if PropertyList.Count <= 0 then begin oFoundCondition := 'propertyList empty'; - Result := true + Result := True end else begin - Result := false; - PropNameCombi := string.Join ('.', [iParentPropertyName, iPropertyName]).TrimLeft (['.']); - OnlyNegative := true; - for l := 0 to 1 do - begin - for S in PropertyList do - begin - if S.IsEmpty then - continue; - Negative := (S.Substring(0, 1) = '-'); - OnlyNegative := OnlyNegative and Negative; - if (l = 0) and Negative then - begin - if MatchesMask ('-' + iPropertyName, S) then - begin - oFoundCondition := Format ('propertyList exclude "%s"', [S]); - Result := false; - exit; - end; - end - else if (l = 1) and not Negative then - begin - if MatchesMask (iPropertyName, S) then - begin - oFoundCondition := Format ('propertyList include "%s"', [S]); - Result := true; - exit; - end; - end; - end; - if not Result and OnlyNegative then - begin - oFoundCondition := 'propertyList contains only exclude'; - Result := true; - end; - end; + Result := PropertyList.IndexOfProperty (iPropertyName, iParentPropertyName, '', + oFoundCondition) >= 0; + if Result then + exit; end; end; @@ -2115,7 +2103,7 @@ procedure tJson2PumlCharacteristicDefinition.SortUsedColumnsByPropertyList (iUse j: Integer; begin i := 0; - for col in PropertyList do + for col in PropertyList.ItemList do begin j := iUsedColumns.IndexOf (col); if j >= 0 then @@ -2132,7 +2120,7 @@ procedure tJson2PumlCharacteristicDefinition.WriteToJson (oJsonOutPut: TStrings; Value: string; IsRecord: boolean; begin - IsRecord := true; + IsRecord := True; if (CharacteristicType = jctRecord) and (not IncludeIndex) and (PropertyList.Count <= 0) then begin Value := ClearJsonPropertyValue (ParentProperty); @@ -2140,7 +2128,7 @@ procedure tJson2PumlCharacteristicDefinition.WriteToJson (oJsonOutPut: TStrings; end else Value := JsonAttributeValue ('parentProperty', ParentProperty) + JsonAttributeValue ('type', - CharacteristicType.ToString) + JsonAttributeValueList ('propertyList', PropertyList) + + CharacteristicType.ToString) + JsonAttributeValueList ('propertyList', PropertyList.ItemList) + JsonAttributeValue ('includeIndex', IncludeIndexStr, false); if IsRecord then Value := Format ('{%s}', [Value.trimRight([',', ' '])]) @@ -2278,7 +2266,7 @@ procedure tJson2PumlConverterGroupDefinition.WriteToJson (oJsonOutPut: TStrings; Description.WriteToJson (oJsonOutPut, 'description', iLevel + 1, iWriteEmpty); WriteToJsonValue (oJsonOutPut, 'defaultOption', DefaultOption, iLevel + 1, iWriteEmpty); OptionList.WriteToJson (oJsonOutPut, 'options', iLevel + 1, iWriteEmpty); - BaseOption.WriteToJson (oJsonOutPut, 'baseOption', iLevel + 1, true); + BaseOption.WriteToJson (oJsonOutPut, 'baseOption', iLevel + 1, True); WriteObjectEndToJson (oJsonOutPut, iLevel); end; @@ -2328,9 +2316,9 @@ function tJson2PumlConverterDefinitionEnumerator.MoveNext: boolean; constructor tJson2PumlConverterDefinitionList.Create; begin inherited; - Sorted := true; + Sorted := True; Duplicates := dupIgnore; - OwnsObjects := true; + OwnsObjects := True; end; procedure tJson2PumlConverterDefinitionList.AddDefinition (iDefinition: tJson2PumlConverterDefinition); @@ -2360,7 +2348,7 @@ function tJson2PumlConverterDefinitionList.GetDefinitionByName (iOptionName: str i: Integer; FoundCondition: string; begin - i := IndexOfProperty (iOptionName, '', '', '', FoundCondition, false, false); + i := IndexOfProperty (iOptionName, '', '', FoundCondition); if i >= 0 then Result := Definition[i] else @@ -2393,7 +2381,7 @@ function tJson2PumlConverterDefinitionList.ReadFromJson (iJsonValue: TJSONValue; exit; if not Assigned (JsonValue) then exit; - Result := true; + Result := True; if JsonValue is TJSONArray then begin JsonArray := TJSONArray (JsonValue); diff --git a/source/json2pumlframe.pas b/source/json2pumlframe.pas index 32d8362..3a5a415 100644 --- a/source/json2pumlframe.pas +++ b/source/json2pumlframe.pas @@ -128,7 +128,7 @@ procedure TJson2PumlOutputFileFrame.CreateMemos (iCreateMemoProc: TJson2PumlCrea SVGIconImage.Parent := SVGScrollBox; SVGIconImage.AutoSize := False; SVGIconImage.Align := alClient; - SVGIconImage.Stretch := true; + SVGIconImage.Stretch := false; SVGIconImage.Proportional := true; {$ENDIF} diff --git a/source/json2pumlinputhandler.pas b/source/json2pumlinputhandler.pas index 761fcc4..572024c 100644 --- a/source/json2pumlinputhandler.pas +++ b/source/json2pumlinputhandler.pas @@ -168,10 +168,11 @@ TJson2PumlInputHandler = class(tPersistent) function CalculateOutputFileNamePath (iFileName, iSourceFileName: string; iNewFileExtension: string = ''): string; function CalculateSummaryFileName (iOutputFormat: tJson2PumlOutputFormat): string; procedure ClearAllRecords; - procedure ConvertAllRecordsInt (iIndex: Integer = - 1); + procedure ConvertAllRecordsInt; procedure CreateAllRecords; function CreateSingleRecord (iInputFile: tJson2PumlInputFileDefinition; iInputGroup, iInputDetail: string) : TJson2PumlInputHandlerRecord; + procedure GenerateAllOutputsFromPuml; procedure GetFileNameExtension (iFileName, iNewFileExtension: string; var oFileNameExtension: string; var oFileFormat: tJson2PumlOutputFormat); function IsConverting: Boolean; @@ -646,7 +647,8 @@ function TJson2PumlInputHandler.CalculateSummaryFileName (iOutputFormat: tJson2P var Filename: string; begin - Filename := CalculateOutputFileName (ExtractFileName(CurrentSummaryFileName), '', iOutputFormat.FileExtension(False), false); + Filename := CalculateOutputFileName (ExtractFileName(CurrentSummaryFileName), '', + iOutputFormat.FileExtension(False), False); Result := CalculateSummaryPath; Result := PathCombine (Result, Filename); Result := ReplaceInvalidPathFileNameChars (Result, true); @@ -696,7 +698,7 @@ procedure TJson2PumlInputHandler.ConvertAllRecords (iIndex: Integer = - 1); RecreateAllRecords; end; -procedure TJson2PumlInputHandler.ConvertAllRecordsInt (iIndex: Integer = - 1); +procedure TJson2PumlInputHandler.ConvertAllRecordsInt; var i: Integer; SingleRecord: TJson2PumlInputHandlerRecord; @@ -711,6 +713,7 @@ procedure TJson2PumlInputHandler.ConvertAllRecordsInt (iIndex: Integer = - 1); if HandlerRecordList.Count <= 0 then Exit; JarFile := CalculateRuntimeJarFile; + OutputFormats := GetCurrentOutputFormats; Converter := TJson2PumlConverter.Create; try Converter.InputHandler := self; @@ -718,13 +721,9 @@ procedure TJson2PumlInputHandler.ConvertAllRecordsInt (iIndex: Integer = - 1); begin if Assigned (OnNotifyChange) then OnNotifyChange (self, i + 1, HandlerRecordList.Count); - if (iIndex >= 0) and (iIndex < HandlerRecordList.Count) then - if i <> iIndex then - Continue; SingleRecord := self[i]; SingleRecord.ConverterLog.Clear; - OutputFormats := GetCurrentOutputFormats; SingleRecord.InputFile.IsConverted := False; if not SingleRecord.InputFile.IncludeIntoOutput then Continue; @@ -740,9 +739,9 @@ procedure TJson2PumlInputHandler.ConvertAllRecordsInt (iIndex: Integer = - 1); if SingleRecord.InputFile.IsSummaryFile then BuildSummaryFile (SingleRecord); - GlobalLoghandler.Info ('[%3d/%3d] Convert %s', [i + 1, HandlerRecordList.Count, - SingleRecord.InputFile.OutputFileName]); - GlobalLoghandler.Info (' to %s', [OutputFile]); + GlobalLoghandler.Info ('[%3d/%3d] Generate puml : Convert %s to %s', [i + 1, HandlerRecordList.Count, + SingleRecord.InputFile.OutputFileName, OutputFile]); +// GlobalLoghandler.Info (' to %s', [OutputFile]); if Assigned (AfterUpdateRecord) then AfterUpdateRecord (SingleRecord); // To Update the console Converter.LeadingObject := SingleRecord.InputFile.LeadingObject; @@ -751,7 +750,7 @@ procedure TJson2PumlInputHandler.ConvertAllRecordsInt (iIndex: Integer = - 1); Converter.PumlFile := OutputFile; if not Converter.Convert then Continue; - GlobalLoghandler.Info (' %-4s generated', ['puml']); + // GlobalLoghandler.Info (' %-4s generated', ['puml']); if CmdLineParameter.GenerateOutputDefinition then CurrentConverterDefinition.WriteToJsonFile (ChangeFileExt(OutputFile, '.definition.json'), true); @@ -767,26 +766,11 @@ procedure TJson2PumlInputHandler.ConvertAllRecordsInt (iIndex: Integer = - 1); SingleRecord.InputFile.IsConverted := true; SingleRecord.InputFile.Output.PUmlFileName := OutputFile; SingleRecord.PUmlOutput.SaveToFile (SingleRecord.InputFile.Output.PUmlFileName); - if GenerateOutputsFromPuml (SingleRecord.InputFile.Output.PUmlFileName, JarFile, CurrentJavaRuntimeParameter, - GetCurrentPlantUmlRuntimeParameter, OutputFormats, CmdLineParameter.OpenOutputs) then - begin - if (jofPng in OutputFormats) and FileExists (jofPng.Filename(OutputFile)) then - SingleRecord.InputFile.Output.PNGFileName := jofPng.Filename (OutputFile) - else - SingleRecord.InputFile.Output.PNGFileName := ''; - if (jofSvg in OutputFormats) and FileExists (jofSvg.Filename(OutputFile)) then - SingleRecord.InputFile.Output.SVGFileName := jofSvg.Filename (OutputFile) - else - SingleRecord.InputFile.Output.SVGFileName := ''; - if (jofPdf in OutputFormats) and FileExists (jofPdf.Filename(OutputFile)) then - SingleRecord.InputFile.Output.PDFFilename := jofPdf.Filename (OutputFile) - else - SingleRecord.InputFile.Output.PDFFilename := ''; - end; end; if Assigned (AfterUpdateRecord) then AfterUpdateRecord (SingleRecord); end; + GenerateAllOutputsFromPuml; GenerateFileDirectory (CalculateSummaryFileName(jofPUML)); ConverterInputList.WriteToJsonOutputFiles (jofFileList.Filename(CalculateSummaryFileName(jofPUML))); // Use PUML to get the Filename with the option included @@ -896,6 +880,53 @@ procedure TJson2PumlInputHandler.EndLoadFile (iAutoStartConvert: Boolean = true) SetFileLoading (False, iAutoStartConvert); end; +procedure TJson2PumlInputHandler.GenerateAllOutputsFromPuml; +var + i: Integer; + SingleRecord: TJson2PumlInputHandlerRecord; + OutputFormats: tJson2PumlOutputFormats; + FileList: TStringList; +begin + OutputFormats := GetCurrentOutputFormats; + FileList := TStringList.Create; + try + for i := 0 to HandlerRecordList.Count - 1 do + begin + SingleRecord := self[i]; + if not SingleRecord.InputFile.IsConverted then + Continue; + FileList.Add (SingleRecord.InputFile.Output.PUmlFileName); + end; + if GenerateOutputsFromPumlFiles (FileList, CalculateRuntimeJarFile, CurrentJavaRuntimeParameter, GetCurrentPlantUmlRuntimeParameter, + OutputFormats, CmdLineParameter.OpenOutputs) then + for i := 0 to HandlerRecordList.Count - 1 do + begin + SingleRecord := self[i]; + if not SingleRecord.InputFile.IsConverted then + Continue; + if (jofPng in OutputFormats) and FileExistsMinSize (jofPng.Filename(SingleRecord.InputFile.Output.PUmlFileName)) + then + SingleRecord.InputFile.Output.PNGFileName := jofPng.Filename (SingleRecord.InputFile.Output.PUmlFileName) + else + SingleRecord.InputFile.Output.PNGFileName := ''; + if (jofSvg in OutputFormats) and FileExistsMinSize (jofSvg.Filename(SingleRecord.InputFile.Output.PUmlFileName)) + then + SingleRecord.InputFile.Output.SVGFileName := jofSvg.Filename (SingleRecord.InputFile.Output.PUmlFileName) + else + SingleRecord.InputFile.Output.SVGFileName := ''; + if (jofPdf in OutputFormats) and FileExistsMinSize (jofPdf.Filename(SingleRecord.InputFile.Output.PUmlFileName)) + then + SingleRecord.InputFile.Output.PDFFilename := jofPdf.Filename (SingleRecord.InputFile.Output.PUmlFileName) + else + SingleRecord.InputFile.Output.PDFFilename := ''; + if Assigned (AfterUpdateRecord) then + AfterUpdateRecord (SingleRecord); + end; + finally + FileList.Free; + end; +end; + procedure TJson2PumlInputHandler.GenerateSummaryZipFile; begin ConverterInputList.GenerateSummaryZipFile (CalculateSummaryFileName(jofZip)); diff --git a/source/json2pumlservice.deployproj b/source/json2pumlservice.deployproj index 6170be6..baca08f 100644 --- a/source/json2pumlservice.deployproj +++ b/source/json2pumlservice.deployproj @@ -27,7 +27,6 @@ True - json2pumlservice\Assets\ @@ -39,5 +38,4 @@ True - diff --git a/source/json2pumlservice.dproj b/source/json2pumlservice.dproj index 579c467..b50dd87 100644 --- a/source/json2pumlservice.dproj +++ b/source/json2pumlservice.dproj @@ -1,28 +1,18 @@  {501A20DC-159A-4DBF-B500-E5EEBE936DAD} - 19.5 + 20.1 None json2pumlservice.dpr True Debug - Win64 + Linux64 131 Console true - - true - Base - true - - - true - Base - true - true Base @@ -92,45 +82,37 @@ VCL;$(DCC_Framework) json2pumlservice - - CFBundleName=$(MSBuildProjectName);CFBundleDisplayName=$(MSBuildProjectName);CFBundleIdentifier=$(MSBuildProjectName);CFBundleVersion=1.0.0;CFBundleShortVersionString=1.0.0;CFBundlePackageType=APPL;CFBundleSignature=????;CFBundleAllowMixedLocalizations=YES;CFBundleExecutable=$(MSBuildProjectName);NSHighResolutionCapable=true;LSApplicationCategoryType=public.app-category.utilities;NSLocationUsageDescription=The reason for accessing the location information of the user;NSContactsUsageDescription=The reason for accessing the contacts;NSCalendarsUsageDescription=The reason for accessing the calendar data;NSRemindersUsageDescription=The reason for accessing the reminders;NSCameraUsageDescription=The reason for accessing the camera;NSMicrophoneUsageDescription=The reason for accessing the microphone;NSMotionUsageDescription=The reason for accessing the accelerometer;NSDesktopFolderUsageDescription=The reason for accessing the Desktop folder;NSDocumentsFolderUsageDescription=The reason for accessing the Documents folder;NSDownloadsFolderUsageDescription=The reason for accessing the Downloads folder;NSNetworkVolumesUsageDescription=The reason for accessing files on a network volume;NSRemovableVolumesUsageDescription=The reason for accessing files on a removable volume;NSSpeechRecognitionUsageDescription=The reason for requesting to send user data to Apple's speech recognition servers - Debug - - - CFBundleName=$(MSBuildProjectName);CFBundleDisplayName=$(MSBuildProjectName);CFBundleIdentifier=$(MSBuildProjectName);CFBundleVersion=1.0.0;CFBundleShortVersionString=1.0.0;CFBundlePackageType=APPL;CFBundleSignature=????;CFBundleAllowMixedLocalizations=YES;CFBundleExecutable=$(MSBuildProjectName);NSHighResolutionCapable=true;LSApplicationCategoryType=public.app-category.utilities;NSLocationUsageDescription=The reason for accessing the location information of the user;NSContactsUsageDescription=The reason for accessing the contacts;NSCalendarsUsageDescription=The reason for accessing the calendar data;NSRemindersUsageDescription=The reason for accessing the reminders;NSCameraUsageDescription=The reason for accessing the camera;NSMicrophoneUsageDescription=The reason for accessing the microphone;NSMotionUsageDescription=The reason for accessing the accelerometer;NSDesktopFolderUsageDescription=The reason for accessing the Desktop folder;NSDocumentsFolderUsageDescription=The reason for accessing the Documents folder;NSDownloadsFolderUsageDescription=The reason for accessing the Downloads folder;NSNetworkVolumesUsageDescription=The reason for accessing files on a network volume;NSRemovableVolumesUsageDescription=The reason for accessing files on a removable volume;NSSpeechRecognitionUsageDescription=The reason for requesting to send user data to Apple's speech recognition servers - Debug - DBXSqliteDriver;dxPSPrVwRibbonRS25;dxRibbonCustomizationFormRS25;vclactnband;dxChartControlRS25;vclFireDAC;cxExportRS25;dxHttpIndyRequestRS25;tethering;dxPScxCommonRS25;cxGridEMFRS25;FireDACADSDriver;cxPivotGridOLAPRS25;JvPluginSystem;cxSchedulerGridRS25;vcltouch;JvBands;vcldb;Intraweb;svn;JvJans;dxGaugeControlRS25;cxLibraryRS25;BaseOracleObjects25;dxFlowChartAdvancedCustomizeFormRS25;odacfmx250;vclx;dxSpreadSheetConditionalFormattingDialogsRS25;dxTileControlRS25;dxMapControlRS25;dxPDFViewerRS25;dxDockingRS25;VCLRESTComponents;dxPSLnksRS25;dxWizardControlRS25;dxRichEditControlRS25;IcsFmxD102Run;vclie;bindengine;dxFireDACServerModeRS25;JvHMI;FireDACMySQLDriver;dxPSdxPDFViewerLnkRS25;bindcompdbx;dxPSdxLCLnkRS25;IndyIPServer;dxGanttControlRS25;dac250;IndySystem;dsnapcon;dxPSRichEditControlLnkRS25;FireDACMSAccDriver;fmxFireDAC;vclimg;Jcl;dxdbtrRS25;dxPScxTLLnkRS25;dxSpreadSheetRS25;dxPScxSchedulerLnkRS25;FMXTee;cxGridRS25;dxSpreadSheetCoreConditionalFormattingDialogsRS25;DbxCommonDriver;dxorgcRS25;JvManagedThreads;dxCloudServiceLibraryRS25;xmlrtl;JvTimeFramework;fmxobj;dxPScxGridLnkRS25;rtl;DbxClientDriver;dacvcl250;dxPSCoreRS25;CodeSiteExpressPkg;dxmdsRS25;JvSystem;JvStdCtrls;appanalytics;IndyIPClient;bindcompvcl;dxADOEMFRS25;TeeUI;JvDocking;JvPascalInterpreter;VclSmp;JclVcl;cxVerticalGridRS25;dxtrmdRS25;JvControls;JvPrintPreview;dxADOServerModeRS25;dxCoreRS25;cxSchedulerTreeBrowserRS25;oraprov250;DBXInterBaseDriver;dxRichEditControlCoreRS25;dxPSTeeChartRS25;JvGlobus;svnui;JvMM;dxPSdxFCLnkRS25;dxRichEditCoreRS25;SyntEditDB25;bindcompfmx;JvNet;inetdb;JvAppFrm;FmxTeeUI;fmx;fmxdae;dxPScxPivotGridLnkRS25;dxBarDBNavRS25;dxTabbedMDIRS25;JvWizards;dbexpress;IndyCore;dxFlowChartRS25;dxRichEditDocumentModelRS25;JvPageComps;dsnap;dxBarRS25;dxPSDBTeeChartRS25;IcsVclD102Run;dxdborRS25;dxPScxExtCommonRS25;cxPivotGridRS25;JclDeveloperTools;dxSpreadSheetReportDesignerRS25;dxNavBarRS25;dxPSdxSpreadSheetLnkRS25;cxSchedulerRibbonStyleEventEditorRS25;JvCmp;DBXMySQLDriver;FireDACCommonODBC;cxTreeListRS25;IndyIPCommon;JvCustom;vcl;dxPScxVGridLnkRS25;JvXPCtrls;dxBarExtItemsRS25;dxComnRS25;dxPSdxDBTVLnkRS25;madExcept_;madBasic_;TeeDB;dxSpreadSheetCoreRS25;dxServerModeRS25;JvCore;dxPScxPCProdRS25;dxFlowChartLayoutsRS25;JvCrypt;FireDACPgDriver;dxEMFRS25;JvDlgs;JvRuntimeDesign;Tee;dxPsPrVwAdvRS25;vclwinx;madDisAsm_;cxTreeListdxBarPopupMenuRS25;CustomIPTransport;vcldsnap;cxSchedulerWebServiceStorageRS25;dxPSdxOCLnkRS25;bindcomp;SyntEdit25;cxPivotGridChartRS25;cxSchedulerRS25;dxBarExtDBItemsRS25;dxOrgChartAdvancedCustomizeFormRS25;SynEdit_R;dxDBXServerModeRS25;dxFireDACEMFRS25;dxGDIPlusRS25;dxPSdxGaugeControlLnkRS25;dmvcframeworkRT;dbxcds;adortl;dmvcframeworkDT;odac250;dacfmx250;dxPSdxDBOCLnkRS25;dxRibbonRS25;dsnapxml;dxSpellCheckerRS25;dbrtl;inetdbxpress;IndyProtocols;dxFlowChartDesignerRS25;IcsCommonD102Run;JclContainers;odacvcl250;dxPSdxMapControlLnkRS25;fmxase;$(DCC_UsePackage) Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace) Debug - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 1033 true (None) - 106 + 107 ..\documentation\icons\json2puml_icon.png ..\documentation\icons\json2puml_icon.png none 2 2 - 10 + 11 DBXSqliteDriver;dxPSPrVwRibbonRS25;dxRibbonCustomizationFormRS25;vclactnband;dxChartControlRS25;vclFireDAC;cxExportRS25;dxHttpIndyRequestRS25;tethering;dxPScxCommonRS25;cxGridEMFRS25;FireDACADSDriver;cxPivotGridOLAPRS25;cxSchedulerGridRS25;vcltouch;vcldb;Intraweb;dxGaugeControlRS25;cxLibraryRS25;dxFlowChartAdvancedCustomizeFormRS25;vclx;dxSpreadSheetConditionalFormattingDialogsRS25;dxTileControlRS25;dxMapControlRS25;dxPDFViewerRS25;dxDockingRS25;VCLRESTComponents;dxPSLnksRS25;dxWizardControlRS25;dxRichEditControlRS25;IcsFmxD102Run;vclie;bindengine;dxFireDACServerModeRS25;FireDACMySQLDriver;dxPSdxPDFViewerLnkRS25;bindcompdbx;dxPSdxLCLnkRS25;IndyIPServer;dxGanttControlRS25;IndySystem;dsnapcon;dxPSRichEditControlLnkRS25;FireDACMSAccDriver;fmxFireDAC;vclimg;dxdbtrRS25;dxPScxTLLnkRS25;dxSpreadSheetRS25;dxPScxSchedulerLnkRS25;FMXTee;cxGridRS25;dxSpreadSheetCoreConditionalFormattingDialogsRS25;DbxCommonDriver;dxorgcRS25;dxCloudServiceLibraryRS25;xmlrtl;fmxobj;dxPScxGridLnkRS25;rtl;DbxClientDriver;dxPSCoreRS25;dxmdsRS25;appanalytics;IndyIPClient;bindcompvcl;dxADOEMFRS25;TeeUI;VclSmp;cxVerticalGridRS25;dxtrmdRS25;dxADOServerModeRS25;dxCoreRS25;cxSchedulerTreeBrowserRS25;DBXInterBaseDriver;dxRichEditControlCoreRS25;dxPSTeeChartRS25;dxPSdxFCLnkRS25;dxRichEditCoreRS25;bindcompfmx;inetdb;FmxTeeUI;fmx;fmxdae;dxPScxPivotGridLnkRS25;dxBarDBNavRS25;dxTabbedMDIRS25;dbexpress;IndyCore;dxFlowChartRS25;dxRichEditDocumentModelRS25;dsnap;dxBarRS25;dxPSDBTeeChartRS25;IcsVclD102Run;dxdborRS25;dxPScxExtCommonRS25;cxPivotGridRS25;dxSpreadSheetReportDesignerRS25;dxNavBarRS25;dxPSdxSpreadSheetLnkRS25;cxSchedulerRibbonStyleEventEditorRS25;DBXMySQLDriver;FireDACCommonODBC;cxTreeListRS25;IndyIPCommon;vcl;dxPScxVGridLnkRS25;dxBarExtItemsRS25;dxComnRS25;dxPSdxDBTVLnkRS25;TeeDB;dxSpreadSheetCoreRS25;dxServerModeRS25;dxPScxPCProdRS25;dxFlowChartLayoutsRS25;FireDACPgDriver;dxEMFRS25;Tee;dxPsPrVwAdvRS25;vclwinx;cxTreeListdxBarPopupMenuRS25;CustomIPTransport;vcldsnap;cxSchedulerWebServiceStorageRS25;dxPSdxOCLnkRS25;bindcomp;cxPivotGridChartRS25;cxSchedulerRS25;dxBarExtDBItemsRS25;dxOrgChartAdvancedCustomizeFormRS25;SynEdit_R;dxDBXServerModeRS25;dxFireDACEMFRS25;dxGDIPlusRS25;dxPSdxGaugeControlLnkRS25;dbxcds;adortl;dxPSdxDBOCLnkRS25;dxRibbonRS25;dsnapxml;dxSpellCheckerRS25;dbrtl;inetdbxpress;IndyProtocols;dxFlowChartDesignerRS25;IcsCommonD102Run;dxPSdxMapControlLnkRS25;fmxase;$(DCC_UsePackage) Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;$(DCC_Namespace) Debug - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 1033 true (None) - 106 + 107 ..\documentation\icons\json2puml_icon.png ..\documentation\icons\json2puml_icon.png none 2 2 - 10 + 11 DEBUG;$(DCC_Define) @@ -148,23 +130,23 @@ false true 1033 - FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 - 106 + FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + 107 none 2 2 - 10 + 11 /debug 3 madExcept;LeakChecking;$(DCC_Define) - 106 - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + 107 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 2 2 /debug - 10 + 11 3 @@ -174,18 +156,18 @@ 0 - 106 - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + 107 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 2 2 - 10 + 11 - 106 - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + 107 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) Service;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 2 2 - 10 + 11 @@ -359,6 +341,16 @@ 1 + + + res\drawable-anydpi-v21 + 1 + + + res\drawable-anydpi-v21 + 1 + + res\values @@ -379,6 +371,66 @@ 1 + + + res\values-v31 + 1 + + + res\values-v31 + 1 + + + + + res\drawable-anydpi-v26 + 1 + + + res\drawable-anydpi-v26 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-anydpi-v33 + 1 + + + res\drawable-anydpi-v33 + 1 + + res\values @@ -389,6 +441,16 @@ 1 + + + res\values-night-v21 + 1 + + + res\values-night-v21 + 1 + + res\drawable @@ -559,6 +621,56 @@ 1 + + + res\drawable-anydpi-v24 + 1 + + + res\drawable-anydpi-v24 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-night-anydpi-v21 + 1 + + + res\drawable-night-anydpi-v21 + 1 + + + + + res\drawable-anydpi-v31 + 1 + + + res\drawable-anydpi-v31 + 1 + + + + + res\drawable-night-anydpi-v31 + 1 + + + res\drawable-night-anydpi-v31 + 1 + + 1 @@ -1000,8 +1112,6 @@ True - False - False True True diff --git a/source/json2pumlservice.res b/source/json2pumlservice.res index 978ac05..36f26e2 100644 Binary files a/source/json2pumlservice.res and b/source/json2pumlservice.res differ diff --git a/source/json2pumltools.pas b/source/json2pumltools.pas index fbbb762..afbb256 100644 --- a/source/json2pumltools.pas +++ b/source/json2pumltools.pas @@ -39,9 +39,9 @@ function ApplicationCompileVersion: string; function ConvertFileToBase64 (iFileName: string): string; -function ExecuteCommand (const iCommand: WideString; const iCommandInfo: string): Boolean; overload; +function ExecuteCommand (const iCommand: WideString; const iCommandType, iCommandInfo: string): Boolean; overload; -function ExecuteCommand (const iCommand: WideString; const iCommandInfo: string; +function ExecuteCommand (const iCommand: WideString; const iCommandType, iCommandInfo: string; oCommandOutPut, oCommandErrors: TStringList): Boolean; overload; function FileContent (iFileName: string): string; @@ -60,9 +60,12 @@ procedure GenerateDirectory (const iDirectory: string); procedure GenerateFileDirectory (iFileName: string); +function GenerateOutputFromPumlFiles (iPlantUmlFiles: TStringList; const iPlantUmlJarFile, iJavaRuntimeParameter, + iPlantUmlRuntimeParameter: string; iFormat: tJson2PumlOutputFormat; iOpenAfter: Boolean): Boolean; +function GenerateOutputsFromPumlFiles (iPlantUmlFiles: TStringList; const iPlantUmlJarFile, iJavaRuntimeParameter, + iPlantUmlRuntimeParameter: string; iOutputFormats, iOpenOutputs: tJson2PumlOutputFormats): Boolean; function GenerateOutputFromPuml (const iPlantUmlFile, iPlantUmlJarFile, iJavaRuntimeParameter, iPlantUmlRuntimeParameter : string; iFormat: tJson2PumlOutputFormat; iOpenAfter: Boolean): Boolean; - function GenerateOutputsFromPuml (const iPlantUmlFile, iPlantUmlJarFile, iJavaRuntimeParameter, iPlantUmlRuntimeParameter: string; iOutputFormats, iOpenOutputs: tJson2PumlOutputFormats): Boolean; @@ -353,28 +356,31 @@ function ExecuteCommandInternal (const iCommand: WideString; oCommandOutPut, oCo end; {$ENDIF} -function ExecuteCommand (const iCommand: WideString; const iCommandInfo: string): Boolean; +function ExecuteCommand (const iCommand: WideString; const iCommandType, iCommandInfo: string): Boolean; var vCommandOutPut, vCommandErrors: TStringList; begin vCommandOutPut := TStringList.Create; vCommandErrors := TStringList.Create; try - Result := ExecuteCommand (iCommand, iCommandInfo, vCommandOutPut, vCommandErrors); + Result := ExecuteCommand (iCommand, iCommandType, iCommandInfo, vCommandOutPut, vCommandErrors); finally vCommandOutPut.Free; vCommandErrors.Free; end; end; -function ExecuteCommand (const iCommand: WideString; const iCommandInfo: string; +function ExecuteCommand (const iCommand: WideString; const iCommandType, iCommandInfo: string; oCommandOutPut, oCommandErrors: TStringList): Boolean; var s: string; begin oCommandOutPut.clear; oCommandErrors.clear; - GlobalLoghandler.Info ('Execute %s', [iCommandInfo]); + if not iCommandType.IsEmpty then + GlobalLoghandler.Info ('%s : Execute %s', [iCommandType, iCommandInfo]) + else + GlobalLoghandler.Info ('Execute %s', [iCommandInfo]); Result := ExecuteCommandInternal (iCommand, oCommandOutPut, oCommandErrors); if oCommandOutPut.Count > 0 then begin @@ -501,7 +507,7 @@ function FileCount (iFileFilter: string): Integer; c: Integer; searchResult: TSearchRec; begin - if iFileFilter.isEmpty then + if iFileFilter.IsEmpty then Result := 0 else begin @@ -548,6 +554,77 @@ procedure GenerateFileDirectory (iFileName: string); GenerateDirectory (ExtractFilePath(iFileName)); end; +function GenerateOutputFromPumlFiles (iPlantUmlFiles: TStringList; const iPlantUmlJarFile, iJavaRuntimeParameter, + iPlantUmlRuntimeParameter: string; iFormat: tJson2PumlOutputFormat; iOpenAfter: Boolean): Boolean; +var + Command: string; + DestinationFile: string; + PumlFile: string; + FileList: string; +begin + Result := false; + if not iFormat.IsPumlOutput then + Exit; + if iPlantUmlJarFile.IsEmpty then + Exit; + if not FileExists (iPlantUmlJarFile) then + begin + GlobalLoghandler.Error (jetPlantUmlFileNotFound, [iPlantUmlJarFile]); + Exit; + end; + FileList := ''; + for PumlFile in iPlantUmlFiles do + begin + if not FileExists (PumlFile) then + Continue; + DestinationFile := iFormat.FileName (PumlFile); + + if FileExists (DestinationFile) then + tFile.Delete (DestinationFile); + + FileList := FileList.Join (' ', [FileList, Format('"%s"', [PumlFile])]); + end; + if FileList.IsEmpty then + Exit; + + Command := Format ('java %s -jar "%s" %s %s %s', [iJavaRuntimeParameter.Trim, iPlantUmlJarFile, FileList, + iFormat.PumlGenerateFlag, iPlantUmlRuntimeParameter]).Trim; + + Result := ExecuteCommand (Command, 'Generate ' + iFormat.ToString, Command); + if Result then + begin + Result := false; + for PumlFile in iPlantUmlFiles do + begin + if not FileExists (PumlFile) then + Continue; + DestinationFile := iFormat.FileName (PumlFile); + if FileExistsMinSize (DestinationFile) then + begin + Result := true; + if iOpenAfter then + OpenFile (DestinationFile); + end + else + GlobalLoghandler.Error (jetPlantUmlResultGenerationFailed, [iFormat.ToString, PumlFile]); + end; + end; + // if Result then + // GlobalLoghandler.Info (' %-4s generated', [iFormat.toString]); +end; + +function GenerateOutputsFromPumlFiles (iPlantUmlFiles: TStringList; const iPlantUmlJarFile, iJavaRuntimeParameter, + iPlantUmlRuntimeParameter: string; iOutputFormats, iOpenOutputs: tJson2PumlOutputFormats): Boolean; +var + f: tJson2PumlOutputFormat; +begin + Result := true; + for f in iOutputFormats do + if f.IsPumlOutput then + Result := Result and GenerateOutputFromPumlFiles (iPlantUmlFiles, iPlantUmlJarFile, iJavaRuntimeParameter, + iPlantUmlRuntimeParameter, f, f in iOpenOutputs); +end; + function GenerateOutputFromPuml (const iPlantUmlFile, iPlantUmlJarFile, iJavaRuntimeParameter, iPlantUmlRuntimeParameter : string; iFormat: tJson2PumlOutputFormat; iOpenAfter: Boolean): Boolean; var @@ -559,7 +636,7 @@ function GenerateOutputFromPuml (const iPlantUmlFile, iPlantUmlJarFile, iJavaRun Exit; if not iFormat.IsPumlOutput then Exit; - if iPlantUmlJarFile.isEmpty then + if iPlantUmlJarFile.IsEmpty then Exit; if not FileExists (iPlantUmlJarFile) then begin @@ -567,7 +644,6 @@ function GenerateOutputFromPuml (const iPlantUmlFile, iPlantUmlJarFile, iJavaRun Exit; end; DestinationFile := iFormat.FileName (iPlantUmlFile); - GenerateFileDirectory (DestinationFile); if FileExists (DestinationFile) then tFile.Delete (DestinationFile); @@ -575,19 +651,19 @@ function GenerateOutputFromPuml (const iPlantUmlFile, iPlantUmlJarFile, iJavaRun Command := Format ('java %s -jar "%s" "%s" %s %s', [iJavaRuntimeParameter.Trim, iPlantUmlJarFile, iPlantUmlFile, iFormat.PumlGenerateFlag, iPlantUmlRuntimeParameter]).Trim; - Result := ExecuteCommand (Command, Command); + Result := ExecuteCommand (Command, 'Generate ' + iFormat.ToString, Command); if Result then begin Result := FileExistsMinSize (DestinationFile); if Result then begin - GlobalLoghandler.Info (' %-4s generated', [iFormat.toString]); + // GlobalLoghandler.Info (' %-4s generated', [iFormat.toString]); if iOpenAfter then OpenFile (DestinationFile); end; end; if not Result then - GlobalLoghandler.Error (jetPlantUmlResultGenerationFailed, [iFormat.toString, iPlantUmlFile]); + GlobalLoghandler.Error (jetPlantUmlResultGenerationFailed, [iFormat.ToString, iPlantUmlFile]); end; function GenerateOutputsFromPuml (const iPlantUmlFile, iPlantUmlJarFile, iJavaRuntimeParameter, @@ -607,7 +683,7 @@ function GetPlantUmlVersion (iPlantUmlJarFile, iJavaRuntimeParameter: string): s Command: string; vCommandOutPut, vCommandErrors: TStringList; begin - if iPlantUmlJarFile.isEmpty then + if iPlantUmlJarFile.IsEmpty then Result := 'PlantUml jar file not defined' else if not FileExists (iPlantUmlJarFile) then Result := Format ('defined PlantUml jar file (%s) not existing', [iPlantUmlJarFile]) @@ -617,7 +693,7 @@ function GetPlantUmlVersion (iPlantUmlJarFile, iJavaRuntimeParameter: string): s vCommandErrors := TStringList.Create; try Command := Format ('java %s -jar "%s" -version', [iJavaRuntimeParameter.Trim, iPlantUmlJarFile.Trim]); - ExecuteCommand (Command, Command, vCommandOutPut, vCommandErrors); + ExecuteCommand (Command, 'get plantuml version', Command, vCommandOutPut, vCommandErrors); Result := vCommandOutPut.Text; finally vCommandOutPut.Free; @@ -759,7 +835,7 @@ procedure OpenFile (iFileName: string); function PathCombine (const Path1, Path2: string): string; begin - if not Path1.isEmpty then + if not Path1.IsEmpty then Result := Path1.TrimRight (tPath.DirectorySeparatorChar) + tPath.DirectorySeparatorChar else Result := ''; @@ -825,9 +901,9 @@ function ReplaceInvalidPathChars (const iPathName: string; iFinal: Boolean = fal function ValidateOutputSuffix (iOutputSuffix: string): string; begin Result := iOutputSuffix.Trim; - if not Result.isEmpty then + if not Result.IsEmpty then if CharInSet (Result[1], ['_', '-', '.']) then - if Result.Substring (1).Trim.isEmpty then + if Result.Substring (1).Trim.IsEmpty then Result := '' else else @@ -866,14 +942,14 @@ function FileNameWithSuffix (iFileName, iFileNameSuffix: string): string; var Extension: string; begin - if iFileNameSuffix.isEmpty then + if iFileNameSuffix.IsEmpty then begin Result := iFileName; Exit; end; Extension := tPath.GetExtension (iFileName); - Result := TPath.Combine(TPath.GetDirectoryName(iFileName), TPath.GetFileNameWithoutExtension(iFileName)); - Result:= Result + iFileNameSuffix+ Extension; + Result := tPath.Combine (tPath.GetDirectoryName(iFileName), tPath.GetFileNameWithoutExtension(iFileName)); + Result := Result + iFileNameSuffix + Extension; end; function LogIndent (iIndent: Integer): string; @@ -997,7 +1073,7 @@ class function TCurlUtils.CalculateCommandExecute (const iBaseUrl: string; const Result := ''; Url := FullUrl (iBaseUrl, iUrlParts, iCurlParameterList, iCurlDetailParameterList); - if Url.isEmpty then + if Url.IsEmpty then Exit; Command := CombineParameter ([CalculateUrlParameter(Url), CombineParameter(iOptions), @@ -1075,7 +1151,7 @@ class function TCurlUtils.CheckExecuteEvaluation (const iOutputFile: string; iEx if not Result then GlobalLoghandler.Info ('curl file %s skipped - validating curlExecuteEvaluation [%s]->[%s] not successful', [iOutputFile, iExecuteEvaluation, ExecuteEvaluation]) - else if not iExecuteEvaluation.Trim.isEmpty then + else if not iExecuteEvaluation.Trim.IsEmpty then GlobalLoghandler.Debug ('curl file %s - validating curlExecuteEvaluation [%s]->[%s] successful', [iOutputFile, iExecuteEvaluation, ExecuteEvaluation]); except @@ -1089,13 +1165,13 @@ class function TCurlUtils.CheckEvaluation (iExecuteEvaluation: string): Boolean; BindExpr: TBindingExpressionDefault; begin Result := true; - if iExecuteEvaluation.Trim.isEmpty then + if iExecuteEvaluation.Trim.IsEmpty then Exit; BindExpr := TBindingExpressionDefault.Create; try BindExpr.Source := iExecuteEvaluation; BindExpr.recompile; - Result := BindExpr.Evaluate.GetValue.toString.ToLower = 'true'; + Result := BindExpr.Evaluate.GetValue.ToString.ToLower = 'true'; finally BindExpr.Free; end; @@ -1136,16 +1212,16 @@ class function TCurlUtils.GetResultFromOutput (iOutputFileName: string; iCommand if vExitCode <> '0' then oErrorMessage := Format ('curl command failed : (%s) : %s', [vExitCode, vErrorMessage]) else if vResponseCode <> '200' then - if vErrorMessage.isEmpty then + if vErrorMessage.IsEmpty then oErrorMessage := Format ('Invalid HTTP Response : %s', [vResponseCode]) else oErrorMessage := Format ('Invalid HTTP Response : %s - %s', [vResponseCode, vErrorMessage]); end; - if not FileExists (iOutputFileName) and oErrorMessage.isEmpty then + if not FileExists (iOutputFileName) and oErrorMessage.IsEmpty then oErrorMessage := Format ('Outputfile "%s" not generated.', [iOutputFileName]); - Result := oErrorMessage.isEmpty; + Result := oErrorMessage.IsEmpty; end; class function TCurlUtils.Execute (const iBaseUrl: string; const iUrlParts, iOptions: array of string; @@ -1166,10 +1242,10 @@ class function TCurlUtils.Execute (const iBaseUrl: string; const iUrlParts, iOpt begin Result := false; - if iOutputFile.Trim.isEmpty then + if iOutputFile.Trim.IsEmpty then Exit; Url := FullUrl (iBaseUrl, iUrlParts, iCurlParameterList, iCurlDetailParameterList); - if Url.Trim.isEmpty then + if Url.Trim.IsEmpty then begin GlobalLoghandler.Error (jetCurlFileSkippedUrlMissing, [iOutputFile]); Exit; @@ -1177,7 +1253,7 @@ class function TCurlUtils.Execute (const iBaseUrl: string; const iUrlParts, iOpt oProtocolCurlCommand := CalculateCommand (iBaseUrl, iUrlParts, iOptions, iOutputFile, iCurlParameterList, iCurlDetailParameterList, true); - if oProtocolCurlCommand.isEmpty then + if oProtocolCurlCommand.IsEmpty then begin GlobalLoghandler.Error (jetCurlFileSkippedInvalidCurlCommand, [iOutputFile]); Exit; @@ -1210,7 +1286,8 @@ class function TCurlUtils.Execute (const iBaseUrl: string; const iUrlParts, iOpt vCommandOutPut := TStringList.Create; vCommandErrors := TStringList.Create; try - ExecuteCommand ('curl ' + Command, oProtocolCurlCommand, vCommandOutPut, vCommandErrors); + ExecuteCommand ('curl ' + Command, Format('curl fetch "%s"', [ExtractFileName(iOutputFile)]), + oProtocolCurlCommand, vCommandOutPut, vCommandErrors); Result := GetResultFromOutput (iOutputFile, vCommandOutPut, vErrorMessage); finally vCommandOutPut.Free; @@ -1248,7 +1325,7 @@ class function TCurlUtils.ReplaceCurlVariablesFromEnvironment (iValue: string): begin s := iValue; Value := ''; - while not s.isEmpty do + while not s.IsEmpty do begin i := s.IndexOf ('${'); if i < 0 then @@ -1266,7 +1343,7 @@ class function TCurlUtils.ReplaceCurlVariablesFromEnvironment (iValue: string): end; v := s.Substring (2, i - 2); v := GetEnvironmentVariable (v.Trim); - if v.isEmpty then + if v.IsEmpty then Value := Value + s.Substring (0, i + 1) else Value := Value + v; @@ -1283,7 +1360,7 @@ class function TCurlUtils.CleanUnusedCurlVariables (iValue: string): string; begin s := iValue; Value := ''; - while not s.isEmpty do + while not s.IsEmpty do begin i := s.IndexOf ('${'); if i < 0 then diff --git a/source/json2pumlui.dproj b/source/json2pumlui.dproj index e16520c..75326e9 100644 --- a/source/json2pumlui.dproj +++ b/source/json2pumlui.dproj @@ -1,7 +1,7 @@  {7F207EB1-4CFC-40D5-8CF2-09D5B35586AB} - 19.5 + 20.1 VCL json2pumlui.dpr True @@ -77,32 +77,32 @@ Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace) Debug true - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 1033 $(BDS)\bin\default_app.manifest - 106 + 107 ..\documentation\icons\json2puml_icon.png ..\documentation\icons\json2puml_icon.png none 2 2 - 10 + 11 DBXSqliteDriver;dxPSPrVwRibbonRS25;dxRibbonCustomizationFormRS25;vclactnband;dxChartControlRS25;vclFireDAC;cxExportRS25;dxHttpIndyRequestRS25;tethering;dxPScxCommonRS25;cxGridEMFRS25;FireDACADSDriver;cxPivotGridOLAPRS25;cxSchedulerGridRS25;vcltouch;vcldb;Intraweb;dxGaugeControlRS25;cxLibraryRS25;vclib;dxFlowChartAdvancedCustomizeFormRS25;vclx;dxSpreadSheetConditionalFormattingDialogsRS25;dxTileControlRS25;dxMapControlRS25;dxPDFViewerRS25;dxDockingRS25;VCLRESTComponents;dxPSLnksRS25;dxWizardControlRS25;dxRichEditControlRS25;vclie;bindengine;dxFireDACServerModeRS25;FireDACMySQLDriver;dxPSdxPDFViewerLnkRS25;bindcompdbx;dxPSdxLCLnkRS25;IndyIPServer;dxGanttControlRS25;IndySystem;dsnapcon;dxPSRichEditControlLnkRS25;FireDACMSAccDriver;fmxFireDAC;vclimg;dxdbtrRS25;dxPScxTLLnkRS25;dxSpreadSheetRS25;dxPScxSchedulerLnkRS25;FMXTee;cxGridRS25;dxSpreadSheetCoreConditionalFormattingDialogsRS25;DbxCommonDriver;dxorgcRS25;dxCloudServiceLibraryRS25;xmlrtl;fmxobj;dxPScxGridLnkRS25;rtl;DbxClientDriver;dxPSCoreRS25;dxmdsRS25;appanalytics;IndyIPClient;bindcompvcl;dxADOEMFRS25;TeeUI;VclSmp;cxVerticalGridRS25;dxtrmdRS25;dxADOServerModeRS25;dxCoreRS25;cxSchedulerTreeBrowserRS25;DBXInterBaseDriver;dxRichEditControlCoreRS25;dxPSTeeChartRS25;dxPSdxFCLnkRS25;dxRichEditCoreRS25;cxPageControldxBarPopupMenuRS25;bindcompfmx;inetdb;FmxTeeUI;fmx;fmxdae;dxPScxPivotGridLnkRS25;dxBarDBNavRS25;dxTabbedMDIRS25;dbexpress;IndyCore;dxFlowChartRS25;dxRichEditDocumentModelRS25;dsnap;dxBarRS25;dxPSDBTeeChartRS25;dxdborRS25;dxPScxExtCommonRS25;cxPivotGridRS25;dxSpreadSheetReportDesignerRS25;dxNavBarRS25;dxPSdxSpreadSheetLnkRS25;cxSchedulerRibbonStyleEventEditorRS25;DBXMySQLDriver;FireDACCommonODBC;cxTreeListRS25;IndyIPCommon;vcl;dxPScxVGridLnkRS25;dxBarExtItemsRS25;dxComnRS25;dxPSdxDBTVLnkRS25;TeeDB;dxSpreadSheetCoreRS25;dxServerModeRS25;dxPScxPCProdRS25;dxFlowChartLayoutsRS25;FireDACPgDriver;ibmonitor;dxEMFRS25;ibxpress;Tee;ibxbindings;dxPsPrVwAdvRS25;vclwinx;cxTreeListdxBarPopupMenuRS25;CustomIPTransport;vcldsnap;cxSchedulerWebServiceStorageRS25;dxPSdxOCLnkRS25;bindcomp;cxPivotGridChartRS25;cxSchedulerRS25;dxBarExtDBItemsRS25;dxOrgChartAdvancedCustomizeFormRS25;dxDBXServerModeRS25;dxFireDACEMFRS25;dxGDIPlusRS25;dxPSdxGaugeControlLnkRS25;dbxcds;adortl;dxPSdxDBOCLnkRS25;dxRibbonRS25;dsnapxml;dxSpellCheckerRS25;dbrtl;inetdbxpress;IndyProtocols;dxFlowChartDesignerRS25;dxPSdxMapControlLnkRS25;fmxase;$(DCC_UsePackage) Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;$(DCC_Namespace) Debug true - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 1033 $(BDS)\bin\default_app.manifest - 106 + 107 ..\documentation\icons\json2puml_icon.png ..\documentation\icons\json2puml_icon.png none 2 2 - 10 + 11 DEBUG;$(DCC_Define) @@ -114,10 +114,10 @@ false - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;LastCompiledTime=2022-06-26 23:48:42 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;LastCompiledTime=2022-06-26 23:48:42 PerMonitor true - 106 + 107 1033 ..\documentation\icons\json2puml-icon.png ..\documentation\icons\json2puml-icon.png @@ -125,21 +125,21 @@ /inputfile:"samples-local\tmf\data\bill_gh\bill_gh.json" /leadingobject:product /definitionfile:"samples\tmf\tmf_definition.json" /option:full 2 2 - 10 + 11 PerMonitorV2 - 106 + 107 true 1033 - /parameterfile:samples\spacex\spacex_parameter_launches.json /curlparameter:launch=latest /formatdefinitionfiles /option:full /generatedefaultconfiguration /nologfiles + /parameterfile:samples\spacex\spacex_parameter_launches.json /option:full /curlparameter:launch=next /outputformat=png,svg /generatedetails=true e:\Delphi\Projects\json2puml - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 ..\documentation\icons\json2puml_icon.png 2 ..\documentation\icons\json2puml_icon.png 2 - 10 + 11 3 @@ -151,20 +151,20 @@ true PerMonitor - 106 - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + 107 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 2 2 - 10 + 11 true PerMonitorV2 - 106 - CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.10.106;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 + 107 + CompanyName=SWE Jens Fudickar;FileDescription=$(MSBuildProjectName) UI;FileVersion=2.2.11.107;LegalCopyright=(c) by Jens Fudickar in 2023;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0 2 2 - 10 + 11 @@ -342,6 +342,16 @@ 1 + + + res\drawable-anydpi-v21 + 1 + + + res\drawable-anydpi-v21 + 1 + + res\values @@ -362,6 +372,66 @@ 1 + + + res\values-v31 + 1 + + + res\values-v31 + 1 + + + + + res\drawable-anydpi-v26 + 1 + + + res\drawable-anydpi-v26 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-anydpi-v33 + 1 + + + res\drawable-anydpi-v33 + 1 + + res\values @@ -372,6 +442,16 @@ 1 + + + res\values-night-v21 + 1 + + + res\values-night-v21 + 1 + + res\drawable @@ -542,6 +622,56 @@ 1 + + + res\drawable-anydpi-v24 + 1 + + + res\drawable-anydpi-v24 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-night-anydpi-v21 + 1 + + + res\drawable-night-anydpi-v21 + 1 + + + + + res\drawable-anydpi-v31 + 1 + + + res\drawable-anydpi-v31 + 1 + + + + + res\drawable-night-anydpi-v31 + 1 + + + res\drawable-night-anydpi-v31 + 1 + + 1 diff --git a/source/json2pumlui.res b/source/json2pumlui.res index b44e028..5eaaada 100644 Binary files a/source/json2pumlui.res and b/source/json2pumlui.res differ diff --git a/source/json2pumlwindowsservice.dpr b/source/json2pumlwindowsservice.dpr index d9448ce..5731dc0 100644 --- a/source/json2pumlwindowsservice.dpr +++ b/source/json2pumlwindowsservice.dpr @@ -25,7 +25,6 @@ located at https://github.com/jfudickar/json2puml program json2pumlwindowsservice; uses - madExcept, Vcl.SvcMgr, json2pumlwinservice in 'json2pumlwinservice.pas' {J2PWinService: TService}, json2pumldefinition in 'json2pumldefinition.pas', diff --git a/source/json2pumlwindowsservice.dproj b/source/json2pumlwindowsservice.dproj index f2ce4a1..0fae49f 100644 --- a/source/json2pumlwindowsservice.dproj +++ b/source/json2pumlwindowsservice.dproj @@ -1,7 +1,7 @@  {055C9561-EFCB-4463-908D-3F11549CA5F0} - 19.5 + 20.1 VCL True Debug @@ -18,11 +18,6 @@ Base true - - true - Base - true - true Base @@ -85,40 +80,37 @@ FireDACADSDriver;FireDACMSSQLDriver;RESTBackendComponents;bindengine;CloudService;FireDACMySQLDriver;DataSnapClient;IndySystem;FireDACInfxDriver;emshosting;FireDACTDataDriver;soaprtl;DbxCommonDriver;xmlrtl;soapmidas;DataSnapNativeClient;rtl;emsserverresource;DbxClientDriver;FireDACODBCDriver;DataSnapIndy10ServerTransport;FireDACMongoDBDriver;RESTComponents;DataSnapServerMidas;emsclientfiredac;DataSnapFireDAC;DatasnapConnectorsFreePascal;inetdb;emsedge;fmx;FireDACIBDriver;dbexpress;IndyCore;dsnap;emsclient;DataSnapCommon;FireDACCommon;DataSnapConnectors;soapserver;FireDACOracleDriver;FireDACCommonODBC;FireDACCommonDriver;inet;FireDACDb2Driver;FireDAC;FireDACSqliteDriver;FireDACPgDriver;FireDACASADriver;DataSnapServer;CustomIPTransport;bindcomp;dbxcds;dsnapxml;dbrtl;IndyProtocols;$(DCC_UsePackage) - - DBXSqliteDriver;tethering;FireDACMSSQLDriver;FireDACDBXDriver;RESTBackendComponents;bindengine;CloudService;FireDACMySQLDriver;DataSnapClient;bindcompdbx;IndyIPServer;IndySystem;fmxFireDAC;FireDACTDataDriver;FMXTee;soaprtl;DbxCommonDriver;xmlrtl;soapmidas;DataSnapNativeClient;fmxobj;rtl;DbxClientDriver;DBXSybaseASADriver;IndyIPClient;FireDACODBCDriver;DataSnapIndy10ServerTransport;DataSnapProviderClient;FireDACMongoDBDriver;RESTComponents;DataSnapServerMidas;DBXInterBaseDriver;emsclientfiredac;DataSnapFireDAC;bindcompfmx;DBXOracleDriver;inetdb;FmxTeeUI;fmx;FireDACIBDriver;fmxdae;dbexpress;IndyCore;dsnap;emsclient;DataSnapCommon;FireDACCommon;soapserver;FireDACOracleDriver;DBXMySQLDriver;DBXFirebirdDriver;FireDACCommonODBC;FireDACCommonDriver;inet;IndyIPCommon;FireDAC;FireDACSqliteDriver;FireDACPgDriver;FireDACASADriver;DataSnapServer;FireDACDSDriver;CustomIPTransport;bindcomp;DBXInformixDriver;dbxcds;dsnapxml;dbrtl;IndyProtocols;inetdbxpress;fmxase;$(DCC_UsePackage) - DBXSqliteDriver;DBXDb2Driver;vclactnband;vclFireDAC;tethering;FireDACADSDriver;cxLibraryRS27;JvPluginSystem;dxRibbonCustomizationFormRS27;FireDACMSSQLDriver;vcltouch;JvBands;vcldb;svn;dxPScxExtCommonRS27;JvJans;cxTreeListRS27;dxPScxSchedulerLnkRS27;JvDotNetCtrls;dxRichEditDocumentModelRS27;dxPsPrVwAdvRS27;FireDACDBXDriver;vclx;dxPSdxFCLnkRS27;dxSpellCheckerRS27;dxPDFViewerRS27;RESTBackendComponents;VCLRESTComponents;dxWizardControlRS27;cxSchedulerTreeBrowserRS27;vclie;bindengine;CloudService;dxBarExtDBItemsRS27;JvHMI;FireDACMySQLDriver;SVGIconPackage;cxExportRS27;DataSnapClient;cxSchedulerWebServiceStorageRS27;bindcompdbx;IndyIPServer;DBXSybaseASEDriver;dxPScxPCProdRS27;IndySystem;dxHttpIndyRequestRS27;bindcompvclwinx;dxFlowChartRS27;dsnapcon;FireDACMSAccDriver;fmxFireDAC;FireDACInfxDriver;vclimg;dxmdsRS27;dxPSPrVwRibbonRS27;Jcl;dxCoreRS27;emshosting;DBXOdbcDriver;FireDACTDataDriver;FMXTee;cxSchedulerRibbonStyleEventEditorRS27;soaprtl;DbxCommonDriver;dxRichEditCoreRS27;JvManagedThreads;dxCloudServiceLibraryRS27;xmlrtl;soapmidas;DataSnapNativeClient;fmxobj;JvTimeFramework;rtl;emsserverresource;DbxClientDriver;dxdborRS27;DBXSybaseASADriver;dxdbtrRS27;JvSystem;JvStdCtrls;dxPSDBTeeChartRS27;appanalytics;dxSpreadSheetCoreRS27;dxRichEditControlCoreRS27;dxGDIPlusRS27;IndyIPClient;dxFireDACServerModeRS27;dxFlowChartAdvancedCustomizeFormRS27;bindcompvcl;dxServerModeRS27;TeeUI;dxPSLnksRS27;dxorgcRS27;JvDocking;JvPascalInterpreter;VclSmp;dxDBXServerModeRS27;FireDACODBCDriver;JclVcl;DataSnapIndy10ServerTransport;cxGridRS27;DataSnapProviderClient;FireDACMongoDBDriver;dxFireDACEMFRS27;JvControls;JvPrintPreview;dxtrmdRS27;dxSpreadSheetCoreConditionalFormattingDialogsRS27;RESTComponents;DataSnapServerMidas;DBXInterBaseDriver;dxSpreadSheetConditionalFormattingDialogsRS27;dxGaugeControlRS27;dxSpreadSheetReportDesignerRS27;dxSpreadSheetRS27;bindcompvclsmp;emsclientfiredac;DataSnapFireDAC;svnui;dxPSRichEditControlLnkRS27;cxPivotGridOLAPRS27;dxBarDBNavRS27;JvGlobus;DBXMSSQLDriver;cxPivotGridRS27;dxADOServerModeRS27;JvMM;DatasnapConnectorsFreePascal;bindcompfmx;JvNet;DBXOracleDriver;inetdb;JvAppFrm;dxFlowChartDesignerRS27;FmxTeeUI;emsedge;fmx;FireDACIBDriver;fmxdae;vcledge;JvWizards;dbexpress;IndyCore;dxRibbonRS27;dxOrgChartAdvancedCustomizeFormRS27;JvPageComps;dsnap;emsclient;DataSnapCommon;SVGIconImageListFMX;FireDACCommon;JvDB;dxTileControlRS27;dxBarExtItemsRS27;DataSnapConnectors;cxSchedulerRS27;cxGridEMFRS27;soapserver;dxRichEditControlRS27;JclDeveloperTools;dxPScxTLLnkRS27;FireDACOracleDriver;DBXMySQLDriver;dxFlowChartLayoutsRS27;dxPSCoreRS27;dxADOEMFRS27;DBXFirebirdDriver;JvCmp;FireDACCommonODBC;FireDACCommonDriver;dxPScxPivotGridLnkRS27;inet;cxPivotGridChartRS27;IndyIPCommon;dxPSdxOCLnkRS27;JvCustom;vcl;JvXPCtrls;FireDACDb2Driver;dxPSdxDBOCLnkRS27;dxMapControlRS27;dxComnRS27;dxPSdxGaugeControlLnkRS27;dxEMFRS27;TeeDB;FireDAC;cxTreeListdxBarPopupMenuRS27;dxPScxVGridLnkRS27;dxPSdxPDFViewerLnkRS27;JvCore;dxPSdxSpreadSheetLnkRS27;JvCrypt;FireDACSqliteDriver;FireDACPgDriver;FireDACASADriver;dxTabbedMDIRS27;dxGanttControlRS27;JvDlgs;JvRuntimeDesign;Tee;DataSnapServer;vclwinx;FireDACDSDriver;dxPScxCommonRS27;CustomIPTransport;vcldsnap;dxPSTeeChartRS27;dxPScxGridLnkRS27;bindcomp;DBXInformixDriver;cxSchedulerGridRS27;cxVerticalGridRS27;dxDockingRS27;dxNavBarRS27;SVGIconImageList;dbxcds;adortl;dsnapxml;dbrtl;IndyProtocols;inetdbxpress;dxBarRS27;dxChartControlRS27;dxPSdxLCLnkRS27;dxPSdxMapControlLnkRS27;JclContainers;dxPSdxDBTVLnkRS27;fmxase;$(DCC_UsePackage) Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace) Debug true - FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 1033 $(BDS)\bin\default_app.manifest - 106 + 107 ..\documentation\icons\json2puml_icon.png ..\documentation\icons\json2puml_icon.png none 2 2 - 10 + 11 DBXSqliteDriver;DBXDb2Driver;vclactnband;vclFireDAC;tethering;FireDACADSDriver;cxLibraryRS27;dxRibbonCustomizationFormRS27;FireDACMSSQLDriver;vcltouch;vcldb;dxPScxExtCommonRS27;cxTreeListRS27;dxPScxSchedulerLnkRS27;dxRichEditDocumentModelRS27;dxPsPrVwAdvRS27;FireDACDBXDriver;vclx;dxPSdxFCLnkRS27;dxSpellCheckerRS27;dxPDFViewerRS27;RESTBackendComponents;VCLRESTComponents;dxWizardControlRS27;cxSchedulerTreeBrowserRS27;vclie;bindengine;CloudService;dxBarExtDBItemsRS27;FireDACMySQLDriver;SVGIconPackage;cxExportRS27;DataSnapClient;cxSchedulerWebServiceStorageRS27;bindcompdbx;IndyIPServer;DBXSybaseASEDriver;dxPScxPCProdRS27;IndySystem;dxHttpIndyRequestRS27;bindcompvclwinx;dxFlowChartRS27;dsnapcon;FireDACMSAccDriver;fmxFireDAC;FireDACInfxDriver;vclimg;dxmdsRS27;dxPSPrVwRibbonRS27;dxCoreRS27;emshosting;DBXOdbcDriver;FireDACTDataDriver;FMXTee;cxSchedulerRibbonStyleEventEditorRS27;soaprtl;DbxCommonDriver;dxRichEditCoreRS27;dxCloudServiceLibraryRS27;xmlrtl;soapmidas;DataSnapNativeClient;fmxobj;rtl;emsserverresource;DbxClientDriver;dxdborRS27;DBXSybaseASADriver;dxdbtrRS27;dxPSDBTeeChartRS27;appanalytics;dxSpreadSheetCoreRS27;dxRichEditControlCoreRS27;dxGDIPlusRS27;IndyIPClient;dxFireDACServerModeRS27;dxFlowChartAdvancedCustomizeFormRS27;bindcompvcl;dxServerModeRS27;TeeUI;dxPSLnksRS27;dxorgcRS27;VclSmp;dxDBXServerModeRS27;FireDACODBCDriver;DataSnapIndy10ServerTransport;cxGridRS27;DataSnapProviderClient;FireDACMongoDBDriver;dxFireDACEMFRS27;dxtrmdRS27;dxSpreadSheetCoreConditionalFormattingDialogsRS27;RESTComponents;DataSnapServerMidas;DBXInterBaseDriver;dxSpreadSheetConditionalFormattingDialogsRS27;dxGaugeControlRS27;dxSpreadSheetReportDesignerRS27;dxSpreadSheetRS27;bindcompvclsmp;emsclientfiredac;DataSnapFireDAC;dxPSRichEditControlLnkRS27;cxPivotGridOLAPRS27;dxBarDBNavRS27;DBXMSSQLDriver;cxPivotGridRS27;dxADOServerModeRS27;DatasnapConnectorsFreePascal;bindcompfmx;DBXOracleDriver;inetdb;dxFlowChartDesignerRS27;FmxTeeUI;emsedge;fmx;FireDACIBDriver;fmxdae;vcledge;dbexpress;IndyCore;dxRibbonRS27;dxOrgChartAdvancedCustomizeFormRS27;dsnap;emsclient;DataSnapCommon;SVGIconImageListFMX;FireDACCommon;dxTileControlRS27;dxBarExtItemsRS27;DataSnapConnectors;cxSchedulerRS27;cxGridEMFRS27;soapserver;dxRichEditControlRS27;dxPScxTLLnkRS27;FireDACOracleDriver;DBXMySQLDriver;dxFlowChartLayoutsRS27;dxPSCoreRS27;dxADOEMFRS27;DBXFirebirdDriver;FireDACCommonODBC;FireDACCommonDriver;dxPScxPivotGridLnkRS27;inet;cxPivotGridChartRS27;IndyIPCommon;dxPSdxOCLnkRS27;vcl;FireDACDb2Driver;dxPSdxDBOCLnkRS27;dxMapControlRS27;dxComnRS27;dxPSdxGaugeControlLnkRS27;dxEMFRS27;TeeDB;FireDAC;cxTreeListdxBarPopupMenuRS27;dxPScxVGridLnkRS27;dxPSdxPDFViewerLnkRS27;dxPSdxSpreadSheetLnkRS27;FireDACSqliteDriver;FireDACPgDriver;FireDACASADriver;dxTabbedMDIRS27;dxGanttControlRS27;Tee;DataSnapServer;vclwinx;FireDACDSDriver;dxPScxCommonRS27;CustomIPTransport;vcldsnap;dxPSTeeChartRS27;dxPScxGridLnkRS27;bindcomp;DBXInformixDriver;cxSchedulerGridRS27;cxVerticalGridRS27;dxDockingRS27;dxNavBarRS27;SVGIconImageList;dbxcds;adortl;dsnapxml;dbrtl;IndyProtocols;inetdbxpress;dxBarRS27;dxChartControlRS27;dxPSdxLCLnkRS27;dxPSdxMapControlLnkRS27;dxPSdxDBTVLnkRS27;fmxase;$(DCC_UsePackage) Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;$(DCC_Namespace) Debug true - FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 1033 $(BDS)\bin\default_app.manifest - 106 + 107 ..\documentation\icons\json2puml_icon.png ..\documentation\icons\json2puml_icon.png none 2 2 - 10 + 11 DEBUG;$(DCC_Define) @@ -132,22 +124,22 @@ false true PerMonitorV2 - FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 - 106 + FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + 107 2 2 - 10 + 11 PerMonitorV2 - 106 - FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + 107 + FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 2 true 1033 /install 2 - 10 + 11 madExcept;LeakChecking;$(DCC_Define) @@ -159,20 +151,20 @@ true PerMonitorV2 - FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 - 106 + FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + 107 2 2 - 10 + 11 true PerMonitorV2 - FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.10.106;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 - 106 + FileDescription=$(MSBuildProjectName) Windows Service;FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=2.0;CompanyName=SWE Jens Fudickar;LegalCopyright=(c) by Jens Fudickar in 2023 + 107 2 2 - 10 + 11 @@ -180,7 +172,6 @@
J2PWinService
- dfm TService
@@ -331,6 +322,16 @@ 1
+ + + res\drawable-anydpi-v21 + 1 + + + res\drawable-anydpi-v21 + 1 + + res\values @@ -351,6 +352,66 @@ 1 + + + res\values-v31 + 1 + + + res\values-v31 + 1 + + + + + res\drawable-anydpi-v26 + 1 + + + res\drawable-anydpi-v26 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-anydpi-v33 + 1 + + + res\drawable-anydpi-v33 + 1 + + res\values @@ -361,6 +422,16 @@ 1 + + + res\values-night-v21 + 1 + + + res\values-night-v21 + 1 + + res\drawable @@ -531,6 +602,56 @@ 1 + + + res\drawable-anydpi-v24 + 1 + + + res\drawable-anydpi-v24 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-night-anydpi-v21 + 1 + + + res\drawable-night-anydpi-v21 + 1 + + + + + res\drawable-anydpi-v31 + 1 + + + res\drawable-anydpi-v31 + 1 + + + + + res\drawable-night-anydpi-v31 + 1 + + + res\drawable-night-anydpi-v31 + 1 + + 1 @@ -1067,7 +1188,6 @@ False - False True True diff --git a/source/json2pumlwindowsservice.res b/source/json2pumlwindowsservice.res index e3a066a..04924e7 100644 Binary files a/source/json2pumlwindowsservice.res and b/source/json2pumlwindowsservice.res differ diff --git a/unittests/.gitignore b/unittests/.gitignore new file mode 100644 index 0000000..f0c719b --- /dev/null +++ b/unittests/.gitignore @@ -0,0 +1,27 @@ +# IDE files +*.~* +*.local +*.identcache +__history +__recovery +*.stat +*.tvsconfig + +# Delphi Compiler output files +*.drc +*.map +*.jdbg +*.tds +*.exe +*.dll +*.bpl +*.dcu +*.dcp +*.o +*. +*.dsk + +# Output Folder +/Win32 +/Win64 +/Linux64 diff --git a/unittests/json2pumlunittests.dpr b/unittests/json2pumlunittests.dpr new file mode 100644 index 0000000..d84a9b9 --- /dev/null +++ b/unittests/json2pumlunittests.dpr @@ -0,0 +1,70 @@ +program json2pumlunittests; + +{$IFNDEF TESTINSIGHT} +{$APPTYPE CONSOLE} +{$ENDIF} +{$STRONGLINKTYPES ON} +uses + System.SysUtils, + {$IFDEF TESTINSIGHT} + TestInsight.DUnitX, + {$ELSE} + DUnitX.Loggers.Console, + DUnitX.Loggers.Xml.NUnit, + {$ENDIF } + DUnitX.TestFramework, + ut.Json2PumlBasePropertyList in 'ut.Json2PumlBasePropertyList.pas', + uttJson2PumlFormatDefinition in 'uttJson2PumlFormatDefinition.pas'; + +{ keep comment here to protect the following conditional from being removed by the IDE when adding a unit } +{$IFNDEF TESTINSIGHT} +var + runner: ITestRunner; + results: IRunResults; + logger: ITestLogger; + nunitLogger : ITestLogger; +{$ENDIF} +begin +{$IFDEF TESTINSIGHT} + TestInsight.DUnitX.RunRegisteredTests; +{$ELSE} + try + //Check command line options, will exit if invalid + TDUnitX.CheckCommandLine; + //Create the test runner + runner := TDUnitX.CreateRunner; + //Tell the runner to use RTTI to find Fixtures + runner.UseRTTI := True; + //When true, Assertions must be made during tests; + runner.FailsOnNoAsserts := False; + + //tell the runner how we will log things + //Log to the console window if desired + if TDUnitX.Options.ConsoleMode <> TDunitXConsoleMode.Off then + begin + logger := TDUnitXConsoleLogger.Create(TDUnitX.Options.ConsoleMode = TDunitXConsoleMode.Quiet); + runner.AddLogger(logger); + end; + //Generate an NUnit compatible XML File + nunitLogger := TDUnitXXMLNUnitFileLogger.Create(TDUnitX.Options.XMLOutputFile); + runner.AddLogger(nunitLogger); + + //Run tests + results := runner.Execute; + if not results.AllPassed then + System.ExitCode := EXIT_ERRORS; + + {$IFNDEF CI} + //We don't want this happening when running under CI. + if TDUnitX.Options.ExitBehavior = TDUnitXExitBehavior.Pause then + begin + System.Write('Done.. press key to quit.'); + System.Readln; + end; + {$ENDIF} + except + on E: Exception do + System.Writeln(E.ClassName, ': ', E.Message); + end; +{$ENDIF} +end. diff --git a/unittests/json2pumlunittests.dproj b/unittests/json2pumlunittests.dproj new file mode 100644 index 0000000..4b6ce6a --- /dev/null +++ b/unittests/json2pumlunittests.dproj @@ -0,0 +1,1111 @@ + + + {595542D7-A413-494E-9908-FD18F01B3535} + 20.1 + None + True + Debug + Win32 + 1 + Console + json2pumlunittests.dpr + + + true + + + true + Base + true + + + true + Base + true + + + true + Base + true + + + true + Base + true + + + true + Cfg_1 + true + true + + + true + Base + true + + + .\$(Platform)\$(Config) + .\$(Platform)\$(Config) + false + false + false + false + false + System;Xml;Data;Datasnap;Web;Soap;$(DCC_Namespace) + true + $(BDS)\bin\delphi_PROJECTICON.ico + $(BDS)\bin\delphi_PROJECTICNS.icns + ..\source;$(DUnitX);$(DCC_UnitSearchPath) + json2pumlunittests + 1031 + CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments= + + + DataSnapServer;fmx;DbxCommonDriver;bindengine;FireDACCommonODBC;emsclient;IndyProtocols;dbxcds;FireDACSqliteDriver;DbxClientDriver;soapmidas;dbexpress;inet;CustomIPTransport;FireDACMSSQLDriver;IndySystem;FireDACCommon;DataSnapServerMidas;FireDACODBCDriver;emsserverresource;rtl;FireDACMySQLDriver;DataSnapFireDAC;FireDAC;xmlrtl;dsnap;FireDACDb2Driver;DataSnapNativeClient;DatasnapConnectorsFreePascal;emshosting;FireDACCommonDriver;emsedge;inetdb;FireDACASADriver;FireDACInfxDriver;DataSnapCommon;dbrtl;FireDACOracleDriver;DataSnapIndy10ServerTransport;DataSnapConnectors;FireDACMongoDBDriver;FireDACTDataDriver;bindcomp;IndyCore;RESTBackendComponents;FireDACADSDriver;RESTComponents;dsnapxml;DataSnapClient;emsclientfiredac;FireDACPgDriver;CloudService;soaprtl;soapserver;FireDACIBDriver;$(DCC_UsePackage) + + + JvNet;vclwinx;DataSnapServer;fmx;vclie;DbxCommonDriver;bindengine;IndyIPCommon;VCLRESTComponents;DBXMSSQLDriver;FireDACCommonODBC;emsclient;appanalytics;IndyProtocols;vclx;Skia.Package.RTL;dbxcds;vcledge;FmxTeeUI;DBXFirebirdDriver;JvAppFrm;FireDACSqliteDriver;DbxClientDriver;JclVcl;soapmidas;TeeUI;Jcl;dbexpress;JvManagedThreads;inet;vcltouch;JvDB;FireDACDBXDriver;fmxdae;JvCustom;CustomIPTransport;FireDACMSSQLDriver;JvSystem;JvControls;JvCrypt;JvJans;JvMM;IndySystem;JvGlobus;JclContainers;JvPageComps;vclFireDAC;FireDACCommon;DataSnapServerMidas;FireDACODBCDriver;emsserverresource;bindcompdbx;rtl;FireDACMySQLDriver;DBXSqliteDriver;DBXSybaseASEDriver;JvRuntimeDesign;JvXPCtrls;vclimg;DataSnapFireDAC;inetdbxpress;FireDAC;JvDocking;JvDlgs;xmlrtl;dsnap;JvCmp;FireDACDb2Driver;DBXOracleDriver;DBXInformixDriver;fmxobj;bindcompvclsmp;DataSnapNativeClient;DatasnapConnectorsFreePascal;emshosting;FireDACCommonDriver;IndyIPClient;bindcompvclwinx;emsedge;bindcompfmx;madBasic_;JvBands;inetdb;FireDACASADriver;Tee;vclactnband;fmxFireDAC;FireDACInfxDriver;DBXMySQLDriver;VclSmp;DataSnapCommon;JvPascalInterpreter;fmxase;JvPluginSystem;DBXOdbcDriver;JvTimeFramework;dbrtl;FireDACOracleDriver;Skia.Package.FMX;TeeDB;FireDACMSAccDriver;DataSnapIndy10ServerTransport;JclDeveloperTools;DataSnapConnectors;vcldsnap;DBXInterBaseDriver;FireDACMongoDBDriver;JvWizards;FireDACTDataDriver;Skia.Package.VCL;vcldb;SynEditDR;JvCore;bindcomp;IndyCore;RESTBackendComponents;FireDACADSDriver;RESTComponents;IndyIPServer;vcl;dsnapxml;adortl;dsnapcon;DataSnapClient;DataSnapProviderClient;JvDotNetCtrls;JvHMI;DBXDb2Driver;emsclientfiredac;FireDACPgDriver;FireDACDSDriver;JvPrintPreview;tethering;JvStdCtrls;bindcompvcl;CloudService;DBXSybaseASADriver;FMXTee;soaprtl;soapserver;FireDACIBDriver;$(DCC_UsePackage) + Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace) + Debug + CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments= + 1033 + + + vclwinx;DataSnapServer;fmx;vclie;DbxCommonDriver;bindengine;IndyIPCommon;VCLRESTComponents;DBXMSSQLDriver;FireDACCommonODBC;emsclient;appanalytics;IndyProtocols;vclx;dbxcds;vcledge;FmxTeeUI;DBXFirebirdDriver;FireDACSqliteDriver;DbxClientDriver;soapmidas;TeeUI;dbexpress;inet;vcltouch;FireDACDBXDriver;fmxdae;CustomIPTransport;FireDACMSSQLDriver;IndySystem;vclFireDAC;FireDACCommon;DataSnapServerMidas;FireDACODBCDriver;emsserverresource;bindcompdbx;rtl;FireDACMySQLDriver;DBXSqliteDriver;DBXSybaseASEDriver;vclimg;DataSnapFireDAC;inetdbxpress;FireDAC;xmlrtl;dsnap;FireDACDb2Driver;DBXOracleDriver;DBXInformixDriver;fmxobj;bindcompvclsmp;DataSnapNativeClient;DatasnapConnectorsFreePascal;emshosting;FireDACCommonDriver;IndyIPClient;bindcompvclwinx;emsedge;bindcompfmx;inetdb;FireDACASADriver;Tee;vclactnband;fmxFireDAC;FireDACInfxDriver;DBXMySQLDriver;VclSmp;DataSnapCommon;fmxase;DBXOdbcDriver;dbrtl;FireDACOracleDriver;TeeDB;FireDACMSAccDriver;DataSnapIndy10ServerTransport;DataSnapConnectors;vcldsnap;DBXInterBaseDriver;FireDACMongoDBDriver;FireDACTDataDriver;Skia.Package.VCL;vcldb;SynEditDR;bindcomp;IndyCore;RESTBackendComponents;FireDACADSDriver;RESTComponents;IndyIPServer;vcl;dsnapxml;adortl;dsnapcon;DataSnapClient;DataSnapProviderClient;DBXDb2Driver;emsclientfiredac;FireDACPgDriver;FireDACDSDriver;tethering;bindcompvcl;CloudService;DBXSybaseASADriver;FMXTee;soaprtl;soapserver;FireDACIBDriver;$(DCC_UsePackage) + + + DEBUG;$(DCC_Define) + true + false + true + true + true + true + true + + + false + -exit:pause + 1033 + (None) + none + + + false + RELEASE;$(DCC_Define) + 0 + 0 + + + + MainSource + + + + + Base + + + Cfg_1 + Base + + + Cfg_2 + Base + + + + Delphi.Personality.12 + Application + + + + json2pumlunittests.dpr + + + Microsoft Office 2000 Sample Automation Server Wrapper Components + Microsoft Office XP Sample Automation Server Wrapper Components + + + + + + true + + + + + true + + + + + true + + + + + json2pumlunittests.exe + true + + + + + 1 + + + Contents\MacOS + 1 + + + 0 + + + + + classes + 64 + + + classes + 64 + + + + + res\xml + 1 + + + res\xml + 1 + + + + + library\lib\armeabi + 1 + + + library\lib\armeabi + 1 + + + + + library\lib\armeabi-v7a + 1 + + + + + library\lib\mips + 1 + + + library\lib\mips + 1 + + + + + library\lib\armeabi-v7a + 1 + + + library\lib\arm64-v8a + 1 + + + + + library\lib\armeabi-v7a + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-anydpi-v21 + 1 + + + res\drawable-anydpi-v21 + 1 + + + + + res\values + 1 + + + res\values + 1 + + + + + res\values-v21 + 1 + + + res\values-v21 + 1 + + + + + res\values-v31 + 1 + + + res\values-v31 + 1 + + + + + res\drawable-anydpi-v26 + 1 + + + res\drawable-anydpi-v26 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-anydpi-v33 + 1 + + + res\drawable-anydpi-v33 + 1 + + + + + res\values + 1 + + + res\values + 1 + + + + + res\values-night-v21 + 1 + + + res\values-night-v21 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-xxhdpi + 1 + + + res\drawable-xxhdpi + 1 + + + + + res\drawable-xxxhdpi + 1 + + + res\drawable-xxxhdpi + 1 + + + + + res\drawable-ldpi + 1 + + + res\drawable-ldpi + 1 + + + + + res\drawable-mdpi + 1 + + + res\drawable-mdpi + 1 + + + + + res\drawable-hdpi + 1 + + + res\drawable-hdpi + 1 + + + + + res\drawable-xhdpi + 1 + + + res\drawable-xhdpi + 1 + + + + + res\drawable-mdpi + 1 + + + res\drawable-mdpi + 1 + + + + + res\drawable-hdpi + 1 + + + res\drawable-hdpi + 1 + + + + + res\drawable-xhdpi + 1 + + + res\drawable-xhdpi + 1 + + + + + res\drawable-xxhdpi + 1 + + + res\drawable-xxhdpi + 1 + + + + + res\drawable-xxxhdpi + 1 + + + res\drawable-xxxhdpi + 1 + + + + + res\drawable-small + 1 + + + res\drawable-small + 1 + + + + + res\drawable-normal + 1 + + + res\drawable-normal + 1 + + + + + res\drawable-large + 1 + + + res\drawable-large + 1 + + + + + res\drawable-xlarge + 1 + + + res\drawable-xlarge + 1 + + + + + res\values + 1 + + + res\values + 1 + + + + + res\drawable-anydpi-v24 + 1 + + + res\drawable-anydpi-v24 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-night-anydpi-v21 + 1 + + + res\drawable-night-anydpi-v21 + 1 + + + + + res\drawable-anydpi-v31 + 1 + + + res\drawable-anydpi-v31 + 1 + + + + + res\drawable-night-anydpi-v31 + 1 + + + res\drawable-night-anydpi-v31 + 1 + + + + + 1 + + + Contents\MacOS + 1 + + + 0 + + + + + Contents\MacOS + 1 + .framework + + + Contents\MacOS + 1 + .framework + + + Contents\MacOS + 1 + .framework + + + 0 + + + + + 1 + .dylib + + + 1 + .dylib + + + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + 0 + .dll;.bpl + + + + + 1 + .dylib + + + 1 + .dylib + + + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + 0 + .bpl + + + + + 0 + + + 0 + + + 0 + + + 0 + + + 0 + + + Contents\Resources\StartUp\ + 0 + + + Contents\Resources\StartUp\ + 0 + + + Contents\Resources\StartUp\ + 0 + + + 0 + + + + + 1 + + + 1 + + + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + + + ..\ + 1 + + + ..\ + 1 + + + ..\ + 1 + + + + + Contents + 1 + + + Contents + 1 + + + Contents + 1 + + + + + Contents\Resources + 1 + + + Contents\Resources + 1 + + + Contents\Resources + 1 + + + + + library\lib\armeabi-v7a + 1 + + + library\lib\arm64-v8a + 1 + + + 1 + + + 1 + + + 1 + + + 1 + + + Contents\MacOS + 1 + + + Contents\MacOS + 1 + + + Contents\MacOS + 1 + + + 0 + + + + + library\lib\armeabi-v7a + 1 + + + + + 1 + + + 1 + + + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + + + ..\ + 1 + + + ..\ + 1 + + + ..\ + 1 + + + + + 1 + + + 1 + + + 1 + + + + + ..\$(PROJECTNAME).launchscreen + 64 + + + ..\$(PROJECTNAME).launchscreen + 64 + + + + + 1 + + + 1 + + + 1 + + + + + Assets + 1 + + + Assets + 1 + + + + + Assets + 1 + + + Assets + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + + + + + + + + + + + + False + True + False + + + 12 + + + + + diff --git a/unittests/json2pumlunittests.res b/unittests/json2pumlunittests.res new file mode 100644 index 0000000..70c5630 Binary files /dev/null and b/unittests/json2pumlunittests.res differ diff --git a/unittests/json2pumlunittestsui.dpr b/unittests/json2pumlunittestsui.dpr new file mode 100644 index 0000000..915589a --- /dev/null +++ b/unittests/json2pumlunittestsui.dpr @@ -0,0 +1,17 @@ +program json2pumlunittestsui; + +uses + Vcl.Forms, + DUnitX.Loggers.GUI.Vcl {GUIVCLTestRunner}, + ut.Json2PumlBasePropertyList in 'ut.Json2PumlBasePropertyList.pas', + uttJson2PumlFormatDefinition in 'uttJson2PumlFormatDefinition.pas'; + +{$R *.res} + +begin + Application.Initialize; + Application.MainFormOnTaskbar := True; + Application.CreateForm(TGUIVCLTestRunner, GUIVCLTestRunner); + Application.Run; + +end. diff --git a/unittests/json2pumlunittestsui.dproj b/unittests/json2pumlunittestsui.dproj new file mode 100644 index 0000000..5845aa7 --- /dev/null +++ b/unittests/json2pumlunittestsui.dproj @@ -0,0 +1,1149 @@ + + + {2224B0B3-7396-4D22-9E89-0E91847677C8} + 20.1 + VCL + True + Debug + Win32 + 3 + Application + json2pumlunittestsui.dpr + + + true + + + true + Base + true + + + true + Base + true + + + true + Base + true + + + true + Cfg_1 + true + true + + + true + Cfg_1 + true + true + + + true + Base + true + + + true + Cfg_2 + true + true + + + true + Cfg_2 + true + true + + + .\$(Platform)\$(Config) + .\$(Platform)\$(Config) + false + false + false + false + false + System;Xml;Data;Datasnap;Web;Soap;Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;$(DCC_Namespace) + $(BDS)\bin\delphi_PROJECTICON.ico + $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_44.png + $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_150.png + json2pumlunittestsui + ..\source;$(DUnitX);c:\Program Files (x86)\Embarcadero\Studio\23.0\source\DunitX\;$(DCC_UnitSearchPath) + 1031 + CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments= + + + JvNet;vclwinx;DataSnapServer;fmx;vclie;DbxCommonDriver;bindengine;IndyIPCommon;VCLRESTComponents;DBXMSSQLDriver;FireDACCommonODBC;emsclient;appanalytics;IndyProtocols;vclx;Skia.Package.RTL;dbxcds;vcledge;FmxTeeUI;DBXFirebirdDriver;JvAppFrm;FireDACSqliteDriver;DbxClientDriver;JclVcl;soapmidas;TeeUI;Jcl;dbexpress;JvManagedThreads;inet;vcltouch;JvDB;FireDACDBXDriver;fmxdae;JvCustom;CustomIPTransport;FireDACMSSQLDriver;JvSystem;JvControls;JvCrypt;JvJans;JvMM;IndySystem;JvGlobus;JclContainers;JvPageComps;vclFireDAC;FireDACCommon;DataSnapServerMidas;FireDACODBCDriver;emsserverresource;bindcompdbx;rtl;FireDACMySQLDriver;DBXSqliteDriver;DBXSybaseASEDriver;JvRuntimeDesign;JvXPCtrls;vclimg;DataSnapFireDAC;inetdbxpress;FireDAC;JvDocking;JvDlgs;xmlrtl;dsnap;JvCmp;FireDACDb2Driver;DBXOracleDriver;DBXInformixDriver;fmxobj;bindcompvclsmp;DataSnapNativeClient;DatasnapConnectorsFreePascal;emshosting;FireDACCommonDriver;IndyIPClient;bindcompvclwinx;emsedge;bindcompfmx;madBasic_;JvBands;inetdb;FireDACASADriver;Tee;vclactnband;fmxFireDAC;FireDACInfxDriver;DBXMySQLDriver;VclSmp;DataSnapCommon;JvPascalInterpreter;fmxase;JvPluginSystem;DBXOdbcDriver;JvTimeFramework;dbrtl;FireDACOracleDriver;Skia.Package.FMX;TeeDB;FireDACMSAccDriver;DataSnapIndy10ServerTransport;JclDeveloperTools;DataSnapConnectors;vcldsnap;DBXInterBaseDriver;FireDACMongoDBDriver;JvWizards;FireDACTDataDriver;Skia.Package.VCL;vcldb;SynEditDR;JvCore;bindcomp;IndyCore;RESTBackendComponents;FireDACADSDriver;RESTComponents;IndyIPServer;vcl;dsnapxml;adortl;dsnapcon;DataSnapClient;DataSnapProviderClient;JvDotNetCtrls;JvHMI;DBXDb2Driver;emsclientfiredac;FireDACPgDriver;FireDACDSDriver;JvPrintPreview;tethering;JvStdCtrls;bindcompvcl;CloudService;DBXSybaseASADriver;FMXTee;soaprtl;soapserver;FireDACIBDriver;$(DCC_UsePackage) + Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace) + Debug + true + FileDescription=$(MSBuildProjectName);FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0 + 1033 + $(BDS)\bin\default_app.manifest + 2 + 2 + 11 + 107 + + + vclwinx;DataSnapServer;fmx;vclie;DbxCommonDriver;bindengine;IndyIPCommon;VCLRESTComponents;DBXMSSQLDriver;FireDACCommonODBC;emsclient;appanalytics;IndyProtocols;vclx;dbxcds;vcledge;FmxTeeUI;DBXFirebirdDriver;FireDACSqliteDriver;DbxClientDriver;soapmidas;TeeUI;dbexpress;inet;vcltouch;FireDACDBXDriver;fmxdae;CustomIPTransport;FireDACMSSQLDriver;IndySystem;vclFireDAC;FireDACCommon;DataSnapServerMidas;FireDACODBCDriver;emsserverresource;bindcompdbx;rtl;FireDACMySQLDriver;DBXSqliteDriver;DBXSybaseASEDriver;vclimg;DataSnapFireDAC;inetdbxpress;FireDAC;xmlrtl;dsnap;FireDACDb2Driver;DBXOracleDriver;DBXInformixDriver;fmxobj;bindcompvclsmp;DataSnapNativeClient;DatasnapConnectorsFreePascal;emshosting;FireDACCommonDriver;IndyIPClient;bindcompvclwinx;emsedge;bindcompfmx;inetdb;FireDACASADriver;Tee;vclactnband;fmxFireDAC;FireDACInfxDriver;DBXMySQLDriver;VclSmp;DataSnapCommon;fmxase;DBXOdbcDriver;dbrtl;FireDACOracleDriver;TeeDB;FireDACMSAccDriver;DataSnapIndy10ServerTransport;DataSnapConnectors;vcldsnap;DBXInterBaseDriver;FireDACMongoDBDriver;FireDACTDataDriver;Skia.Package.VCL;vcldb;SynEditDR;bindcomp;IndyCore;RESTBackendComponents;FireDACADSDriver;RESTComponents;IndyIPServer;vcl;dsnapxml;adortl;dsnapcon;DataSnapClient;DataSnapProviderClient;DBXDb2Driver;emsclientfiredac;FireDACPgDriver;FireDACDSDriver;tethering;bindcompvcl;CloudService;DBXSybaseASADriver;FMXTee;soaprtl;soapserver;FireDACIBDriver;$(DCC_UsePackage) + Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;$(DCC_Namespace) + Debug + true + FileDescription=$(MSBuildProjectName);FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0 + 1033 + $(BDS)\bin\default_app.manifest + 2 + 2 + 11 + 107 + + + DEBUG;$(DCC_Define) + true + false + true + true + true + true + true + + + false + PerMonitorV2 + true + 1033 + 2 + 2 + 11 + FileDescription=$(MSBuildProjectName);FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0 + 107 + + + PerMonitorV2 + 2 + 2 + 11 + FileDescription=$(MSBuildProjectName);FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0 + 107 + + + false + RELEASE;$(DCC_Define) + 0 + 0 + + + PerMonitorV2 + 2 + 2 + 11 + FileDescription=$(MSBuildProjectName);FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0 + 107 + + + PerMonitorV2 + 2 + 2 + 11 + FileDescription=$(MSBuildProjectName);FileVersion=2.2.11.107;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0 + 107 + + + + MainSource + + + + + Base + + + Cfg_1 + Base + + + Cfg_2 + Base + + + + Delphi.Personality.12 + Application + + + + json2pumlunittestsui.dpr + + + Microsoft Office 2000 Sample Automation Server Wrapper Components + Microsoft Office XP Sample Automation Server Wrapper Components + + + + + + json2pumlunittestsui.exe + true + + + + + 1 + + + Contents\MacOS + 1 + + + 0 + + + + + classes + 64 + + + classes + 64 + + + + + res\xml + 1 + + + res\xml + 1 + + + + + library\lib\armeabi + 1 + + + library\lib\armeabi + 1 + + + + + library\lib\armeabi-v7a + 1 + + + + + library\lib\mips + 1 + + + library\lib\mips + 1 + + + + + library\lib\armeabi-v7a + 1 + + + library\lib\arm64-v8a + 1 + + + + + library\lib\armeabi-v7a + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-anydpi-v21 + 1 + + + res\drawable-anydpi-v21 + 1 + + + + + res\values + 1 + + + res\values + 1 + + + + + res\values-v21 + 1 + + + res\values-v21 + 1 + + + + + res\values-v31 + 1 + + + res\values-v31 + 1 + + + + + res\drawable-anydpi-v26 + 1 + + + res\drawable-anydpi-v26 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-anydpi-v33 + 1 + + + res\drawable-anydpi-v33 + 1 + + + + + res\values + 1 + + + res\values + 1 + + + + + res\values-night-v21 + 1 + + + res\values-night-v21 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-xxhdpi + 1 + + + res\drawable-xxhdpi + 1 + + + + + res\drawable-xxxhdpi + 1 + + + res\drawable-xxxhdpi + 1 + + + + + res\drawable-ldpi + 1 + + + res\drawable-ldpi + 1 + + + + + res\drawable-mdpi + 1 + + + res\drawable-mdpi + 1 + + + + + res\drawable-hdpi + 1 + + + res\drawable-hdpi + 1 + + + + + res\drawable-xhdpi + 1 + + + res\drawable-xhdpi + 1 + + + + + res\drawable-mdpi + 1 + + + res\drawable-mdpi + 1 + + + + + res\drawable-hdpi + 1 + + + res\drawable-hdpi + 1 + + + + + res\drawable-xhdpi + 1 + + + res\drawable-xhdpi + 1 + + + + + res\drawable-xxhdpi + 1 + + + res\drawable-xxhdpi + 1 + + + + + res\drawable-xxxhdpi + 1 + + + res\drawable-xxxhdpi + 1 + + + + + res\drawable-small + 1 + + + res\drawable-small + 1 + + + + + res\drawable-normal + 1 + + + res\drawable-normal + 1 + + + + + res\drawable-large + 1 + + + res\drawable-large + 1 + + + + + res\drawable-xlarge + 1 + + + res\drawable-xlarge + 1 + + + + + res\values + 1 + + + res\values + 1 + + + + + res\drawable-anydpi-v24 + 1 + + + res\drawable-anydpi-v24 + 1 + + + + + res\drawable + 1 + + + res\drawable + 1 + + + + + res\drawable-night-anydpi-v21 + 1 + + + res\drawable-night-anydpi-v21 + 1 + + + + + res\drawable-anydpi-v31 + 1 + + + res\drawable-anydpi-v31 + 1 + + + + + res\drawable-night-anydpi-v31 + 1 + + + res\drawable-night-anydpi-v31 + 1 + + + + + 1 + + + Contents\MacOS + 1 + + + 0 + + + + + Contents\MacOS + 1 + .framework + + + Contents\MacOS + 1 + .framework + + + Contents\MacOS + 1 + .framework + + + 0 + + + + + 1 + .dylib + + + 1 + .dylib + + + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + 0 + .dll;.bpl + + + + + 1 + .dylib + + + 1 + .dylib + + + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + Contents\MacOS + 1 + .dylib + + + 0 + .bpl + + + + + 0 + + + 0 + + + 0 + + + 0 + + + 0 + + + Contents\Resources\StartUp\ + 0 + + + Contents\Resources\StartUp\ + 0 + + + Contents\Resources\StartUp\ + 0 + + + 0 + + + + + 1 + + + 1 + + + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + + + ..\ + 1 + + + ..\ + 1 + + + ..\ + 1 + + + + + Contents + 1 + + + Contents + 1 + + + Contents + 1 + + + + + Contents\Resources + 1 + + + Contents\Resources + 1 + + + Contents\Resources + 1 + + + + + library\lib\armeabi-v7a + 1 + + + library\lib\arm64-v8a + 1 + + + 1 + + + 1 + + + 1 + + + 1 + + + Contents\MacOS + 1 + + + Contents\MacOS + 1 + + + Contents\MacOS + 1 + + + 0 + + + + + library\lib\armeabi-v7a + 1 + + + + + 1 + + + 1 + + + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + ..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF + 1 + + + + + ..\ + 1 + + + ..\ + 1 + + + ..\ + 1 + + + + + 1 + + + 1 + + + 1 + + + + + ..\$(PROJECTNAME).launchscreen + 64 + + + ..\$(PROJECTNAME).launchscreen + 64 + + + + + 1 + + + 1 + + + 1 + + + + + Assets + 1 + + + Assets + 1 + + + + + Assets + 1 + + + Assets + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + ..\$(PROJECTNAME).launchscreen\Assets\AppIcon.appiconset + 1 + + + + + + + + + + + + + + + + True + True + + + 12 + + + + + diff --git a/unittests/json2pumlunittestsui.res b/unittests/json2pumlunittestsui.res new file mode 100644 index 0000000..733980c Binary files /dev/null and b/unittests/json2pumlunittestsui.res differ diff --git a/unittests/ut.Json2PumlBasePropertyList.pas b/unittests/ut.Json2PumlBasePropertyList.pas new file mode 100644 index 0000000..a15b5a8 --- /dev/null +++ b/unittests/ut.Json2PumlBasePropertyList.pas @@ -0,0 +1,128 @@ +unit ut.Json2PumlBasePropertyList; + +interface + +uses + DUnitX.TestFramework, json2pumldefinition, json2pumlbasedefinition; + +type + + [TestFixture] + tJson2PumlBasePropertyListTest = class + private + FPropertyList: tJson2PumlBasePropertyList; + + procedure IndexOfProperty(iPropertyName, iParentPropertyName, iParentObjectType: string; iUseMatch: boolean; const + iResultName: String); + + public + [Setup] + procedure Setup; + + [TearDown] + procedure TearDown; + + [Test] + [Category('Exact')] + [TestCase('x', 'x,,')] + [TestCase('product', 'product,,product')] + [TestCase('productList', 'productList,,')] + [TestCase('order', 'order,,order=value')] + [TestCase('test.order', 'order,test,order=value')] + [TestCase('product.price', 'price,product,product.price')] + [TestCase('product.item', 'item,product,product.item')] + [TestCase('order.item', 'item,order,item')] + [TestCase('amount', 'amount,,')] + [TestCase('product.amount', 'amount,product,product.amount')] + [TestCase('charge', 'charge,,')] + [TestCase('product.charge', 'charge,product,')] + [TestCase('productlist.amount', 'amount,productlist,')] + procedure TestIndexOfPropertyExact(const iPropertyName, iParentPropertyName, iResultName: String); + [Category('Match')] + [TestCase('x', 'x,,')] + [TestCase('product', 'product,,product')] + [TestCase('productList', 'productList,,')] + [TestCase('order', 'order,,order=value')] + [TestCase('test.order', 'order,test,order=value')] + [TestCase('product.price', 'price,product,product.price')] + [TestCase('product.item', 'item,product,product.item')] + [TestCase('order.item', 'item,order,item')] + [TestCase('amount', 'amount,,')] + [TestCase('product.amount', 'amount,product,product.amount')] + [TestCase('charge', 'charge,,')] + [TestCase('product.charge', 'charge,product,product*.*')] + [TestCase('productlist.amount', 'amount,productlist,')] + [TestCase('productOffering', 'productOffering,,')] + procedure TestIndexOfPropertyMatch(const iPropertyName, iParentPropertyName, iResultName: String); + + property PropertyList: tJson2PumlBasePropertyList read FPropertyList + write FPropertyList; + end; + +implementation + +type + tJson2PumlBasePropertyListAccess = class(tJson2PumlBasePropertyList); + +procedure tJson2PumlBasePropertyListTest.IndexOfProperty(iPropertyName, iParentPropertyName, iParentObjectType: string; + iUseMatch: boolean; const iResultName: String); +Var + Index: Integer; + ResultName : String; + FoundCondition: String; +begin + PropertyList.UseMatch := iUseMatch; + Index := tJson2PumlBasePropertyListAccess(PropertyList) + .IndexOfProperty(iPropertyName, iParentPropertyName, iParentObjectType, + FoundCondition); + if Index >= 0 then + ResultName := PropertyList[Index] + else + ResultName := ''; + Assert.AreEqual(iResultName, ResultName, FoundCondition); + Assert.IsNotEmpty(FoundCondition, 'FoundCondition'); + Assert.Pass(FoundCondition); +end; + +procedure tJson2PumlBasePropertyListTest.Setup; +begin + FPropertyList := tJson2PumlBasePropertyList.Create; + FPropertyList.ConfigurationPropertyName := 'Unittest'; + FPropertyList.ItemList.Add('product*=value'); + FPropertyList.ItemList.Add('-productList'); + FPropertyList.ItemList.Add('product'); + FPropertyList.ItemList.Add('productParameter'); + FPropertyList.ItemList.Add('order=value'); + FPropertyList.ItemList.Add('product.amount'); + FPropertyList.ItemList.Add('product*.*'); + FPropertyList.ItemList.Add('product.price'); + FPropertyList.ItemList.Add('-product*.a*'); + FPropertyList.ItemList.Add('-*Offer*'); + FPropertyList.ItemList.Add('item'); + FPropertyList.ItemList.Add('product.item'); + FPropertyList.ItemList.Add('bill'); + FPropertyList.ItemList.Add(''); +end; + +procedure tJson2PumlBasePropertyListTest.TearDown; +begin + FPropertyList.Free; +end; + +procedure tJson2PumlBasePropertyListTest.TestIndexOfPropertyExact(const iPropertyName, iParentPropertyName, + iResultName: String); +begin + IndexOfProperty(iPropertyName, iParentPropertyName,'', False, iResultName); +end; + +procedure tJson2PumlBasePropertyListTest.TestIndexOfPropertyMatch(const iPropertyName, iParentPropertyName, + iResultName: String); +begin + IndexOfProperty(iPropertyName, iParentPropertyName,'', True, iResultName); +end; + +initialization + +TDUnitX.RegisterTestFixture(tJson2PumlBasePropertyListTest); + +end. diff --git a/unittests/uttJson2PumlFormatDefinition.pas b/unittests/uttJson2PumlFormatDefinition.pas new file mode 100644 index 0000000..572a9f6 --- /dev/null +++ b/unittests/uttJson2PumlFormatDefinition.pas @@ -0,0 +1,93 @@ +unit uttJson2PumlFormatDefinition; + +interface + +uses + DUnitX.TestFramework, json2pumlconverterdefinition; + +type + + [TestFixture] + tJson2PumlFormatDefinitionTest = class + private + FFormatDefinition: tJson2PumlFormatDefinition; + public + [Setup] + procedure Setup; + [TearDown] + procedure TearDown; + // Test with TestCase Attribute to supply parameters. + [Test] + [TestCase('Default/No matching format found', 'Unknown,,')] + [TestCase('Format Name only', 'Empty,,Empty')] + [TestCase('product', 'product,,A')] + [TestCase('product.item', 'item,product,C')] + [TestCase('productOffer', 'productOffer,,B')] + [TestCase('productOffer.charge', 'productOffer.charge,,B')] + [TestCase('bill.charge', 'charge,bill,')] + procedure TestGetFormatByName (const iPropertyName, iParentPropertyName, iFormatName: string); + property FormatDefinition: tJson2PumlFormatDefinition read FFormatDefinition write FFormatDefinition; + end; + +implementation + +procedure tJson2PumlFormatDefinitionTest.Setup; +var + SingleFormat: tJson2PumlSingleFormatDefinition; +begin + FFormatDefinition := tJson2PumlFormatDefinition.Create; + + SingleFormat := tJson2PumlSingleFormatDefinition.Create; + SingleFormat.FormatName := 'Empty'; + SingleFormat.IconColor := 'Red'; + FormatDefinition.Formats.AddDefinition (SingleFormat); + + SingleFormat := tJson2PumlSingleFormatDefinition.Create; + SingleFormat.FormatName := 'A'; + SingleFormat.ObjectFilter.Itemlist.Add('product*'); + SingleFormat.ObjectFilter.Itemlist.Add('product*.*'); + SingleFormat.ObjectFilter.Itemlist.Add('-*Offer*'); + FormatDefinition.Formats.AddDefinition (SingleFormat); + + SingleFormat := tJson2PumlSingleFormatDefinition.Create; + SingleFormat.FormatName := 'B'; + SingleFormat.ObjectFilter.Itemlist.Add('productOffer'); + SingleFormat.ObjectFilter.Itemlist.Add('productOffer.*'); + FormatDefinition.Formats.AddDefinition (SingleFormat); + + SingleFormat := tJson2PumlSingleFormatDefinition.Create; + SingleFormat.FormatName := 'C'; + SingleFormat.ObjectFilter.Itemlist.Add('item'); + FormatDefinition.Formats.AddDefinition (SingleFormat); +// +// SingleFormat := tJson2PumlSingleFormatDefinition.Create; +// SingleFormat.FormatName := 'C'; +// FormatDefinition.Formats.AddDefinition (SingleFormat); + +end; + +procedure tJson2PumlFormatDefinitionTest.TearDown; +begin + FFormatDefinition.Free; +end; + +procedure tJson2PumlFormatDefinitionTest.TestGetFormatByName (const iPropertyName, iParentPropertyName, + iFormatName: string); +var + SingleFormat: tJson2PumlSingleFormatDefinition; + Priority: Integer; + FoundCondition: string; +begin + SingleFormat := FormatDefinition.GetFormatByName (iPropertyName, iParentPropertyName, Priority, FoundCondition); + Assert.isnotnull(SingleFormat); + Assert.AreEqual(iFormatName, SingleFormat.FormatName, FoundCondition); + Assert.IsNotEmpty(FoundCondition, 'FoundCondition'); + Assert.Pass(FoundCondition); + +end; + +initialization + +TDUnitX.RegisterTestFixture (tJson2PumlFormatDefinitionTest); + +end.