Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New and updated model checks, improved XML export and bug fixes #15

Merged
merged 6 commits into from
Mar 8, 2024

Conversation

harmen-xb
Copy link
Contributor

@harmen-xb harmen-xb commented Mar 7, 2024

XML Export:

  • Added sorting in XML export for Packages, ExampleRecord, Inheritence, DependentModels (in Model template).
  • Added Comment to XML export of BaseStructuralFeatureMapping.
  • Created mdde_IsAttributeMapped extended attribute on EntityAttribute (with logic on inheritance) and added to XML Export.
  • Updated EntityAttribute XML Export template to produce same XML output (and newlines) as before added export extension.
  • Added mdde_NamedObject_XmlElementExport_Template to Example XML export.
  • Enabled export of Comment and Description properties for all named objects (mdde_NamedObject_XmlElementExport_Template).

Model checks:

  • BaseClassifierMapping
    • New: Check duplicate source objects (MDDE)
    • Updated: mdde_Check_OrderOFSourceObjects.
  • Business rule
    • Moved mdde_Check_BusinessRuleHasAtLeastOneInputAttribute and mdde_Check_BusinessRuleHasAtLeastOneExample to ExpressionBusinessRule, otherwise it wouldn't show up.
  • EntityAttribute:
    • Renamed mdde_Check_ScalarBusinessRule_AttributeCodeOccursInSqlExpression to mdde_Check_ExpressionBusinessRule_AttributeCodeOccursInSqlExpression.
  • ExtendedSubObject/mdde_EntityExampleData
    • New: Check Entity Example Data Attributes (MDDE)
  • ExtendedSubObject/mdde_SourceObject
    • New: Expression business rule join conditions are in same order as attributes (MDDE)
    • Updated: mdde_Check_JoinConditionSpecified: Added checking FROM object, coping with literals and better error handling.
  • ShortcutBase
    • New: Shortcut is broken (MDDE)

Other changes:

  • Renamed mdde_Classifier_IsMDDEMapping to mdde_Criterion_IsMDDEMapping.
  • Created mdde_IsMDDEDataSource criterium with template to be used from other objects to check data source is MDDE and refactored criteria for BaseClassifierMapping, BaseStructuralFeatureMapping, .
  • Updated Entity AddMapping method to use constant for the MDDE DataSource Stereotype.
  • Created mdde_Entity_IsBusinessRule extended attribute to be consumed by other extensions.
  • Fixed naming error in criterium from mdde_BusinessRule_IsBusinessRuleWithMapping to mdde_BusinessRule_IsBusinessRuleWithoutMapping.
  • Fixed ExtendedSubObject/mdde_EntityExampleData mdde_EntityExampleData_EditExampleEntity method so you can also make example data for business rules when used as source object in mappings.
  • Added mdde_ExampleValueCount on ExtendedSubObject/mdde_ExampleRecord, so it can be viewed in datagrid.
  • Added force saving the model file as XML (in Model mdde_ExportXmlAndDecompose method) to the current location to solve issue of switching to binary mode.

Harmen Wessels added 2 commits March 7, 2024 22:06
Created mdde_IsMDDEDataSource criterium with template to be used from other objects to check data source is MDDE and refactored criteria for BaseClassifierMapping, BaseStructuralFeatureMapping, .
Updated Entity AddMapping method to use constant for the MDDE DataSource Stereotype.
Created mdde_Entity_IsBusinessRule extended attribute to be consumed by other extensions.
Fixed naming error in criterium from mdde_BusinessRule_IsBusinessRuleWithMapping to mdde_BusinessRule_IsBusinessRuleWithoutMapping.
Fixed ExtendedSubObject/mdde_EntityExampleData mdde_EntityExampleData_EditExampleEntity method so you can also make example data for business rules with mappings.
Added mdde_ExampleValueCount on ExtendedSubObject/mdde_ExampleRecord, so it can be viewed in datagrid.
Added force saving the model file as XML (in Model mdde_ExportXmlAndDecompose method) to the current location to solve issue of switching to binary model.

XML Export:
- Added sorting in XML export for Packages, ExampleRecord, Inheritence, DependentModels (in Model template).
- Added Comment to XML export of BaseStructuralFeatureMapping.
- Created mdde_IsAttributeMapped extended attribute on EntityAttribute (with logic on inheritance) and added to XML Export.
- Updated EntityAttribute XML Export template to produce same XML output (and newlines) as before added export extension.
- Added mdde_NamedObject_XmlElementExport_Template to Example XML export.
- Enabled export of Comment and Description properties for all named objects (mdde_NamedObject_XmlElementExport_Template).

Model checks:
- BaseClassifierMapping
  - New: Check duplicate source objects (MDDE)
  - Updated: mdde_Check_OrderOFSourceObjects.
- Business rule
  - Moved mdde_Check_BusinessRuleHasAtLeastOneInputAttribute and mdde_Check_BusinessRuleHasAtLeastOneExample to ExpressionBusinessRule, otherwise it wouldn't show up.
  - EntityAttribute:
    - Renamed mdde_Check_ScalarBusinessRule_AttributeCodeOccursInSqlExpression to mdde_Check_ExpressionBusinessRule_AttributeCodeOccursInSqlExpression.
- ExtendedSubObject/mdde_EntityExampleData
  - New: Check Entity Example Data Attributes (MDDE)
- ExtendedSubObject/mdde_SourceObject
  - New: Expression business rule join conditions are in same order as attributes (MDDE)
  - Updated: mdde_Check_JoinConditionSpecified: Added checking FROM object, coping with literals and better error handling.
- ShortcutBase
  - New: Shortcut is broken (MDDE)
@harmen-xb harmen-xb requested a review from willem-xbreeze March 7, 2024 21:32
@harmen-xb harmen-xb self-assigned this Mar 7, 2024
@harmen-xb harmen-xb added bug Something isn't working enhancement New feature or request labels Mar 7, 2024
Updated pdc ldm config to removed empty ExtendedCollections and ExtendedComposition elements.
@willem-xbreeze willem-xbreeze merged commit 7754325 into main Mar 8, 2024
1 check passed
@willem-xbreeze willem-xbreeze deleted the feature/model-checks-export-sort branch March 8, 2024 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants