protected void checkExistingName(String name) throws JRException { if (getStyle(name) != null) { throw new JRException("Duplicate declaration of template style : " + name); } }
protected void setParentStyle(JRDesignStyle currentStyle, String parentStyleName) { JRSimpleTemplate template = (JRSimpleTemplate) digester.peek(digester.getCount() - 1); JRStyle parent = template.getStyle(parentStyleName); if (parent == null) { currentStyle.setParentStyleNameReference(parentStyleName); } else { currentStyle.setParentStyle(parent); } }