Platform Explorer / Nuxeo Platform LTS 2015 7.10

Component org.nuxeo.ecm.webengine.WebEngineComponent

Implementation

Javadoc: org.nuxeo.ecm.webengine.WebEngineComponent

Services

Extension points

Contributions

XML source

<?xml version="1.0"?>
<component name="org.nuxeo.ecm.webengine.WebEngineComponent">
  <require>org.nuxeo.ecm.platform.ui.web.auth.service.PluggableAuthenticationService</require>

  <implementation
          class="org.nuxeo.ecm.webengine.WebEngineComponent" />
  <documentation>
    @author Bogdan Stefanescu (bs@nuxeo.com)
    Manage templates
  </documentation>

  <!-- you can change the default rendering engine by setting this property to the engine class name
  <property name="engine" value="org.nuxeo.ecm.platform.rendering.fm.FreemarkerEngine"/>
  -->

  <service>
    <provide interface="org.nuxeo.ecm.webengine.WebEngine" />
  </service>

  <extension-point name="rendering-extension">
    <documentation>
      @author Bogdan Stefanescu (bs@nuxeo.com)
      Expose the registration of freemarker templates (directives, methods or global shared variables)
      This way custom templates can be registered into the freemarker engine from outside
      <code>
        <rendering-extension name="myExtension" class="org.nuxeo.ecm.platform.my.MyExtension"/>
      </code>
    </documentation>

    <object
      class="org.nuxeo.ecm.webengine.rendering.RenderingExtensionDescriptor" />
  </extension-point>

  <extension-point name="guard">
    <documentation>
      @author Bogdan Stefanescu (bs@nuxeo.com)
      Register global guards. Guards are used to define permissions
      <code>
        <guard id="MyGuard" expression="(GUARD1 OR GUARD2) AND user=bogdan">
        </guard>
      </code>
    </documentation>

    <object
      class="org.nuxeo.ecm.webengine.security.GuardDescriptor" />
  </extension-point>

  <extension-point name="resource">
    <documentation>
      @author Bogdan Stefanescu (bs@nuxeo.com)
      Register a JAX-RS root resource
      <code>
        <resource path="{lang:[a-z]}" singleton="false" class="org.nuxeo.Resource" />
      </code>
    </documentation>

    <object
      class="org.nuxeo.ecm.webengine.ResourceBinding" />
  </extension-point>

  <extension-point name="request-configuration">
    <documentation>
      @author Bogdan Stefanescu (bs@nuxeo.com)
  Configure how a given path is handled by the WebEngine filter.

  If <b>autoTx</b> is true (which is the default) then a transaction will be
  started each time a path matching the given path specification is requested.
  (the transaction is started in a filter before the JAX-RS resource is called
  and closed after the response is sent to the output stream). If false then no
  transaction handling is done. The default is to start a transaction for any
  path but: [^/]+/skin/.*

  The <b>value</b> attribute is required and must be used to specify the path pattern. The path
  pattern is either a prefix or a regular expression. If the <b>regex</b> parameter
  is true (the default is false) then the value will be expected to be a
  regular expression. A prefix denotes a path starting with 'prefix'. Paths are
  relative to the webengine servlet (i.e. they correspond to the servlet path
  info in the JAX-RS servlet) - and always begin with a '/'.

      <code>
        <path value="/admin" autoTx="false" />
      </code>
    </documentation>

    <object
      class="org.nuxeo.ecm.webengine.PathDescriptor" />
  </extension-point>

  <extension target="org.nuxeo.ecm.webengine.WebEngineComponent" point="rendering-extension">
    <rendering-extension name="script" class="org.nuxeo.ecm.webengine.rendering.ScriptMethod"/>
    <rendering-extension name="render" class="org.nuxeo.ecm.webengine.rendering.RenderDirective"/>
    <rendering-extension name="wiki" class="org.nuxeo.ecm.platform.rendering.wiki.WikiTransformer"/>
    <rendering-extension name="API" class="org.nuxeo.ecm.webengine.rendering.APIHelper"/>
  </extension>

  <!-- extension target="org.nuxeo.runtime.server" point="webapp">
    <webapp name="nuxeo" path="/">
      <root>web/root.war</root>
    </webapp>
  </extension-->

</component>

Documentation

Manage templates