/** @since 3.0 */ public void activate(IPage page) { Defense.notNull(page, "page"); if (LOG.isDebugEnabled()) LOG.debug("Activating page " + page); Tapestry.clearMethodInvocations(); page.validate(this); Tapestry.checkMethodInvocation(Tapestry.ABSTRACTPAGE_VALIDATE_METHOD_ID, "validate()", page); _page = page; }
/** @since 3.0 */ public void activate(IPage page) { Defense.notNull(page, "page"); if (LOG.isDebugEnabled()) LOG.debug("Activating page " + page); Tapestry.clearMethodInvocations(); page.validate(this); Tapestry.checkMethodInvocation(Tapestry.ABSTRACTPAGE_VALIDATE_METHOD_ID, "validate()", page); _page = page; }
/** * Returns the page to the appropriate pool. Invokes {@link IPage#detach()}. */ public void releasePage(IPage page) { Tapestry.clearMethodInvocations(); page.detach(); Tapestry.checkMethodInvocation(Tapestry.ABSTRACTPAGE_DETACH_METHOD_ID, "detach()", page); PageKey key = buildKey(page); try { _pool.returnObject(key, page); } catch (Exception ex) { if (RuntimeException.class.isInstance(ex)) throw (RuntimeException)ex; else throw new ApplicationRuntimeException(PageloadMessages.errorPagePoolGet(key), ex); } }
/** * Returns the page to the appropriate pool. Invokes {@link IPage#detach()}. */ public void releasePage(IPage page) { Tapestry.clearMethodInvocations(); page.detach(); Tapestry.checkMethodInvocation(Tapestry.ABSTRACTPAGE_DETACH_METHOD_ID, "detach()", page); PageKey key = buildKey(page); try { _pool.returnObject(key, page); } catch (Exception ex) { if (RuntimeException.class.isInstance(ex)) throw (RuntimeException)ex; else throw new ApplicationRuntimeException(PageloadMessages.errorPagePoolGet(key), ex); } }