org.apache.struts2.factory

## Class StrutsResultFactory

- java.lang.Object
- - org.apache.struts2.factory.StrutsResultFactory

- All Implemented Interfaces:
    ResultFactory

      public class StrutsResultFactory
      extends Object
      implements ResultFactory

  Default implementation which uses `ParamNameAwareResult` to accept or throw away parameters

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected ObjectFactory` | `objectFactory`
    `protected ReflectionProvider` | `reflectionProvider`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `StrutsResultFactory()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `Result` | `buildResult(ResultConfig resultConfig, Map<String,Object> extraContext)`
    `void` | `setObjectFactory(ObjectFactory objectFactory)`
    `protected void` | `setParameter(Result result, String name, String value, Map<String,Object> extraContext)`
    `protected void` | `setParameters(Map<String,Object> extraContext, Result result, Map<String,String> params)`
    `void` | `setReflectionProvider(ReflectionProvider provider)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### objectFactory

          protected ObjectFactory objectFactory

    - #### reflectionProvider

          protected ReflectionProvider reflectionProvider

  - ### Constructor Detail

    - #### StrutsResultFactory

          public StrutsResultFactory()

  - ### Method Detail

    - #### setObjectFactory

          public void setObjectFactory(ObjectFactory objectFactory)

    - #### setReflectionProvider

          public void setReflectionProvider(ReflectionProvider provider)

    - #### buildResult

          public Result buildResult(ResultConfig resultConfig,
                           Map<String,Object> extraContext)
                             throws Exception

      Specified by:
        `buildResult` in interface `ResultFactory`
      Throws:
        `Exception`

    - #### setParameters

          protected void setParameters(Map<String,Object> extraContext,
                           Result result,
                           Map<String,String> params)

    - #### setParameter

          protected void setParameter(Result result,
                          String name,
                          String value,
                          Map<String,Object> extraContext)

Copyright © 2000–2021 Apache Software Foundation. All rights reserved.