Class Gadget
- java.lang.Object
-
- org.xwiki.rendering.macro.dashboard.Gadget
-
public class Gadget extends Object
Abstraction for a gadget to put on a dashboard, to contain its title, content and position.- Since:
- 3.0M3
- Version:
- $Id: 914af736ee7d14cb54a4583a0b7a788b356ad204 $
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<org.xwiki.rendering.block.Block>
getContent()
String
getId()
String
getPosition()
List<org.xwiki.rendering.block.Block>
getTitle()
String
getTitleSource()
void
setContent(List<org.xwiki.rendering.block.Block> content)
void
setId(String id)
void
setPosition(String position)
void
setTitle(List<org.xwiki.rendering.block.Block> title)
void
setTitleSource(String titleSource)
-
-
-
Constructor Detail
-
Gadget
public Gadget(String id, List<org.xwiki.rendering.block.Block> title, List<org.xwiki.rendering.block.Block> content, String position)
Creates a gadget from a title, content and position.- Parameters:
id
- the id of this gadgettitle
- the title of the gadgetcontent
- the content of the gadgetposition
- the position of the gadget
-
-
Method Detail
-
getTitle
public List<org.xwiki.rendering.block.Block> getTitle()
- Returns:
- the title
-
setTitle
public void setTitle(List<org.xwiki.rendering.block.Block> title)
- Parameters:
title
- the title to set
-
getContent
public List<org.xwiki.rendering.block.Block> getContent()
- Returns:
- the content
-
setContent
public void setContent(List<org.xwiki.rendering.block.Block> content)
- Parameters:
content
- the content to set
-
getPosition
public String getPosition()
- Returns:
- the position
-
setPosition
public void setPosition(String position)
- Parameters:
position
- the position to set
-
getId
public String getId()
- Returns:
- the id of this gadget, to render in the content
-
setId
public void setId(String id)
- Parameters:
id
- the id to set to this gadget
-
getTitleSource
public String getTitleSource()
- Returns:
- the titleSource FIXME: this should be passed in a different way, potentially in metadata block attached to the title block. FTM, to make it backwards compatible, keep it like this.
-
setTitleSource
public void setTitleSource(String titleSource)
- Parameters:
titleSource
- the titleSource to set
-
-