public interface PortletPlacementContext
Modifier and Type | Method and Description |
---|---|
Coordinate |
add(ContentFragment fragment,
Coordinate coordinate)
Add a portlet to its managed page.
|
ContentFragment |
getFragmentAtNewCoordinate(Coordinate coordinate)
Retrieve a portlet fragment for the given coordinate.
|
ContentFragment |
getFragmentAtOldCoordinate(Coordinate coordinate)
Retrieve the old portlet fragment for the given coordinate (prior to placement).
|
ContentFragment |
getFragmentById(String fragmentId)
Retrieve a fragment by fragment id.
|
int |
getNumberColumns()
retrieve the number of columns for the managed layout.
|
int |
getNumberRows(int column)
retrieve the number of rows for the managed layout at the given column.
|
Coordinate |
moveAbsolute(ContentFragment fragment,
Coordinate coordinate)
Move a portlet fragment to a new absolute position as specified in the Coordinate parameter.
|
Coordinate |
moveAbsolute(ContentFragment fragment,
Coordinate coordinate,
boolean addFragment)
Move a portlet fragment to a new absolute position as specified in the Coordinate parameter.
|
Coordinate |
moveDown(ContentFragment fragment)
Move a portlet relative to its current position DOWN one row.
|
Coordinate |
moveLeft(ContentFragment fragment)
Move a portlet relative to its current position LEFT one column.
|
Coordinate |
moveRight(ContentFragment fragment)
Move a portlet relative to its current position RIGHT one column.
|
Coordinate |
moveUp(ContentFragment fragment)
Move a portlet relative to its current position UP one row.
|
Coordinate |
remove(ContentFragment fragment)
Remove the specified fragment.
|
ContentPage |
syncPageFragments()
Takes the internal portlet placement state and writes it back
out to the root fragment for the managed page layout.
|
ContentPage |
syncPageFragments(String scope,
String scopeValue)
Takes the internal portlet placement state and writes it back
out to the root fragment for the managed page layout.
|
Coordinate moveAbsolute(ContentFragment fragment, Coordinate coordinate) throws PortletPlacementException
fragment
- The fragment to be moved.coordinate
- The specification of the new absolute coordinatePortletPlacementException
Coordinate moveAbsolute(ContentFragment fragment, Coordinate coordinate, boolean addFragment) throws PortletPlacementException
fragment
- The fragment to be moved.coordinate
- The specification of the new absolute coordinateaddFragment
- When true, the fragment is being added (i.e. it is not being moved within the column)PortletPlacementException
Coordinate moveUp(ContentFragment fragment) throws PortletPlacementException
fragment
- The fragment to be moved.PortletPlacementException
Coordinate moveDown(ContentFragment fragment) throws PortletPlacementException
fragment
- The fragment to be moved.PortletPlacementException
Coordinate moveLeft(ContentFragment fragment) throws PortletPlacementException
fragment
- The fragment to be moved.PortletPlacementException
Coordinate moveRight(ContentFragment fragment) throws PortletPlacementException
fragment
- The fragment to be moved.PortletPlacementException
Coordinate add(ContentFragment fragment, Coordinate coordinate) throws PortletPlacementException
fragment
- The Fragment to addcoordinate
- The coordinate where to place the new portletPortletPlacementException
Coordinate remove(ContentFragment fragment) throws PortletPlacementException
fragment
- PortletPlacementException
int getNumberColumns() throws PortletPlacementException
PortletPlacementException
int getNumberRows(int column) throws PortletPlacementException
column
- the column to retrieve the number of rows forPortletPlacementException
ContentFragment getFragmentAtNewCoordinate(Coordinate coordinate) throws PortletPlacementException
coordinate
- the coordinate associated to a fragment.PortletPlacementException
ContentFragment getFragmentAtOldCoordinate(Coordinate coordinate) throws PortletPlacementException
coordinate
- the coordinate associated to a fragment.PortletPlacementException
ContentFragment getFragmentById(String fragmentId) throws PortletPlacementException
fragmentId
- a string key for a fragment managed on this layout.PortletPlacementException
ContentPage syncPageFragments(String scope, String scopeValue)
scope
- the name of the property scope to updatescopeValue
- the scope discriminator value, (unless scope is GLOBAL
or USER where the default user name is used if null)ContentPage syncPageFragments()
Copyright © 1999–2016 The Apache Software Foundation. All rights reserved.