@Override public void onConfigure(final Component component) { notify(new INotifier<IComponentOnConfigureListener>() { @Override public void notify(IComponentOnConfigureListener listener) { listener.onConfigure(component); } }); } }
application.getComponentOnConfigureListeners().add(new PageParametersAwareEnabler());
getApplication().getComponentOnConfigureListeners().onConfigure(this);
@Override protected void init() { super.init(); getMarkupSettings().setStripWicketTags(true); getMarkupSettings().setStripComments(true); getMarkupSettings().setDefaultMarkupEncoding(StandardCharsets.UTF_8.name()); setHeaderResponseDecorator(r -> new JavaScriptFilteredIntoFooterHeaderResponse(r, SingularTemplate.JAVASCRIPT_CONTAINER)); getComponentInstantiationListeners().add(new SpringComponentInjector(this)); new SingularAnnotatedMountScanner().mountPages(this); List<IStringResourceLoader> stringResourceLoaders = getResourceSettings().getStringResourceLoaders(); stringResourceLoaders.add(0, new ClassStringResourceLoader(appConfig.getClass())); getComponentOnConfigureListeners().add(component -> { boolean outputId = !component.getRenderBodyOnly(); component.setOutputMarkupId(outputId).setOutputMarkupPlaceholderTag(outputId); }); getRequestCycleListeners().add(new SingularCsrfPreventionRequestCycleListener()); }
getApplication().getComponentOnConfigureListeners().onConfigure(this);
@Override public void init() { super.init(); getMarkupSettings().setStripWicketTags(true); getMarkupSettings().setStripComments(true); getApplicationSettings().setAccessDeniedPage(Page403.class); getApplicationSettings().setPageExpiredErrorPage(Page410.class); getMarkupSettings().setDefaultMarkupEncoding(StandardCharsets.UTF_8.name()); setHeaderResponseDecorator(r -> new JavaScriptFilteredIntoFooterHeaderResponse(r, SingularTemplate.JAVASCRIPT_CONTAINER)); getComponentInstantiationListeners().add(new SpringComponentInjector(this)); new AnnotatedMountScanner().scanPackage("org.opensingular.studio").mount(this); List<IStringResourceLoader> stringResourceLoaders = getResourceSettings().getStringResourceLoaders(); stringResourceLoaders.add(0, new ClassStringResourceLoader(appConfig.getClass())); getComponentOnConfigureListeners().add(component -> { boolean outputId = !component.getRenderBodyOnly(); component.setOutputMarkupId(outputId).setOutputMarkupPlaceholderTag(outputId); }); }
@Override public void onConfigure(final Component component) { notify(new INotifier<IComponentOnConfigureListener>() { @Override public void notify(IComponentOnConfigureListener listener) { listener.onConfigure(component); } }); } }
@Override public void init() { super.init(); getRequestCycleSettings().setTimeout(Duration.minutes(5)); getRequestCycleListeners().add(new SingularServerContextListener()); Locale.setDefault(new Locale("pt", "BR"));//NOSONAR getApplicationSettings().setAccessDeniedPage(Error403Page.class); getApplicationSettings().setPageExpiredErrorPage(Page410.class); // Don't forget to check your Application server for this getApplicationSettings().setDefaultMaximumUploadSize(Bytes.megabytes(10)); getMarkupSettings().setStripWicketTags(true); getMarkupSettings().setStripComments(true); getMarkupSettings().setDefaultMarkupEncoding(StandardCharsets.UTF_8.name()); getComponentOnConfigureListeners().add(component -> { boolean outputId = !component.getRenderBodyOnly(); component.setOutputMarkupId(outputId).setOutputMarkupPlaceholderTag(outputId); }); getComponentInstantiationListeners().add(new SpringComponentInjector(this, getApplicationContext(), true)); new SingularAnnotatedMountScanner().mountPages(this); if (RuntimeConfigurationType.DEVELOPMENT == getConfigurationType()) { getDebugSettings().setComponentPathAttributeName("wicketdebug"); WicketSerializationDebugUtil.configurePageSerializationDebug(this, this.getClass()); } }
@Override public void init() { super.init(); getRequestCycleSettings().setTimeout(Duration.minutes(5)); getRequestCycleListeners().add(new SingularServerContextListener()); Locale.setDefault(new Locale("pt", "BR"));//NOSONAR getApplicationSettings().setAccessDeniedPage(Error403Page.class); getApplicationSettings().setPageExpiredErrorPage(Page410.class); // Don't forget to check your Application server for this getApplicationSettings().setDefaultMaximumUploadSize(Bytes.megabytes(10)); getMarkupSettings().setStripWicketTags(true); getMarkupSettings().setStripComments(true); getMarkupSettings().setDefaultMarkupEncoding(StandardCharsets.UTF_8.name()); getComponentOnConfigureListeners().add(component -> { boolean outputId = !component.getRenderBodyOnly(); component.setOutputMarkupId(outputId).setOutputMarkupPlaceholderTag(outputId); }); getComponentInstantiationListeners().add(new SpringComponentInjector(this, getApplicationContext(), true)); new SingularAnnotatedMountScanner().mountPages(this); if (RuntimeConfigurationType.DEVELOPMENT == getConfigurationType()) { getDebugSettings().setComponentPathAttributeName("wicketdebug"); WicketSerializationDebugUtil.configurePageSerializationDebug(this, this.getClass()); } }
@Override public void init() { super.init(); setPageManagerProvider(new RequirementPageManagerProvider(this)); getStoreSettings().setMaxSizePerSession(Bytes.megabytes(20)); getRequestCycleSettings().setTimeout(Duration.minutes(5)); getRequestCycleListeners().add(new SingularRequirementContextListener()); Locale.setDefault(new Locale("pt", "BR"));//NOSONAR getApplicationSettings().setAccessDeniedPage(Page403.class); getApplicationSettings().setPageExpiredErrorPage(Page410.class); // Don't forget to check your Application server for this getApplicationSettings().setDefaultMaximumUploadSize(Bytes.megabytes(10)); getMarkupSettings().setStripWicketTags(true); getMarkupSettings().setStripComments(true); getMarkupSettings().setDefaultMarkupEncoding(StandardCharsets.UTF_8.name()); getComponentOnConfigureListeners().add(component -> { boolean outputId = !component.getRenderBodyOnly(); component.setOutputMarkupId(outputId).setOutputMarkupPlaceholderTag(outputId); }); getComponentInstantiationListeners().add(new SpringComponentInjector(this, getApplicationContext(), true)); new SingularAnnotatedMountScanner().mountPages(this); if (RuntimeConfigurationType.DEVELOPMENT == getConfigurationType()) { getDebugSettings().setComponentPathAttributeName("wicketdebug"); WicketSerializationDebugUtil.configurePageSerializationDebug(this, this.getClass()); } }
@Override public void init() { super.init(); getRequestCycleSettings().setTimeout(Duration.minutes(5)); getRequestCycleListeners().add(new SingularServerContextListener()); Locale.setDefault(new Locale("pt", "BR")); getApplicationSettings().setAccessDeniedPage(Error403Page.class); getApplicationSettings().setPageExpiredErrorPage(Page410.class); // Don't forget to check your Application server for this getApplicationSettings().setDefaultMaximumUploadSize(Bytes.megabytes(10)); getMarkupSettings().setStripWicketTags(true); getMarkupSettings().setStripComments(true); getMarkupSettings().setDefaultMarkupEncoding("UTF-8"); getComponentOnConfigureListeners().add(component -> { boolean outputId = !component.getRenderBodyOnly(); component.setOutputMarkupId(outputId).setOutputMarkupPlaceholderTag(outputId); }); if (applicationContext != null) { getComponentInstantiationListeners().add(new SpringComponentInjector(this, applicationContext, true)); } else { getComponentInstantiationListeners().add(new SpringComponentInjector(this)); applicationContext = WebApplicationContextUtils.getWebApplicationContext(getServletContext()); } new AnnotatedMountScanner().scanPackage("org.opensingular").mount(this); for (String packageName : getPackagesToScan()) { new AnnotatedMountScanner().scanPackage(packageName).mount(this); } getDebugSettings().setComponentPathAttributeName("wicketpath"); }