From c067a976d30d0a1213648e46bc912a11024f5c4e Mon Sep 17 00:00:00 2001 From: Raphael Date: Mon, 14 Jul 2025 08:09:50 +0200 Subject: [PATCH 1/2] feat: created parent type rule --- proto/shared/shared.data_type.proto | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/proto/shared/shared.data_type.proto b/proto/shared/shared.data_type.proto index 5dbc667..44d7961 100644 --- a/proto/shared/shared.data_type.proto +++ b/proto/shared/shared.data_type.proto @@ -30,10 +30,8 @@ message DefinitionDataType { repeated Translation name = 3; // Rules of the data type (e.g. Regex, contains...) repeated DefinitionDataTypeRule rules = 4; - // Optional identifier it the given data type is a child of another - optional DataTypeIdentifier parent_type = 5; // List of generic keys - repeated string generic_keys = 6; + repeated string generic_keys = 5; } message ExecutionDataType { @@ -41,8 +39,6 @@ message ExecutionDataType { string identifier = 1; // Rules of the data type (e.g. Regex, contains...) repeated ExecutionDataTypeRule rules = 2; - // Optional identifier it the given data type is a child of another - optional string parent_type = 3; } message DefinitionDataTypeRule { @@ -54,6 +50,7 @@ message DefinitionDataTypeRule { DataTypeRegexRuleConfig regex = 5; DefinitionDataTypeInputTypesRuleConfig input_types = 6; DefinitionDataTypeReturnTypeRuleConfig return_type = 7; + DefinitionDataTypeParentTypeRuleConfig parent_type = 8; } } @@ -64,9 +61,19 @@ message ExecutionDataTypeRule { DataTypeItemOfCollectionRuleConfig item_of_collection = 3; DataTypeNumberRangeRuleConfig number_range = 4; DataTypeRegexRuleConfig regex = 5; + ExecutionDataTypeParentTypeRuleConfig parent_type = 6; } } +// Rule for defining the data type parent type +message DefinitionDataTypeParentTypeRuleConfig { + DataTypeIdentifier parent_type = 1; +} + +message ExecutionDataTypeParentTypeRuleConfig { + string parent_type = 1; +} + // Rule to check that the given key is contained in the given object message DefinitionDataTypeContainsKeyRuleConfig { string key = 1; From d052e4a2548360af81487e83140732ff63f4e801 Mon Sep 17 00:00:00 2001 From: Raphael Date: Mon, 14 Jul 2025 19:24:08 +0200 Subject: [PATCH 2/2] Update shared.data_type.proto --- proto/shared/shared.data_type.proto | 5 ----- 1 file changed, 5 deletions(-) diff --git a/proto/shared/shared.data_type.proto b/proto/shared/shared.data_type.proto index 44d7961..4acedf5 100644 --- a/proto/shared/shared.data_type.proto +++ b/proto/shared/shared.data_type.proto @@ -61,7 +61,6 @@ message ExecutionDataTypeRule { DataTypeItemOfCollectionRuleConfig item_of_collection = 3; DataTypeNumberRangeRuleConfig number_range = 4; DataTypeRegexRuleConfig regex = 5; - ExecutionDataTypeParentTypeRuleConfig parent_type = 6; } } @@ -70,10 +69,6 @@ message DefinitionDataTypeParentTypeRuleConfig { DataTypeIdentifier parent_type = 1; } -message ExecutionDataTypeParentTypeRuleConfig { - string parent_type = 1; -} - // Rule to check that the given key is contained in the given object message DefinitionDataTypeContainsKeyRuleConfig { string key = 1;