Overview | Package | Class | Tree | Deprecated | Index | Help
| Portlet API 2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.jetspeed.portlet
Interface PortletWindow

public interface PortletWindow

The `PortletWindow` represents the window that encloses a portlet. The portlet window can send events on manipulation of its various window controls, like the "minimize" or "close" buttons. But a portlet also interrogate the portlet window about its current visibility state. For example, a portlet may render its content differently depending on whether its window is maximized or not.

Method Summary
`void` | `addWindowListener(WindowListener listener)` Adds the given listener to receive window events from this portlet window.
`boolean` | `isClosed()` Returns whether this portlet window is currently closed.
`boolean` | `isDetached()` Returns whether this portlet window is currently detached.
`boolean` | `isMaximized()` Returns whether this portlet window is currently maximized.
`boolean` | `isMinimized()` Returns whether this portlet window is currently minimized.
`void` | `removeWindowListener(WindowListener listener)` Removes the given listener from receiving window events from this portlet window.
`void` | `setClosed(boolean aFlag)` Sets this window to be closed.
`void` | `setDetached(boolean aFlag)` Sets this window to be detached.
`void` | `setMaximized(boolean aFlag)` Sets this window to be maximized.
`void` | `setMinimized(boolean aFlag)` Sets this window to be minimized.
`void` | `setTitle(PortletTitle title)` Sets the given title to be the title of this window.

Method Detail

### addWindowListener

    public void addWindowListener(WindowListener listener)

  Adds the given listener to receive window events from this portlet window.

  If the given listener is `null`, this method does nothing.

  Parameters:
    `listener` - the listener to be added

### removeWindowListener

    public void removeWindowListener(WindowListener listener)

  Removes the given listener from receiving window events from this portlet window.

  If the given listener is `null`, this method does nothing.

  Parameters:
    `listener` - the listener to be removed

### setTitle

    public void setTitle(PortletTitle title)

  Sets the given title to be the title of this window. This method should only be called if a dynamic title is required. Otherwise, the portlet container uses the title from the portlet configuration.
  Parameters:
    `title` - the portlet title

### isDetached

    public boolean isDetached()

  Returns whether this portlet window is currently detached.
  Returns:
    `true` if this window is detached,
    `false` otherwise

### isMaximized

    public boolean isMaximized()

  Returns whether this portlet window is currently maximized.
  Returns:
    `true` if this window is maximized,
    `false` otherwise

### isMinimized

    public boolean isMinimized()

  Returns whether this portlet window is currently minimized.
  Returns:
    `true` if this window is minimized,
    `false` otherwise

### isClosed

    public boolean isClosed()

  Returns whether this portlet window is currently closed.
  Returns:
    `true` if this window is closed,
    `false` otherwise

### setDetached

    public void setDetached(boolean aFlag)

  Sets this window to be detached. If the portlet container does not support detachable portlet windows, this method does nothing.
  Parameters:
    `aFlag` - a flag whether or not to detach this window

### setMinimized

    public void setMinimized(boolean aFlag)

  Sets this window to be minimized. If the portlet container does not support minimizable portlet windows, this method does nothing.
  Parameters:
    `aFlag` - a flag whether or not to minimize this window

### setMaximized

    public void setMaximized(boolean aFlag)

  Sets this window to be maximized. If the portlet container does not support maximizable portlet windows, this method does nothing.
  Parameters:
    `aFlag` - a flag whether or not to maximize this window

### setClosed

    public void setClosed(boolean aFlag)

  Sets this window to be closed. If the portlet container does not support closable portlet windows, this method does nothing.
  Returns:
    `true` if this window is closed,
    `false` otherwise

Overview | Package | Class | Tree | Deprecated | Index | Help
| Portlet API 2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD