- java.lang.Object
-
- net.n2oapp.framework.config.metadata.compile.widget.BaseWidgetCompiler<D,S>
-
- All Implemented Interfaces:
SourceClassAware,SourceCompiler<D,S,CompileContext<?,?>>,BaseSourceCompiler<D,S,CompileContext<?,?>>
- Direct Known Subclasses:
BaseListWidgetCompiler,CalendarCompiler,ChartCompiler,CustomWidgetCompiler,FormCompiler,HtmlWidgetCompiler,TreeCompiler
public abstract class BaseWidgetCompiler<D extends Widget,S extends N2oWidget> extends java.lang.Object implements BaseSourceCompiler<D,S,CompileContext<?,?>>
Компиляция абстрактного виджета
-
-
Constructor Summary
Constructors Constructor Description BaseWidgetCompiler()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voidcollectValidation(FieldSet fs, java.util.Map<java.lang.String,java.util.List<Validation>> clientValidations, ValidationScope validationScope)protected voidcompileDataProviderAndRoutes(D compiled, S source, CompileContext<?,?> context, CompileProcessor p, ValidationList validationList, ParentRouteScope widgetRouteScope, SubModelsScope subModelsScope, CopiedFieldScope copiedFieldScope, CompiledObject object)protected voidcompileToolbarAndAction(D compiled, S source, CompileContext<?,?> context, CompileProcessor p, WidgetScope widgetScope, ParentRouteScope widgetRouteScope, MetaActions widgetActions, CompiledObject object, ValidationList validationList)protected voidcompileWidget(D compiled, S source, CompileContext<?,?> context, CompileProcessor p, CompiledObject object)protected java.lang.StringgetFailAlertWidget(Widget widget)protected java.lang.StringgetMessagesForm(Widget widget)protected CompiledObjectgetObject(S source, CompileProcessor p)protected abstract java.lang.StringgetPropertyWidgetSrc()protected CompiledQuerygetQuery(S source, CompileProcessor p)Получить скомпилированную выборкуprotected QueryContextgetQueryContext(D widget, S source, CompileContext<?,?> context, java.lang.String route, CompiledQuery query, ValidationList validationList, SubModelsScope subModelsScope, CopiedFieldScope copiedFieldScope, CompileProcessor p, CompiledObject object)protected java.lang.StringgetSuccessAlertWidget(Widget widget)protected java.util.List<FieldSet>initFieldSets(SourceComponent[] fields, CompileContext<?,?> context, CompileProcessor p, WidgetScope widgetScope, CompiledQuery widgetQuery, CompiledObject widgetObject, java.lang.Object... scopes)Инициализация филдсетовprotected FieldSetScopeinitFieldSetScope(CompiledQuery query, CompiledObject object)protected ParentRouteScopeinitWidgetRouteScope(D compiled, CompileContext<?,?> context, CompileProcessor p)Инициализация текущего маршрута виджета при сборке-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.n2oapp.framework.api.metadata.aware.SourceClassAware
getSourceClass
-
Methods inherited from interface net.n2oapp.framework.api.metadata.compile.SourceCompiler
compile
-
-
-
-
Method Detail
-
getPropertyWidgetSrc
protected abstract java.lang.String getPropertyWidgetSrc()
-
compileWidget
protected void compileWidget(D compiled, S source, CompileContext<?,?> context, CompileProcessor p, CompiledObject object)
-
initWidgetRouteScope
protected ParentRouteScope initWidgetRouteScope(D compiled, CompileContext<?,?> context, CompileProcessor p)
Инициализация текущего маршрута виджета при сборке- Parameters:
context- Контекстp- Процессор сборки- Returns:
- Маршрут виджета соединенный с родительским маршрутом
-
compileDataProviderAndRoutes
protected void compileDataProviderAndRoutes(D compiled, S source, CompileContext<?,?> context, CompileProcessor p, ValidationList validationList, ParentRouteScope widgetRouteScope, SubModelsScope subModelsScope, CopiedFieldScope copiedFieldScope, CompiledObject object)
-
collectValidation
protected void collectValidation(FieldSet fs, java.util.Map<java.lang.String,java.util.List<Validation>> clientValidations, ValidationScope validationScope)
-
compileToolbarAndAction
protected void compileToolbarAndAction(D compiled, S source, CompileContext<?,?> context, CompileProcessor p, WidgetScope widgetScope, ParentRouteScope widgetRouteScope, MetaActions widgetActions, CompiledObject object, ValidationList validationList)
-
getObject
protected CompiledObject getObject(S source, CompileProcessor p)
-
getQueryContext
protected QueryContext getQueryContext(D widget, S source, CompileContext<?,?> context, java.lang.String route, CompiledQuery query, ValidationList validationList, SubModelsScope subModelsScope, CopiedFieldScope copiedFieldScope, CompileProcessor p, CompiledObject object)
-
getFailAlertWidget
protected java.lang.String getFailAlertWidget(Widget widget)
-
getSuccessAlertWidget
protected java.lang.String getSuccessAlertWidget(Widget widget)
-
getMessagesForm
protected java.lang.String getMessagesForm(Widget widget)
-
getQuery
protected CompiledQuery getQuery(S source, CompileProcessor p)
Получить скомпилированную выборку
-
initFieldSetScope
protected FieldSetScope initFieldSetScope(CompiledQuery query, CompiledObject object)
-
initFieldSets
protected java.util.List<FieldSet> initFieldSets(SourceComponent[] fields, CompileContext<?,?> context, CompileProcessor p, WidgetScope widgetScope, CompiledQuery widgetQuery, CompiledObject widgetObject, java.lang.Object... scopes)
Инициализация филдсетов- Parameters:
fields- Список полей или филдсетов или строк или столбцовcontext- Контекст сборкиwidgetQuery- Выборка виджетаp- Процессор сборки- Returns:
- Список филдсетов
-
-