org.apache.struts2.views.velocity

## Class StrutsVelocityContext

- java.lang.Object
- - org.apache.velocity.context.AbstractContext
  - - org.apache.velocity.VelocityContext
    - - org.apache.struts2.views.velocity.StrutsVelocityContext

- All Implemented Interfaces:
    Serializable, Cloneable, org.apache.velocity.context.Context, org.apache.velocity.context.InternalEventContext

      public class StrutsVelocityContext
      extends org.apache.velocity.VelocityContext

  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `StrutsVelocityContext(List<org.apache.velocity.VelocityContext> chainedContexts, ValueStack stack)` Creates a content with link to the ValueStack and any other Velocity contexts
    `StrutsVelocityContext(ValueStack stack)` Deprecated. please use `StrutsVelocityContext(List, ValueStack)` and pass {null} or empty list if no chained contexts were defined
    `StrutsVelocityContext(org.apache.velocity.VelocityContext[] chainedContexts, ValueStack stack)` Deprecated. please use `StrutsVelocityContext(List, ValueStack)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `internalContainsKey(String key)`
    `Object` | `internalGet(String key)`

    - ### Methods inherited from class org.apache.velocity.VelocityContext

      `clone, internalGetKeys, internalPut, internalRemove`

    - ### Methods inherited from class org.apache.velocity.context.AbstractContext

      `containsKey, get, getChainedContext, getKeys, put, remove`

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

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

- - ### Constructor Detail

    - #### StrutsVelocityContext

          public StrutsVelocityContext(List<org.apache.velocity.VelocityContext> chainedContexts,
                                       ValueStack stack)

      Creates a content with link to the ValueStack and any other Velocity contexts
      Parameters:
        `chainedContexts` - Existing Velocity contexts to chain to
        `stack` - Struts ValueStack
      Since:
        6.0.0

    - #### StrutsVelocityContext

          @Deprecated
          public StrutsVelocityContext(ValueStack stack)

      Deprecated. please use `StrutsVelocityContext(List, ValueStack)` and pass {null} or empty list if no chained contexts were defined

    - #### StrutsVelocityContext

          @Deprecated
          public StrutsVelocityContext(org.apache.velocity.VelocityContext[] chainedContexts,
                                                   ValueStack stack)

      Deprecated. please use `StrutsVelocityContext(List, ValueStack)`

  - ### Method Detail

    - #### internalContainsKey

          public boolean internalContainsKey(String key)

      Overrides:
        `internalContainsKey` in class `org.apache.velocity.VelocityContext`

    - #### internalGet

          public Object internalGet(String key)

      Overrides:
        `internalGet` in class `org.apache.velocity.VelocityContext`

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