{
b.append(value);
}
else if (value instanceof Expression)
{
final MetaData metaData =
ExpressionRegistry.getInstance().getExpressionMetaData(value.getClass().getName());
if (metaData != null)
{
b.append(metaData.getDisplayName(Locale.getDefault()));
}
else
{
b.append(String.valueOf(value));
}
}
else if (value instanceof ReportElement)
{
final Element element = (Element) value;
final MetaData metaData = element.getElementType().getMetaData();
if (metaData != null)
{
b.append(metaData.getDisplayName(Locale.getDefault()));
}
else
{
b.append(String.valueOf(value));
}
}
else if (value instanceof ReportPreProcessor)
{
final ReportPreProcessorMetaData metaData =
ReportPreProcessorRegistry.getInstance().getReportPreProcessorMetaData(value.getClass().getName());
if (metaData != null)
{
b.append(metaData.getDisplayName(Locale.getDefault()));
}
else
{
b.append(String.valueOf(value));
}