private void writeProperties(JRPropertiesHolder propertiesHolder) throws IOException
{
if (propertiesHolder.hasProperties())
{
JRPropertiesMap propertiesMap = propertiesHolder.getPropertiesMap();
String[] propertyNames = propertiesMap.getPropertyNames();
if (propertyNames != null && propertyNames.length > 0)
{
for(int i = 0; i < propertyNames.length; i++)
{
writer.startElement(JRXmlConstants.ELEMENT_property);
writer.addEncodedAttribute(JRXmlConstants.ATTRIBUTE_name, propertyNames[i]);
String value = propertiesMap.getProperty(propertyNames[i]);
if (value != null)
{
writer.addEncodedAttribute(JRXmlConstants.ATTRIBUTE_value, value);
}
writer.closeElement();