Overview | Package | Class | Tree | Deprecated | Index | Help
| © 2004 BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.netuix.servlets.controls.page
Class PagePresentationContext

    java.lang.Object
      com.bea.netuix.servlets.controls.ControlContext
          com.bea.netuix.servlets.controls.PresentationContext
              com.bea.netuix.servlets.controls.window.WindowPresentationContext
                  com.bea.netuix.servlets.controls.page.PagePresentationContext

All Implemented Interfaces:
  Serializable

Direct Known Subclasses:
  BookPresentationContext

public class PagePresentationContext
extends WindowPresentationContext

This class represents a portal page component. All presentation-related attributes of a page component are available from instances of this class. Such instances are typically used during portal rendering via look and feel skeleton files (e.g. page.jsp).

See Also:
  `getPagePresentationContext(javax.servlet.http.HttpServletRequest)`, Serialized Form

Method Summary
`String` | `getActiveImage()` Returns the webapp-qualified path to a fully skinned, classified, localized, and themed image to be displayed when this page is active.
`BookPresentationContext` | `getBookPresentationContextRecursive(String definitionLabel)` Returns a book, searching the entire tree recursively.
`String` | `getInactiveImage()` Returns the webapp-qualified path to a fully skinned, classified, localized, and themed image to be displayed when this page is inactive.
`String` | `getLabel()` Return the label for this page.
`static PagePresentationContext` | `getPagePresentationContext(HttpServletRequest request)` This is a convenience method for returning a reference to the current `PagePresentationContext`.
`PagePresentationContext` | `getPagePresentationContextRecursive(String definitionLabel)` Returns a book or a page but traverse the entire tree; this will go inside books that are on pages too.
`PortletPresentationContext` | `getPortletPresentationContextRecursive(String instanceLabel)` Returns the `PortletPresentationContext` matching the supplied instance label.
`PortletPresentationContext[]` | `getPortletsPresentationContextRecursive(String definitionLabel)` Returns an array of `PortletPresentationContext`s matching the supplied definition label.
`String` | `getRolloverImage()` Returns the webapp-qualified path to a fully skinned, classified, localized, and themed image to be displayed when this page is inactive.
`List` | `getWindowPresentationContexts()` Return the collection of child WindowPresentationContexts (`BookPresentationContext` or `PortletPresentationContext`) for this page.
`boolean` | `isActive()` Return true if this page is active.
`boolean` | `isDisplayed()` Return true if this page is being displayed.
`boolean` | `isHidden()` A hidden page is a page that does not show up as a tab in a book's menu.
`boolean` | `isVisible()` Returns true if this page is visible.

Methods inherited from class com.bea.netuix.servlets.controls.window.WindowPresentationContext
`getContentPresentationClass, getContentPresentationContextChildren, getContentPresentationStyle, getDefinitionId, getDefinitionLabel, getInstanceId, getOrientation, getParentPagePresentationContext, getPreviousWindowMode, getTitle, getWindowMode, getWindowPresentationContext, getWindowState, isCapable, isPacked`

Methods inherited from class com.bea.netuix.servlets.controls.PresentationContext
`getChildren, getChildren, getFirstChild, getParsedProperties, getPresentationClass, getPresentationId, getPresentationStyle, getProperties, getProperty, getProperty, getPropertyAsBoolean, getPropertyAsInt, getResolvedLocale, getTagName, setVisible`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### isHidden

    public boolean isHidden()

  A hidden page is a page that does not show up as a tab in a book's menu. It may still be activated via links and events, however.

  Returns:
    True, if this is a hidden page

### isActive

    public boolean isActive()

  Return true if this page is active. Note this is different from `isDisplayed()` in that an active page is not necessarily always displayed, since the parent book may not itself be active. Active pages can have an inactive parent book but when the parent is activated again the current page is remembered.

  Returns:
    True, if the page is active.

### isVisible

    public boolean isVisible()

  Returns true if this page is visible. Note that this is different from `isDisplayed()` and `isActive()`. Generaly this method is useless as the pages that are not being displayed are `suspended` and never get visible set to false. It is recommended that you use `isDisplayed()` or `isActive()` instead.

  Overrides:
    `isVisible` in class `PresentationContext`
  Returns:
    True if the page is visible

### isDisplayed

    public boolean isDisplayed()

  Return true if this page is being displayed. Note that this is different from `isActive()` in that an active page is not necessarily always displayed, since the parent book may not be active.

  Returns:
    True, if the page is displayed

### getLabel

    public String getLabel()

  Return the label for this page. This is equivalent to calling `WindowPresentationContext.getDefinitionLabel()`.

  Specified by:
    `getLabel` in class `WindowPresentationContext`
  Returns:
    The page's label

### getPagePresentationContext

    public static PagePresentationContext getPagePresentationContext(HttpServletRequest request)

  This is a convenience method for returning a reference to the current `PagePresentationContext`. Note this method will only work if called from within a portal (typically, from the page.jsp skeleton). This method may return null if called when no appropriate context exists, but such a context should safely exist when being fetched from the associated skeleton JSP during normal portal rendering.

  Parameters:
    `request` - The current HTTPServletRequest instance
  Returns:
    A reference to the current PagePresentationContext, if any

### getWindowPresentationContexts

    public List getWindowPresentationContexts()

  Return the collection of child WindowPresentationContexts (`BookPresentationContext` or `PortletPresentationContext`) for this page. If no child portlets and books exist, this returns an empty list.

  Returns:
    A list of BookPresentationContext and PortletPresentationContexts objects

### getActiveImage

    public String getActiveImage()

  Returns the webapp-qualified path to a fully skinned, classified, localized, and themed image to be displayed when this page is active. Such an image may be optionally displayed in the page tab of it's parent book's menu. This setting is optional, so this method may return null.

  Returns:
    The path to the active image for this page; null if not set

### getInactiveImage

    public String getInactiveImage()

  Returns the webapp-qualified path to a fully skinned, classified, localized, and themed image to be displayed when this page is inactive. Such an image may be optionally displayed in the page tab of it's parent book's menu. This setting is optional, so this method may return null.

  Returns:
    The path to the active image for this page; null if not set

### getRolloverImage

    public String getRolloverImage()

  Returns the webapp-qualified path to a fully skinned, classified, localized, and themed image to be displayed when this page is inactive. Such an image may be optionally displayed in the page tab of it's parent book's menu. This setting is optional, so this method may return null.

  Returns:
    The path to the active image for this page; null if not set

### getBookPresentationContextRecursive

    public BookPresentationContext getBookPresentationContextRecursive(String definitionLabel)

  Returns a book, searching the entire tree recursively. If you are interested in both books AND pages use `getPagePresentationContextRecursive(java.lang.String)` as that method returns both.

  Parameters:
    `definitionLabel` - The definitionLabel of the desired book
  Returns:
    The Book of interest or null if not found.

### getPagePresentationContextRecursive

    public PagePresentationContext getPagePresentationContextRecursive(String definitionLabel)

  Returns a book or a page but traverse the entire tree; this will go inside books that are on pages too.

  Parameters:
    `definitionLabel` - The definitionLabel of the desired page
  Returns:
    PagePresentationContext (or BookPresentationContext if a book) of the page or book with a matching definition label

### getPortletPresentationContextRecursive

    public PortletPresentationContext getPortletPresentationContextRecursive(String instanceLabel)

  Returns the `PortletPresentationContext` matching the supplied instance label.

  Parameters:
    `instanceLabel` - The Unique instance label of the desired portlet
  Returns:
    A reference to the PortletPresentationContext if it exists; null otherwise

### getPortletsPresentationContextRecursive

    public PortletPresentationContext[] getPortletsPresentationContextRecursive(String definitionLabel)

  Returns an array of `PortletPresentationContext`s matching the supplied definition label. Since many portlets can share the same definition label, more then one portlet can be returned. If you are interested in just one portlet then try `getPortletPresentationContextRecursive(java.lang.String)`.

  Parameters:
    `definitionLabel` - The label of the portlet(s)
  Returns:
    A non-null array of PortletPresentationContexts

Overview | Package | Class | Tree | Deprecated | Index | Help
| © 2004 BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004 BEA Systems, Inc. All Rights Reserved