public abstract class AbstractCellExplanation extends Object implements CellExplanation
Constructor and Description |
---|
AbstractCellExplanation() |
Modifier and Type | Method and Description |
---|---|
protected String |
formatEntity(Entity entity,
boolean html,
boolean indexInFront)
Format an entity for inclusion in an explanation.
|
protected String |
getEntityNameWithoutCondition(Entity entity)
Returns an entity name without condition strings (e.g.
|
protected abstract String |
getExplanation(Cell cell,
boolean html)
Get the explanation string in the specified format.
|
String |
getExplanation(Cell cell,
ServiceProvider provider)
Get the explanation for the given cell.
|
String |
getExplanationAsHtml(Cell cell,
ServiceProvider provider)
Get the explanation in html format for the given cell
|
protected boolean |
hasIndexCondition(Entity entity)
Checks whether the given entity has an index condition.
|
protected String |
quoteText(String text,
boolean html)
Quote or otherwise format (in case of HTML) the given text.
|
public String getExplanation(Cell cell, ServiceProvider provider)
CellExplanation
getExplanation
in interface CellExplanation
cell
- the cellprovider
- provider for eventual services needed to create the
explanation, may be null
null
if none is availableCellExplanation.getExplanation(Cell, ServiceProvider)
public String getExplanationAsHtml(Cell cell, ServiceProvider provider)
CellExplanation
getExplanationAsHtml
in interface CellExplanation
cell
- the cellprovider
- provider for eventual services needed to create the
explanation, my be null
null
if none is
availableCellExplanation.getExplanationAsHtml(Cell, ServiceProvider)
protected abstract String getExplanation(Cell cell, boolean html)
cell
- the cell to create an explanation forhtml
- if the format should be HMTL, otherwise the format is just
textnull
protected String formatEntity(Entity entity, boolean html, boolean indexInFront)
entity
- the entity, may be null
html
- if the format should be HMTL, otherwise the format is just
textindexInFront
- whether index conditions should be in front of the
property name or behind in bracketsnull
in case of
null
inputprotected String getEntityNameWithoutCondition(Entity entity)
entity
- the entityprotected boolean hasIndexCondition(Entity entity)
entity
- the entity to checkBuild 2013-10-07_11-27-38
Revision 99b27713a799a59a21b0b166eaaea8aaefbf125a