public class CmsContainerBean extends java.lang.Object
Constructor and Description |
---|
CmsContainerBean(java.lang.String name,
java.lang.String type,
java.lang.String parentInstanceId,
int maxElements,
java.util.List<CmsContainerElementBean> elements)
Creates a new container bean.
|
CmsContainerBean(java.lang.String name,
java.lang.String type,
java.lang.String parentInstanceId,
java.util.List<CmsContainerElementBean> elements)
Creates a new container bean with an unlimited number of elements.
|
Modifier and Type | Method and Description |
---|---|
boolean |
containsElement(CmsUUID elementId)
Returns
true if the element with the provided id is contained in this container. |
java.util.Map<CmsUUID,java.lang.Boolean> |
getContainsElement()
Returns a lazy initialized map that describes if a certain element if part of this container.
|
java.util.List<CmsUUID> |
getElementIds()
Returns the id's of all elements in this container.
|
java.util.List<CmsContainerElementBean> |
getElements()
Returns the elements in this container.
|
int |
getMaxElements()
Returns the maximal number of elements in this container.
|
java.lang.String |
getName()
Returns the name of this container.
|
java.lang.String |
getParam()
Returns the (optional) container parameter.
|
java.lang.String |
getParentInstanceId()
Returns the the parent instance id.
|
java.lang.String |
getType()
Returns the type of this container.
|
java.lang.String |
getWidth()
Returns the container width set by the rendering container tag.
|
boolean |
isDetailOnly()
Returns if this container is used on detail pages only.
|
boolean |
isNestedContainer()
Returns if the given container is a nested container.
|
void |
setDetailOnly(boolean detailOnly)
Sets if this container is used on detail pages only.
|
void |
setMaxElements(int maxElements)
Sets the maximal number of elements in the container.
|
void |
setParam(java.lang.String param)
Sets the container parameter.
|
void |
setType(java.lang.String type)
Sets the container type.
|
void |
setWidth(java.lang.String width)
Sets the client side render with of this container.
|
public CmsContainerBean(java.lang.String name, java.lang.String type, java.lang.String parentInstanceId, int maxElements, java.util.List<CmsContainerElementBean> elements)
name
- the container nametype
- the container typeparentInstanceId
- the parent instance idmaxElements
- the maximal number of elements in the containerelements
- the elementspublic CmsContainerBean(java.lang.String name, java.lang.String type, java.lang.String parentInstanceId, java.util.List<CmsContainerElementBean> elements)
name
- the container nametype
- the container typeparentInstanceId
- the parent instance idelements
- the elementspublic boolean containsElement(CmsUUID elementId)
true
if the element with the provided id is contained in this container.elementId
- the element id to checktrue
if the element with the provided id is contained in this containerpublic java.util.Map<CmsUUID,java.lang.Boolean> getContainsElement()
public java.util.List<CmsUUID> getElementIds()
public java.util.List<CmsContainerElementBean> getElements()
public int getMaxElements()
public java.lang.String getName()
public java.lang.String getParam()
This is useful for a dynamically generated nested container,
to pass information to the formatter used inside that container.
If no parameters have been set, this will return null
public java.lang.String getParentInstanceId()
public java.lang.String getType()
public java.lang.String getWidth()
public boolean isDetailOnly()
true
if this container is used on detail pages onlypublic boolean isNestedContainer()
true
if the given container is a nested containerpublic void setDetailOnly(boolean detailOnly)
detailOnly
- true
if this container is used on detail pages onlypublic void setMaxElements(int maxElements)
maxElements
- the maximal number of elements to setpublic void setParam(java.lang.String param)
This is useful for a dynamically generated nested container, to pass information to the formatter used inside that container.
param
- the parameter String to setpublic void setType(java.lang.String type)
type
- the container typepublic void setWidth(java.lang.String width)
width
- the client side render with of this container