To illustrate what a JSP page fragment might look like, the following code sample shows an abbreviated configuration page for a document exchange gear. This page is designed to appear when the user clicks an Edit link on the gear’s shared view. It uses a subclass of GearConfigFormHandler named DocExchConfigFormHandler.

<%@ taglib uri="/dsp" prefix="dsp" %>
<%@ taglib uri="/paf-taglib" prefix="paf" %>
<paf:InitializeGearEnvironment id="gearEnv">
<dsp:importbean bean="/atg/portal/gear/docexch/DocExchConfigFormHandler"/>

  <%-- set default values --%>
<dsp:setvalue bean="DocExchConfigFormHandler.paramType" value="instance"/>
<dsp:setvalue bean="DocExchConfigFormHandler.settingDefaultValues"
              value="true"/>
<dsp:setvalue bean="DocExchConfigFormHandler.paramNames"
              value="fullListPageSize property1 property2 property3"/>

  <%-- start form --%>
<dsp:form method="post" action="<%= pafEnv.getOriginalRequestURI() %>">

  <%-- 2 hidden params indicate we are setting user-specific parameter
values --%>
  <dsp:input type="hidden" bean="DocExchConfigFormHandler.successUrl"
             value="<%= pafEnv.getOriginalRequestURI() %>"/>
  <dsp:input type="hidden" bean="DocExchConfigFormHandler.paramType"
             value="user"/>
  <dsp:input type="hidden"
             bean="DocExchConfigFormHandler.settingDefaultValues" value="false"/>

  <input type="hidden" name="paf_gear_id"
         value="<%=pafEnv.getGear().getId()%>"/>

...

How many documents would you like to see on each page of the full page
listing?<br>

Full List Page Size:

<dsp:input type="text" size="5"
           bean="DocExchConfigFormHandler.values.fullListPageSize"/>

...

<%! -- ADDITIONAL SETTINGS GO HERE --%>

...

<dsp:input type="submit" value="Finish" bean="DocExchConfigFormHandler.confirm"/>
 &nbsp;&nbsp;&nbsp;
  <input type="submit" value="Cancel"/>

...

</dsp:form>

</paf:InitializeGearEnvironment>
 
loading table of contents...