|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.portal.common.invocation.Invocation org.jboss.portal.core.command.ControllerCommand org.jboss.portal.core.command.PortalObjectCommand org.jboss.portal.core.command.MarkupCommand
Abstract base class for portal object commands that produce markup (of a page, region, window).
This command contains all the shared functionality amongst all commands that create page , or page fragment markup, like the RenderPageCommand and the RenderRegionCommand.
Field Summary |
Fields inherited from class org.jboss.portal.core.command.ControllerCommand |
context, log |
Constructor Summary | |
MarkupCommand(java.lang.String pageRef)
render the entire page |
|
MarkupCommand(java.lang.String pageRef,
MarkupContainer markupContainer)
render a fragment on the page (a region or a window on the page) |
Method Summary | |
void |
create()
initialize the command |
void |
enforceSecurity(PortalAuthorizationManager pam)
Enforce the security on this command using the provided portal authorization manager. |
void |
execute()
execute the command |
CommandInfo |
getInfo()
Get the command info (runtime info about the command) |
PortalLayout |
getLayout()
Get the layout that was determined for this request (based on portal and page properties) |
static PortalLayout |
getLayout(LayoutService layoutService,
Page page)
Get the portal layout to use for the provided page. |
MarkupContainer |
getMarkupContainer()
Get the fragment identifier of the page fragment that was requested |
Page |
getPage()
Get the requeste page |
java.lang.String |
getPageRef()
Get the identifier of the requeste page |
PortalObject |
getTarget()
for security checks and navigational state, return the page of the requested MarkupContainer |
abstract MarkupResult |
renderFragments(ServerConfig cfg,
NavigationalStateContext navCtx)
call the component invocation(s) to create the markup fragment(s) for this request |
protected MarkupResult |
renderPortletWindow(ServerConfig cfg,
Window window)
Call the component container to render the markup fragment of a window |
Methods inherited from class org.jboss.portal.core.command.ControllerCommand |
destroy, dispatch, getContext, setContext |
Methods inherited from class org.jboss.portal.common.invocation.Invocation |
getAttribute, invoke, invokeNext, removeAttribute, setAttribute |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public MarkupCommand(java.lang.String pageRef)
pageRef
- the page idenitifier of the page to renderpublic MarkupCommand(java.lang.String pageRef, MarkupContainer markupContainer)
pageRef
- the page idenitifier of the page to rendermarkupContainer
- the fragment to render (the region or the window); if the argument is null, the entire page
will be renderedMethod Detail |
public abstract MarkupResult renderFragments(ServerConfig cfg, NavigationalStateContext navCtx) throws CommandException
cfg
- the server config to get config information (for error behaviour )navCtx
- the navigational state context to get to the window navigational state
InvocationException
CommandException
public PortalObject getTarget()
getTarget
in class PortalObjectCommand
public CommandInfo getInfo()
getInfo
in class ControllerCommand
public java.lang.String getPageRef()
public Page getPage()
public PortalLayout getLayout()
public MarkupContainer getMarkupContainer()
public void create() throws CommandException
create
in class ControllerCommand
InvocationException
CommandException
public void enforceSecurity(PortalAuthorizationManager pam) throws SecurityException, PortalSecurityException
PortalObjectCommand
enforceSecurity
in class PortalObjectCommand
pam
- the portal authorization manager
SecurityException
- if the access is not granted
PortalSecurityException
public final void execute() throws InvocationException
execute
in class ControllerCommand
InvocationException
public static PortalLayout getLayout(LayoutService layoutService, Page page)
The name of the layout to use can be defined as a property in the portal, or the individual page. The page property overwrites the portal property. If no property was set, a default layout with the name "nodesk" is assumed.
layoutService
- the layout service that allows access to the layoutpage
- the page that hosts the markup container to render (the page, region, window,...)
PortalLayout
for the defined layout nameprotected MarkupResult renderPortletWindow(ServerConfig cfg, Window window) throws CommandException
cfg
- the server config to get information about the error behaviourwindow
- the window to render
InvocationException
CommandException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |