com.primix.vlib.pages
Class MyLibrary
java.lang.Object
|
+--com.primix.tapestry.AbstractComponent
|
+--com.primix.tapestry.BaseComponent
|
+--com.primix.tapestry.AbstractPage
|
+--com.primix.tapestry.BasePage
|
+--com.primix.vlib.Protected
|
+--com.primix.vlib.pages.MyLibrary
- All Implemented Interfaces:
- IComponent, IErrorProperty, IPage, IRender
- public class MyLibrary
- extends Protected
Shows a list of the user's books, allowing books to be editted or
even deleted.
Note that, unlike elsewhere, book titles do not link to the
ViewBook
page. It seems to me there would be a conflict between
that behavior and the edit behavior; making the book titles not be links
removes the ambiguity over what happens when the book title is clicked
(view vs. edit).
- Version:
- $Id: MyLibrary.java,v 1.6 2001/08/15 21:28:10 hship Exp $
- Author:
- Howard Ship
Methods inherited from class com.primix.tapestry.AbstractPage |
addPageCleanupListener, addPageDetachListener, addPageRenderListener, attach, firePageBeginRender, firePageCleanup, firePageDetached, firePageEndRender, getChangeObserver, getEngine, getExtendedId, getIdPath, getLocale, getName, getNestedComponent, getPage, getRequestCycle, getVisit, renderPage, setChangeObserver, setLocale, setName, setRequestCycle |
Methods inherited from class com.primix.tapestry.AbstractComponent |
addAsset, addComponent, addWrapped, cleanupAfterRender, cleanupComponent, finishLoad, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, generateAttributes, getAsset, getAssets, getBeans, getBinding, getBindingNames, getBindings, getComponent, getComponents, getContainer, getId, getListeners, getSpecification, prepareForRender, renderWrapped, reset, setBinding, setContainer, setId, setPage, setSpecification, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.primix.tapestry.IComponent |
addAsset, addComponent, addWrapped, getAsset, getAssets, getBinding, getBindingNames, getBindings, getComponent, getComponents, getContainer, getId, getSpecification, renderWrapped, setBinding, setContainer, setId, setPage, setSpecification |
Methods inherited from interface com.primix.tapestry.IRender |
render |
MyLibrary
public MyLibrary()
detach
public void detach()
- Description copied from class:
AbstractPage
- Prepares the page to be returned to the pool.
Subclasses may override this method, but must invoke this
implementation (usually, last).
- Overrides:
detach
in class Protected
- Following copied from interface:
com.primix.tapestry.IPage
- See Also:
IPageSource.releasePage(IPage)
finishLoad
public void finishLoad(IPageLoader loader,
ComponentSpecification specification)
throws PageLoaderException
- Description copied from interface:
IComponent
- Allows a component to finish any setup after it has been constructed.
The exact timing is not
specified, but any components contained by the
receiving component will also have been constructed
before this method is invoked.
As of release 1.0.6, this method is invoked before
bindings are set. This should not affect anything, as bindings
should only be used during renderring.
- Overrides:
finishLoad
in class BaseComponent
beginResponse
public void beginResponse(IResponseWriter writer,
IRequestCycle cycle)
throws RequestCycleException
- A dirty little secret of Tapestry and page recorders: persistent
properties must be set before the render (when this method is invoked)
and can't change during the render. We force
the creation of the owned book query and re-execute it whenever
the MyLibrary page is rendered.
- Overrides:
beginResponse
in class AbstractPage
setOwnedQuery
public void setOwnedQuery(IBookQuery value)
getOwnedQuery
public IBookQuery getOwnedQuery()
- Gets the query object responsible for the finding books owned by the user.
setCurrentBook
public void setCurrentBook(Book value)
- Updates the currentBook dynamic page property.
getCurrentBook
public Book getCurrentBook()
getOmitHolderLink
public boolean getOmitHolderLink()
setMessage
public void setMessage(java.lang.String value)
getMessage
public java.lang.String getMessage()
editBook
public void editBook(java.lang.String[] context,
IRequestCycle cycle)
- Listener invoked to allow a user to edit a book.
deleteBook
public void deleteBook(java.lang.String[] context,
IRequestCycle cycle)
- Listener invoked to allow a user to delete a book.
cleanupPage
public void cleanupPage()
- Removes the book query bean.
- Overrides:
cleanupPage
in class AbstractPage