© 2003 BEA Systems, Inc.

com.bea.netuix.servlets.controls.page
Class BookBackingContext

java.lang.Object
  |
  +--com.bea.netuix.servlets.controls.ControlContext
        |
        +--com.bea.netuix.servlets.controls.BackingContext
              |
              +--com.bea.netuix.servlets.controls.window.backing.WindowBackingContext
                    |
                    +--com.bea.netuix.servlets.controls.page.PageBackingContext
                          |
                          +--com.bea.netuix.servlets.controls.page.BookBackingContext
All Implemented Interfaces:
Serializable

public class BookBackingContext
extends PageBackingContext

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.bea.netuix.servlets.controls.ControlContext
debug
 
Constructor Summary
BookBackingContext(Book book)
           
 
Method Summary
 PageBackingContext getActivePageBackingContext()
          Return the PageBackingContext of the active Page or null if there is none.
static BookBackingContext getBookBackingContext(HttpServletRequest request)
          Obtain a reference to the current BookBackingContext in the request.
 BackingContext getContainerParentBackingContext()
          Returns the next "container" (Window, Page, or Book) ancestor BackingContext.
 String getCurrentPage()
          Returns the instanceId of the current Page
 String getDefaultPage()
          Return the value of the underlying control's defaultPage attribute.
 List getEntitledPages()
          Deprecated. use getPageBackingContexts()
 PageBackingContext getPageBackingContextByDefinitionLabel(String definitionLabel)
          Returns the PageBackingContext of the child Page specified by definitionLabel.
 PageBackingContext getPageBackingContextByInstanceId(String instanceId)
          Returns the PageBackingContext of the child Page specified by instanceId.
 PageBackingContext getPageBackingContextByUnqiueId(String uniqueId)
          Returns the PageBackingContext of the child Page specified by uniqueId.
 List getPageBackingContexts()
          Return the collection of BackingContexts (BookBackingContexts and PageBackingContexts) for the Pages and Books contatined by the Book this BackingContext represents.
 int getPageCount()
          Return the number of pages contained in the Book this BackingContext represents.
 List getPages()
          Deprecated. use getPageBackingContexts()
 boolean isContained()
          Returns true if the Book represented by this backing context is "contained", that is if the the Book's next Book, Window, or Page ancestor is a Book or Window then it is contained and this method will return true.
 boolean isDesktopBook()
          Returns true if the Book represented by this backing context is the desktop Book anotherwords is it the top most Book in the control tree.
 boolean isLikePage()
          Indicates whether or not the underlying book is a page in another book.
 
Methods inherited from class com.bea.netuix.servlets.controls.page.PageBackingContext
getActiveImage, getInactiveImage, getLabel, getMarkupName, getMarkupType, getPageBackingContext, getParentBookBackingContext, getParentPageBackingContext, getRolloverImage, getWindowBackingContexts, isActive, isDisplayed, isHidden, setActive, setActiveImage, setHidden, setInactiveImage, setRolloverImage
 
Methods inherited from class com.bea.netuix.servlets.controls.window.backing.WindowBackingContext
getCapabilityVisible, getDefinitionId, getDefinitionLabel, getDescription, getInstanceId, getOrientation, getParentWindowBackingContext, getPlacementId, getPreviousWindowMode, getPreviousWindowState, getRenderedChildrenWindowBackingContexts, getTitle, getWindowMode, getWindowState, isCapable, isPacked, setCapabilityVisible, setDescription, setTitle, setupModeChangeEvent, setupModeChangeEvent, setupPageChangeEvent, setupStateChangeEvent
 
Methods inherited from class com.bea.netuix.servlets.controls.BackingContext
getChildrenBackingContexts, getContextFromRequest, getParentBackingContext, getTopParentBackingContext, isBackingPhase, isVisible, setBackingPhase, setVisible
 
Methods inherited from class com.bea.netuix.servlets.controls.ControlContext
getContextKey, getControl, getRequestKey, getUniqueId, removeContextFromRequest, setContextInRequest
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BookBackingContext

public BookBackingContext(Book book)
Method Detail

isDesktopBook

public boolean isDesktopBook()
Returns true if the Book represented by this backing context is the desktop Book anotherwords is it the top most Book in the control tree.


isContained

public boolean isContained()
Returns true if the Book represented by this backing context is "contained", that is if the the Book's next Book, Window, or Page ancestor is a Book or Window then it is contained and this method will return true.


getActivePageBackingContext

public PageBackingContext getActivePageBackingContext()
Return the PageBackingContext of the active Page or null if there is none.

Returns:
the PageBackingContext of the active Page or null if there is none.
See Also:
Book.getActivePage()

getCurrentPage

public String getCurrentPage()
Returns the instanceId of the current Page

Returns:
the instanceId of the current Page
See Also:
Book.getCurrentPage()

getDefaultPage

public String getDefaultPage()
Return the value of the underlying control's defaultPage attribute.

Returns:
a String, the value of the underlying control's defaultPage attribute.

getPageBackingContextByInstanceId

public PageBackingContext getPageBackingContextByInstanceId(String instanceId)
Returns the PageBackingContext of the child Page specified by instanceId. If the Page is not found null is returned.


getPageBackingContextByUnqiueId

public PageBackingContext getPageBackingContextByUnqiueId(String uniqueId)
Returns the PageBackingContext of the child Page specified by uniqueId. If the Page is not found null is returned.


getPageBackingContextByDefinitionLabel

public PageBackingContext getPageBackingContextByDefinitionLabel(String definitionLabel)
Returns the PageBackingContext of the child Page specified by definitionLabel. If the Page is not found null is returned.


getPageCount

public int getPageCount()
Return the number of pages contained in the Book this BackingContext represents.

Returns:
the number of pages contained in the Book this BackingContext represents.
See Also:
Book.getPageCount()

getPageBackingContexts

public List getPageBackingContexts()
Return the collection of BackingContexts (BookBackingContexts and PageBackingContexts) for the Pages and Books contatined by the Book this BackingContext represents. This list is entitled. If no pagees or books exist returns an empty list.


getPages

public List getPages()
Deprecated. use getPageBackingContexts()

Return the collection of BackingContexts (BookBackingContexts and PageBackingContexts) for the Pages and Books contatined by the Book this BackingContext represents. If no windows exist returns an empty list.


getEntitledPages

public List getEntitledPages()
Deprecated. use getPageBackingContexts()

Return the collection of entitled BackingContexts (BookBackingContexts and PageBackingContexts) for the Pages and Books contatined by the Book this BackingContext represents. This method filters out pages that are hidden or not entitled to view.

Returns:
an List of PageBackingContext/BookBackingContext objects. If not pages present an empty list.

getBookBackingContext

public static BookBackingContext getBookBackingContext(HttpServletRequest request)

Obtain a reference to the current BookBackingContext in the request. Note: the BookBackingCOntext shuold on be obtained from a backing file. If you think you need this context from a JSP look at BookPresentationContext.

Parameters:
request - http servlet request.
Returns:
a refence to the BookBackingContext or null if noe exist.

isLikePage

public boolean isLikePage()
Indicates whether or not the underlying book is a page in another book.

Returns:
true if underlying book is a page in another book

getContainerParentBackingContext

public BackingContext getContainerParentBackingContext()
Returns the next "container" (Window, Page, or Book) ancestor BackingContext.

Returns:
the next "container" (Window, Page, or Book) ancestor BackingContext or null if there is none

© 2003 BEA Systems, Inc.

Copyright © 2003 BEA Systems, Inc. All Rights Reserved