org.apache.struts2.portlet

## Enum PortletPhase

- java.lang.Object
- - java.lang.Enum<PortletPhase>
  - - org.apache.struts2.portlet.PortletPhase

- All Implemented Interfaces:
    Serializable, Comparable<PortletPhase>

      public enum PortletPhase
      extends Enum<PortletPhase>

  Defines phases of portlet processing per the portlet specification.

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `ACTION_PHASE` Constant used for the action phase ( `Portlet.processAction(javax.portlet.ActionRequest, javax.portlet.ActionResponse)`)
    `EVENT_PHASE` Constant used for the event phase
    `RENDER_PHASE` Constant used for the render phase ( `Portlet.render(javax.portlet.RenderRequest, javax.portlet.RenderResponse)`)
    `SERVE_RESOURCE_PHASE` Constant used for the serve resource phase that was added with the 2.0 portlet specification.

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `isAction()`
    `boolean` | `isEvent()`
    `boolean` | `isRender()`
    `boolean` | `isResource()`
    `static PortletPhase` | `valueOf(String name)` Returns the enum constant of this type with the specified name.
    `static PortletPhase[]` | `values()` Returns an array containing the constants of this enum type, in the order they are declared.

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

      `clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

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

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Enum Constant Detail

    - #### RENDER_PHASE

          public static final PortletPhase RENDER_PHASE

      Constant used for the render phase ( `Portlet.render(javax.portlet.RenderRequest, javax.portlet.RenderResponse)`)

    - #### ACTION_PHASE

          public static final PortletPhase ACTION_PHASE

      Constant used for the action phase ( `Portlet.processAction(javax.portlet.ActionRequest, javax.portlet.ActionResponse)`)

    - #### EVENT_PHASE

          public static final PortletPhase EVENT_PHASE

      Constant used for the event phase

    - #### SERVE_RESOURCE_PHASE

          public static final PortletPhase SERVE_RESOURCE_PHASE

      Constant used for the serve resource phase that was added with the 2.0 portlet specification.

  - ### Method Detail

    - #### values

          public static PortletPhase[] values()

      Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:

          for (PortletPhase c : PortletPhase.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static PortletPhase valueOf(String name)

      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
        `name` - the name of the enum constant to be returned.
      Returns:
        the enum constant with the specified name
      Throws:
        `IllegalArgumentException` - if this enum type has no constant with the specified name
        `NullPointerException` - if the argument is null

    - #### isRender

          public boolean isRender()

    - #### isAction

          public boolean isAction()

    - #### isEvent

          public boolean isEvent()

    - #### isResource

          public boolean isResource()

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