public abstract class AbstractGxpResult extends Object implements Result
The abstract base class for our Struts 2 GXP result type implementation. It outputs GXP, and pulls GXP parameters from Struts 2's value stack. Implementing classes have to:
execute(ActionInvocation), which must instruct the
 GXP to write itself to the output stream. See GxpResult for a
 sample implementation.public static final field DEFAULT_PARAM with
 the value 'gxpName'. Struts 2 needs this to set the name of your
 template into this object.If you want to use instantiated GXPs (using the nested
 Interface), you can set the useuseInstances parameter to
 true:
 
     <result-types>
       <result-type name="gxp" class="org.apache.struts2.views.gxp.GxpResult">
         <param name="useInstances">true</param>
       </result-type>
     </result-types>
 
 
 This means that Struts 2 will attempt to instantiate the Interface
 using the ObjectFactory. If
 com.google.webwork.GuiceWebWorkIntegrationModule is installed, or
 com.google.webwork.ContainerObjectFactory is set as the static
 ObjectFactory instance, then Guice will be used to instantiate the
 GXP instance; otherwise, only GXPs with no constructor parameters will work.
 
| Modifier and Type | Class and Description | 
|---|---|
| protected static class  | AbstractGxpResult.DefaultProviderUses reasonable defaults to provide resources. | 
| protected static interface  | AbstractGxpResult.GxpResourceProviderProvides resources necessary to execute a GXP. | 
Result.LegacyAdapter| Constructor and Description | 
|---|
| AbstractGxpResult() | 
| Modifier and Type | Method and Description | 
|---|---|
| protected String | getGxpName() | 
| protected boolean | getUseInstances() | 
| void | setGxpName(String gxpName) | 
| void | setUseInstances(boolean useInstances) | 
Copyright © 2000–2025 Apache Software Foundation. All rights reserved.