DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=40308>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=40308

           Summary: RFE: FOP throws a validation exception when it finds
                    duplicate IDs in the XSL-FO
           Product: Fop
           Version: 0.92
          Platform: Other
        OS/Version: other
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: fo tree
        AssignedTo: fop-dev@xmlgraphics.apache.org
        ReportedBy: [EMAIL PROTECTED]
                CC: [EMAIL PROTECTED]


FOP 0.92beta throws a ValidationException if it finds that several XSL-FOs      
  have the same ID and this, even when parameter "strict-validation" has been
  set to "false".

  Modular documents built using XInclude often contain duplicate IDs. For
  example, a modular document may contain three instances of the same table
  found at three different places in the document. There is no error that
  could be fixed in the source XML in such case.

  In all cases, IMHO, it does not make sense for a XSL-FO formatter such as
  FOP to completely stop working when it finds a validity error as benign as a
  duplicate ID.

Changes made in FOP 0.92beta's src/java/org/apache/fop/fo/FObj.java: 
added test "if (getUserAgent().validateStrictly())".

===============================================================
    protected void checkId(String id) throws ValidationException {
        if (!id.equals("")) {
            Set idrefs = getFOEventHandler().getIDReferences();
            if (!idrefs.contains(id)) {
                idrefs.add(id);
            } else {
                if (getUserAgent().validateStrictly()) {
                    throw new ValidationException(
                        "Property id \"" + id 
                        + "\" previously used; id values must be unique"
                        + " in document.", locator);
                }
            }
        }
    }
===============================================================

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

Reply via email to