Package io.jmix.dynmodelflowui.impl
Class DynamicViewValidatorImpl
java.lang.Object
io.jmix.dynmodelflowui.impl.DynamicViewValidatorImpl
- All Implemented Interfaces:
DynamicViewValidator
@Component("dynmod_DynamicViewValidator")
public class DynamicViewValidatorImpl
extends Object
implements DynamicViewValidator
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected org.springframework.beans.factory.ObjectProvider<DynamicModelManager> protected DynamicModelToolsprotected static final Stringprotected Metadataprotected static final Patternprotected static final Patternprotected DynamicTemplateViewSupportprotected ViewRegistry -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddResult(List<DynamicViewValidationResult> results, String entityName, DynamicViewDefinition definition, @Nullable String viewId, List<String> errors) collectCreatedDynamicEntities(DynamicModelDefinition modelDefinition) protected StringcreateRouteSlug(String value) protected StringresolveRoute(DynamicViewDefinition definition, String viewId, DynamicViewType type) protected StringresolveViewId(String entityName, DynamicViewDefinition definition, @Nullable DynamicViewType type) validate(DynamicModelDefinition modelDefinition) Validates the views declared in the given model definition.protected @Nullable DynamicViewTypevalidateAndResolveType(DynamicEntityDefinition entityDefinition, boolean dynamicEntity, DynamicViewDefinition viewDefinition, List<String> errors) protected voidvalidateDescriptor(boolean dynamicEntity, DynamicViewDefinition viewDefinition, @Nullable DynamicViewType type, List<String> errors) protected voidvalidateStaticAndDynamicRules(boolean dynamicEntity, DynamicViewDefinition viewDefinition, List<String> errors) protected voidvalidateTemplatePath(String template, List<String> errors) protected voidvalidateXmlDescriptor(@Nullable String source, List<String> errors)
-
Field Details
-
FLOWUI_VIEW_NS
- See Also:
-
ROUTE_NON_ALNUM
-
ROUTE_EDGE
-
metadata
-
dynamicModelTools
-
viewRegistry
-
dynamicModelManagerProvider
@Autowired protected org.springframework.beans.factory.ObjectProvider<DynamicModelManager> dynamicModelManagerProvider -
templateViewSupport
-
-
Constructor Details
-
DynamicViewValidatorImpl
public DynamicViewValidatorImpl()
-
-
Method Details
-
validate
Description copied from interface:DynamicViewValidatorValidates the views declared in the given model definition.- Specified by:
validatein interfaceDynamicViewValidator- Parameters:
modelDefinition- dynamic model definition to validate- Returns:
- a result for each view that has errors; empty if all views are valid
-
validateAndResolveType
protected @Nullable DynamicViewType validateAndResolveType(DynamicEntityDefinition entityDefinition, boolean dynamicEntity, DynamicViewDefinition viewDefinition, List<String> errors) -
validateStaticAndDynamicRules
protected void validateStaticAndDynamicRules(boolean dynamicEntity, DynamicViewDefinition viewDefinition, List<String> errors) -
validateDescriptor
protected void validateDescriptor(boolean dynamicEntity, DynamicViewDefinition viewDefinition, @Nullable DynamicViewType type, List<String> errors) -
validateTemplatePath
-
validateXmlDescriptor
-
resolveViewId
protected String resolveViewId(String entityName, DynamicViewDefinition definition, @Nullable DynamicViewType type) -
resolveRoute
protected String resolveRoute(DynamicViewDefinition definition, String viewId, DynamicViewType type) -
createRouteSlug
-
collectCreatedDynamicEntities
-
addResult
protected void addResult(List<DynamicViewValidationResult> results, String entityName, DynamicViewDefinition definition, @Nullable String viewId, List<String> errors)
-