⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wpslookupdispatchaction.html

📁 门户开发
💻 HTML
📖 第 1 页 / 共 2 页
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"><!--NewPage--><HTML><HEAD><!-- Generated by javadoc (build 1.4.2) on Wed Jul 19 18:22:43 EDT 2006 --><TITLE>WpsLookupDispatchAction (IBM WebSphere Portal Version 6.0.0.0 API Docs)</TITLE><META NAME="keywords" CONTENT="com.ibm.wps.struts.action.WpsLookupDispatchAction class"><LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style"><SCRIPT type="text/javascript">function windowTitle(){    parent.document.title="WpsLookupDispatchAction (IBM WebSphere Portal Version 6.0.0.0 API Docs)";}</SCRIPT></HEAD><BODY BGCOLOR="white" onload="windowTitle();"><!-- ========= START OF TOP NAVBAR ======= --><A NAME="navbar_top"><!-- --></A><A HREF="#skip-navbar_top" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_top_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">  <TR ALIGN="center" VALIGN="top">  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<A HREF="#main"><FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../serialized-form.html"><FONT CLASS="NavBarFont1"><B>Serialized</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../../../../com/ibm/wps/struts/action/WpsDispatchAction.html" title="class in com.ibm.wps.struts.action"><B>PREV CLASS</B></A>&nbsp;&nbsp;NEXT CLASS</FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="WpsLookupDispatchAction.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;&nbsp;<SCRIPT type="text/javascript">  <!--  if(window==top) {    document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');  }  //--></SCRIPT><NOSCRIPT>  <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_top"></A><!-- ========= END OF TOP NAVBAR ========= --><HR><A NAME="main"></A><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">com.ibm.wps.struts.action</FONT><BR>Class WpsLookupDispatchAction</H2><PRE>java.lang.Object  <IMG SRC="../../../../../resources/inherit.gif" ALT="extended by">org.apache.struts.action.Action      <IMG SRC="../../../../../resources/inherit.gif" ALT="extended by"><A HREF="../../../../../com/ibm/wps/struts/action/StrutsAction.html" title="class in com.ibm.wps.struts.action">com.ibm.wps.struts.action.StrutsAction</A>          <IMG SRC="../../../../../resources/inherit.gif" ALT="extended by"><A HREF="../../../../../com/ibm/wps/struts/action/WpsDispatchAction.html" title="class in com.ibm.wps.struts.action">com.ibm.wps.struts.action.WpsDispatchAction</A>              <IMG SRC="../../../../../resources/inherit.gif" ALT="extended by"><B>com.ibm.wps.struts.action.WpsLookupDispatchAction</B></PRE><HR><DL><DT>public abstract class <B>WpsLookupDispatchAction</B><DT>extends <A HREF="../../../../../com/ibm/wps/struts/action/WpsDispatchAction.html" title="class in com.ibm.wps.struts.action">WpsDispatchAction</A></DL><P><p>  A Portal friendly implementation of the LookupDispatchAction class. The following comments are from the Struts LookupDispatchAction javadoc.</p>  <p>  An abstract <strong>Action</strong> that dispatches to the subclass mapped  <code>execute</code> method. This is useful in  cases where an HTML form has multiple submit buttons with the same name. The  button name is specified by the <code>parameter</code> property of the  corresponding ActionMapping. To configure the use of this action in your  <code>struts-config.xml</code> file, create an entry like this: </p>  <pre>   &lt;action path="/test"           type="org.example.MyAction"           name="MyForm"          scope="request"          input="/test.jsp"      parameter="action"/&gt; </pre>  <p>  which will use the value of the request parameter named "action" to locate  the corresponding key in ApplicationResources. For example, you might have  the following ApplicationResources.properties: </p>  <pre>    button.add=Add Record    button.delete=Delete Record </pre> <p>  And your JSP would have the following format for submit buttons: </p>  <pre>   &lt;html:form action="/test"&gt;    &lt;html:submit property="action"&gt;      &lt;bean:message key="button.add"/&gt;    &lt;/html:submit&gt;    &lt;html:submit property="action"&gt;      &lt;bean:message key="button.delete"/&gt;    &lt;/html:submit&gt;  &lt;/html:form&gt; </pre>   <p>  Your subclass must implement both getKeyMethodMap and the  methods defined in the map. An example of such implementations are: </p> <pre>  protected Map getKeyMethodMap() {      Map map = new HashMap();      map.put("button.add", "add");      map.put("button.delete", "delete");      return map;  }  public ActionForward add(ActionMapping mapping,          ActionForm form,          PortletRequest request )          throws IOException, ServletException {      // do add      return mapping.findForward("success");  }  public ActionForward delete(ActionMapping mapping,          ActionForm form,          PortletRequest request )          throws IOException, ServletException {      // do delete      return mapping.findForward("success");  } </pre>  <p>  <strong>NOTE</strong> - If duplicate values exist for the keys returned by  getKeys, only the first one found will be returned. If no corresponding key  is found then an exception will be thrown.<P><P><DL><DT><B>Since:</B></DT>  <DD>5.0</DD></DL><HR><P><!-- ======== NESTED CLASS SUMMARY ======== --><!-- =========== FIELD SUMMARY =========== --><A NAME="field_summary"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TH ALIGN="left" COLSPAN=2><FONT SIZE="+2"><B>Field Summary</B></FONT></TH></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected &nbsp;java.util.Map</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../com/ibm/wps/struts/action/WpsLookupDispatchAction.html#keyMethodMap">keyMethodMap</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Resource key to method name lookup.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected &nbsp;java.util.Map</CODE></FONT></TD><TD><CODE><B><A HREF="../../../../../com/ibm/wps/struts/action/WpsLookupDispatchAction.html#localeMap">localeMap</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reverse lookup map from resource value to resource key.</TD></TR></TABLE>&nbsp;<A NAME="fields_inherited_from_class_com.ibm.wps.struts.action.WpsDispatchAction"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TH ALIGN="left"><B>Fields inherited from class com.ibm.wps.struts.action.<A HREF="../../../../../com/ibm/wps/struts/action/WpsDispatchAction.html" title="class in com.ibm.wps.struts.action">WpsDispatchAction</A></B></TH></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="../../../../../com/ibm/wps/struts/action/WpsDispatchAction.html#clazz">clazz</A>, <A HREF="../../../../../com/ibm/wps/struts/action/WpsDispatchAction.html#log">log</A>, <A HREF="../../../../../com/ibm/wps/struts/action/WpsDispatchAction.html#messages">messages</A>, <A HREF="../../../../../com/ibm/wps/struts/action/WpsDispatchAction.html#methods">methods</A>, <A HREF="../../../../../com/ibm/wps/struts/action/WpsDispatchAction.html#types">types</A></CODE></TD></TR></TABLE>&nbsp;<A NAME="fields_inherited_from_class_org.apache.struts.action.Action"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TH ALIGN="left"><B>Fields inherited from class org.apache.struts.action.Action</B></TH></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE>ACTION_SERVLET_KEY, APPLICATION_KEY, DATA_SOURCE_KEY, defaultLocale, ERROR_KEY, EXCEPTION_KEY, FORM_BEANS_KEY, FORWARDS_KEY, LOCALE_KEY, MAPPING_KEY, MAPPINGS_KEY, MESSAGE_KEY, MESSAGES_KEY, MULTIPART_KEY, PLUG_INS_KEY, REQUEST_PROCESSOR_KEY, servlet, SERVLET_KEY, TRANSACTION_TOKEN_KEY</CODE></TD></TR></TABLE>&nbsp;<!-- ======== CONSTRUCTOR SUMMARY ======== -->

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -