public PageRedirectException( String message, Object component, Throwable rootCause, String targetPageName) { super(message, component, null, rootCause); _targetPageName = targetPageName; }
public PageRedirectException( String message, Object component, Throwable rootCause, String targetPageName) { super(message, component, null, rootCause); _targetPageName = targetPageName; }
public StaleSessionException(String message, IPage page) { super(message, page, null, null); _page = page; if (page != null) _pageName = page.getPageName(); else _pageName = null; }
public PageCallback(IPage page) { Defense.notNull(page, "page"); _pageName = page.getPageName(); }
public static String pageNotCompatible(IPage page, Class expectedType) { return _formatter.format("page-not-compatible", page.getPageName(), expectedType.getName()); }
public PageCallback(IPage page) { Defense.notNull(page, "page"); _pageName = page.getPageName(); }
/** * Returns the name of the page, a slash, and this component's id path. Pages are different, * they override this method to simply return their page name. * * @see #getIdPath() */ public String getExtendedId() { if (_page == null) return null; return _page.getPageName() + "/" + getIdPath(); }
/** * Returns the name of the page, a slash, and this component's id path. Pages are different, * they override this method to simply return their page name. * * @see #getIdPath() */ public String getExtendedId() { if (_page == null) return null; return _page.getPageName() + "/" + getIdPath(); }
public ILink getLink(boolean post, Object parameter) { if (parameter != null) throw new IllegalArgumentException(EngineMessages .serviceNoParameter(this)); Map parameters = new HashMap(); parameters.put(ServiceConstants.PAGE, _requestCycle.getPage() .getPageName()); return _linkFactory.constructLink(this, post, parameters, true); }
public ILink getLink(boolean post, Object parameter) { if (parameter != null) throw new IllegalArgumentException(EngineMessages .serviceNoParameter(this)); Map parameters = new HashMap(); parameters.put(ServiceConstants.PAGE, _requestCycle.getPage() .getPageName()); return _linkFactory.constructLink(this, post, parameters, true); }
/** * Creates a new ComponentAddress object that carries the identification information of the * given component (the page name and the ID path). * * @param component * the component to get the address of */ public ComponentAddress(IComponent component) { this(component.getPage().getPageName(), component.getIdPath()); }
/** * If the currently displaying page is part of the currently rendering category. */ public boolean isCurrentPageInCategory() { return isPageInCategory(getPage().getPageName()); }
/** * The category of the currently displaying page. */ public CategoryInfo getCurrentPageCategory() { return getCategoryOf(getPage().getPageName()); }
/** * Gets the pages that belong to the same category as the currently displaying one. */ public List getPagesOfCategoryOfCurrentPage() { return getPagesOfCategoryOfPage(getPage().getPageName()); }
public ILink getLink(boolean post, Object parameter) { Defense.isAssignable(parameter, IComponent.class, "parameter"); IComponent component = (IComponent) parameter; Map parameters = new HashMap(); parameters.put(ServiceConstants.PAGE, component.getPage().getPageName()); parameters.put(ServiceConstants.COMPONENT, component.getIdPath()); return _linkFactory.constructLink(this, false, parameters, true); }
/** * Creates a new DirectCallback for the component. The parameters (which may be null) is * retained, not copied. */ public DirectCallback(IDirect component, Object[] parameters) { Defense.notNull(component, "component"); _pageName = component.getPage().getPageName(); _componentIdPath = component.getIdPath(); _parameters = parameters; }
/** * Creates a new DirectCallback for the component. The parameters (which may be null) is * retained, not copied. */ public DirectCallback(IDirect component, Object[] parameters) { Defense.notNull(component, "component"); _pageName = component.getPage().getPageName(); _componentIdPath = component.getIdPath(); _parameters = parameters; }
public boolean getShowPage() { if (getShowAll()) return true; else return !getName().equals( getCategoryOf(getPage().getPageName()).getDefaultPage() ); }
public void pageBeginRender(PageEvent event) { Inspector inspector = (Inspector) getPage(); IPage inspectedPage = inspector.getInspectedPage(); String pageName = inspectedPage.getPageName(); PropertyPersistenceStrategySource source = getPropertySource(); Collection properties = source.getAllStoredChanges(pageName); // TODO: sorting setProperties(new ArrayList(properties)); }
/** * Gets the listener for the link component. * * @since 1.0.5 */ public void trigger(IRequestCycle cycle) { String name = getNamespace().constructQualifiedName("Inspector"); Inspector inspector = (Inspector) cycle.getPage(name); inspector.inspect(getPage().getPageName(), cycle); }