com.bea.netuix.servlets.controls.layout
Class GridLayoutPresentationContext
java.lang.Object
|
+--com.bea.netuix.servlets.controls.ControlContext
|
+--com.bea.netuix.servlets.controls.PresentationContext
|
+--com.bea.netuix.servlets.controls.layout.LayoutPresentationContext
|
+--com.bea.netuix.servlets.controls.layout.GridLayoutPresentationContext
- All Implemented Interfaces:
- Serializable
- public class GridLayoutPresentationContext
- extends LayoutPresentationContext
- See Also:
- Serialized Form
Methods inherited from class com.bea.netuix.servlets.controls.PresentationContext |
getChildren, getChildren, getControlState, getFirstChild, getParsedProperties, getPresentationClass, getPresentationId, getPresentationStyle, getProperties, getProperty, getProperty, getPropertyAsBoolean, getPropertyAsInt, getResolvedLocale, getTagName, isVisible, render, setVisible |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DEFAULT_GRID_COLUMNS
public static final int DEFAULT_GRID_COLUMNS
- See Also:
- Constant Field Values
GridLayoutPresentationContext
protected GridLayoutPresentationContext(Layout layout)
getColumns
public int getColumns()
getRows
public int getRows()
isRowMajor
public boolean isRowMajor()
getPlaceholderGrid
public PlaceholderPresentationContext[][] getPlaceholderGrid()
- This method arranges the placeholder context children of this layout into an n-by-m grid, ready for rendering.
The grid layout logic is as follows:
-
First, the "columns" property is checked. If it exists and is greater than zero in value, then a row-major
approach is used for rendering placeholders. That is, placement of placeholder content proceeds left to
right, starting a new row every time the "columns" value is reached.
-
If the "columns" property is found to either not exist or be less than or equal to zero, then the "rows"
property is checked. If it's value exists and is greater than zero, then a column-major approach is used
for rendering placeholders. That is, placement of placeholder content proceeds top to bottom, starting a
new column every time the "rows" value is reached.
-
If neither rows nor columns has a value specified, then the grid layout uses a hardcoded default fill
strategy. This strategy is a row-major approach using the default "columns" value of "3".
-
Lastly, if the last column or row to be assigned placeholders cannot be completely filled due to
insufficient remaining placeholders, the column or row is filled to the end with empty cells.
getGridLayoutPresentationContext
public static GridLayoutPresentationContext getGridLayoutPresentationContext(HttpServletRequest request)
Copyright © 2003 BEA Systems, Inc. All Rights Reserved