The /atg/endeca/assembler/droplet/InvokeAssembler servlet bean, which is of class atg.endeca.assembler.droplet.InvokeAssembler, provides a means of invoking the Assembler via a servlet bean on a page. It is useful on pages that contain mostly Nucleus-driven content, with a section of Assembler-based content. Note that, for pages that have multiple sections of Assembler content, you should consider combining the requests for that content into a single InvokeAssembler call for performance reasons.

Input Parameters

The InvokeAssembler servlet bean has two input parameters, includePath and contentCollection, described below. Note that you must provide either an includePath or a contentCollection parameter, but you cannot provide both.

includePath
Use the includePath parameter for a page request. The path you specify must correspond to the name of a page in Experience Manager and is relative to the current site. For example, if includePath is set to /browse and the current site is Site A, the content for Site A’s browse page is retrieved. InvokeAssembler creates a ContentInclude component and sets its contentUri property from the includePath parameter.

contentCollection
Use the contentCollection parameter for a content folder request. The value you provide for contentCollection must correspond to the name of a content folder in Experience Manager, for example, Search Box Auto Suggest Content. InvokeAssembler creates a ContentSlotConfig component and inserts the contentCollection parameter in its contentUri property. Note that the ContentSlotConfig component specifies both the content folder and the number of content items to return from that folder. The number of items to return is specified using the InvokeAssembler.ruleLimit parameter, described next.

ruleLimit
This optional parameter is used in conjunction with the contentCollection parameter to specify the number of items that should be returned from the specified content folder.

Output Parameters

The InvokeAssembler servlet bean has one output parameter, contentItem. This parameter contains the root ContentItem returned by the Assembler. If this content item is empty, the request was not an Assembler request.

Open Parameters

The InvokeAssembler has two open parameters.

output
Rendered when the Assembler returns a ContentItem.

error
Rendered if the Assembler returns a ContentItem with an @error key. The presence of this key indicates that the ContentItem does not contain any content because the Assembler threw an exception or returned an error.

Example

This code snippet shows how to use the InvokeAssembler servlet bean on a page:

<dsp:importbean bean="/atg/endeca/assembler/droplet/InvokeAssembler"/>
<dsp:droplet name="InvokeAssembler">
  <dsp:param name="includePath" value="/browse"/>
  <dsp:oparam name="output">
    <dsp:getvalueof var="contentItem"
                    vartype="com.endeca.infront.assembler.ContentItem"
                    param="contentItem" />
  </dsp:oparam>
</dsp:droplet>

Copyright © 1997, 2016 Oracle and/or its affiliates. All rights reserved. Legal Notices