org.apache.fop.fo

## Interface FOValidationEventProducer

- All Superinterfaces:
    EventProducer

      public interface FOValidationEventProducer
      extends EventProducer

  Event producer interface for XSL-FO validation messages.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface and Description
    --- | ---
    `static class` | `FOValidationEventProducer.Provider` Provider class for the event producer.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `altTextMissing(Object source, String foElement, Locator loc)` Alternate text is missing for a graphic element.
    `void` | `changeBarClassNotUnique(Object source, String elementName, String name, Locator loc)` A class for change bars is not unique.
    `void` | `changeBarNoBegin(Object source, String elementName, Locator loc)` Change bar ended without a start of bar occurred
    `void` | `changeBarWrongAncestor(Object source, String elementName, Locator loc)` Change bar not descendant of fo:flow or fo:static-content
    `void` | `changeBarWrongStacking(Object source, String elementName, String beginName, String endName, Locator loc)` Change bars were not stacked correctly
    `void` | `colorProfileNameNotUnique(Object source, String elementName, String name, Locator loc)` There are multiple color profiles defined with the same name.
    `void` | `columnCountErrorOnRegionBodyOverflowScroll(Object source, String elementName, Locator loc)` If overflow property is set to "scroll", a column-count other than "1" may not be specified.
    `void` | `duplicateFlowNameInPageSequence(Object source, String elementName, String flowName, Locator loc)` There are multiple flows with the same name.
    `void` | `emptyDocument(Object source)` No FO document was found.
    `void` | `flowNameNotMapped(Object source, String elementName, String flowName, Locator loc)` A flow name could not be mapped to a region.
    `void` | `idNotUnique(Object source, String elementName, String id, boolean canRecover, Locator loc)` An id was used twice in a document.
    `void` | `illegalRegionName(Object source, String elementName, String regionName, Locator loc)` An illegal region name was used.
    `void` | `invalidChild(Object source, String elementName, org.apache.xmlgraphics.util.QName offendingNode, String ruleViolated, Locator loc)` An invalid child was encountered.
    `void` | `invalidFORoot(Object source, String elementName, Locator loc)` fo:root must be root.
    `void` | `invalidProperty(Object source, String elementName, org.apache.xmlgraphics.util.QName attr, boolean canRecover, Locator loc)` An invalid property was found.
    `void` | `invalidPropertyValue(Object source, String elementName, String propName, String propValue, PropertyException e, Locator loc)` An invalid property value was encountered.
    `void` | `markerBlockContainerAbsolutePosition(Object source, Locator loc)` An fo:marker appears as initial descendant in an fo:block-container that generates absolutely positioned areas
    `void` | `markerCloningFailed(Object source, String markerClassName, FOPException fe, Locator loc)` Indicates a problem while cloning a marker (ex.
    `void` | `markerNotInitialChild(Object source, String elementName, String mcname, Locator loc)` A marker is not an initial child on a node.
    `void` | `markerNotUniqueForSameParent(Object source, String elementName, String mcname, Locator loc)` A marker class name is not unique within the same parent.
    `void` | `masterNameNotUnique(Object source, String elementName, String name, Locator loc)` There are multiple page masters defined with the same name.
    `void` | `masterNotFound(Object source, String elementName, String masterReference, Locator loc)` A page master could not be found.
    `void` | `missingChildElement(Object source, String elementName, String contentModel, boolean canRecover, Locator loc)` A required child element is missing.
    `void` | `missingLinkDestination(Object source, String elementName, Locator loc)` Missing internal-/external-destination on basic-link or bookmark.
    `void` | `missingProperty(Object source, String elementName, String propertyName, Locator loc)` An element is missing a required property.
    `void` | `nodeOutOfOrder(Object source, String elementName, String tooLateNode, String tooEarlyNode, boolean canRecover, Locator loc)` The node order is wrong.
    `void` | `nonZeroBorderPaddingOnRegion(Object source, String elementName, String regionName, boolean canRecover, Locator loc)` A non-zero border and/or padding has been encountered on a region.
    `void` | `notSupportedChild(Object source, String elementName, org.apache.xmlgraphics.util.QName offendingNode, Locator loc)` A valid but not yet supported child was encountered.
    `void` | `regionNameMappedToMultipleRegionClasses(Object source, String regionName, String defaultRegionClass1, String defaultRegionClass2, Locator loc)` A region name is mapped to multiple region classes.
    `void` | `tooManyNodes(Object source, String elementName, org.apache.xmlgraphics.util.QName offendingNode, Locator loc)` Too many child nodes.
    `void` | `unimplementedFeature(Object source, String elementName, String feature, Locator loc)` A feature is not supported, yet.
    `void` | `unknownFormattingObject(Object source, String elementName, org.apache.xmlgraphics.util.QName offendingNode, Locator loc)` An unknown/unsupported formatting object has been encountered.
    `void` | `warnOnInvalidPropertyValue(Object source, String elementName, String propName, String propValue, PropertyException e, Locator loc)` An invalid property value was encountered.

- - ### Method Detail

    - #### tooManyNodes

          void tooManyNodes(Object source,
                            String elementName,
                            org.apache.xmlgraphics.util.QName offendingNode,
                            Locator loc)
                     throws ValidationException

      Too many child nodes.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `offendingNode` - the offending node
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### nodeOutOfOrder

          void nodeOutOfOrder(Object source,
                              String elementName,
                              String tooLateNode,
                              String tooEarlyNode,
                              boolean canRecover,
                              Locator loc)
                       throws ValidationException

      The node order is wrong.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `tooLateNode` - string name of node that should be earlier in document
        `tooEarlyNode` - string name of node that should be later in document
        `canRecover` - indicates whether FOP can recover from this problem and continue working
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call

    - #### invalidChild

          void invalidChild(Object source,
                            String elementName,
                            org.apache.xmlgraphics.util.QName offendingNode,
                            String ruleViolated,
                            Locator loc)
                     throws ValidationException

      An invalid child was encountered.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `offendingNode` - the offending node
        `ruleViolated` - the rule that was violated or null
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call

    - #### notSupportedChild

          void notSupportedChild(Object source,
                                 String elementName,
                                 org.apache.xmlgraphics.util.QName offendingNode,
                                 Locator loc)
                          throws ValidationException

      A valid but not yet supported child was encountered.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `offendingNode` - the offending node
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call

    - #### missingChildElement

          void missingChildElement(Object source,
                                   String elementName,
                                   String contentModel,
                                   boolean canRecover,
                                   Locator loc)
                            throws ValidationException

      A required child element is missing.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `contentModel` - the expected content model
        `canRecover` - indicates whether FOP can recover from this problem and continue working
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### missingProperty

          void missingProperty(Object source,
                               String elementName,
                               String propertyName,
                               Locator loc)
                        throws ValidationException

      An element is missing a required property.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `propertyName` - the name of the missing property
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### idNotUnique

          void idNotUnique(Object source,
                           String elementName,
                           String id,
                           boolean canRecover,
                           Locator loc)
                    throws ValidationException

      An id was used twice in a document.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `id` - the id that was reused
        `canRecover` - indicates whether FOP can recover from this problem and continue working
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### colorProfileNameNotUnique

          void colorProfileNameNotUnique(Object source,
                                         String elementName,
                                         String name,
                                         Locator loc)

      There are multiple color profiles defined with the same name.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `name` - the duplicate color profile name
        `loc` - the location of the error or null
      Event.severity:
        WARN

    - #### masterNameNotUnique

          void masterNameNotUnique(Object source,
                                   String elementName,
                                   String name,
                                   Locator loc)
                            throws ValidationException

      There are multiple page masters defined with the same name.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `name` - the duplicate page master name
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### markerBlockContainerAbsolutePosition

          void markerBlockContainerAbsolutePosition(Object source,
                                                    Locator loc)

      An fo:marker appears as initial descendant in an fo:block-container that generates absolutely positioned areas
      Parameters:
        `source` - the event source
        `loc` - the location of the error (possibly null)
      Event.severity:
        ERROR

    - #### markerNotInitialChild

          void markerNotInitialChild(Object source,
                                     String elementName,
                                     String mcname,
                                     Locator loc)

      A marker is not an initial child on a node.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `mcname` - the marker class name
        `loc` - the location of the error or null
      Event.severity:
        ERROR

    - #### markerNotUniqueForSameParent

          void markerNotUniqueForSameParent(Object source,
                                            String elementName,
                                            String mcname,
                                            Locator loc)

      A marker class name is not unique within the same parent.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `mcname` - the marker class name
        `loc` - the location of the error or null
      Event.severity:
        ERROR

    - #### invalidProperty

          void invalidProperty(Object source,
                               String elementName,
                               org.apache.xmlgraphics.util.QName attr,
                               boolean canRecover,
                               Locator loc)
                        throws ValidationException

      An invalid property was found.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `attr` - the invalid attribute
        `canRecover` - indicates whether FOP can recover from this problem and continue working
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### invalidPropertyValue

          void invalidPropertyValue(Object source,
                                    String elementName,
                                    String propName,
                                    String propValue,
                                    PropertyException e,
                                    Locator loc)

      An invalid property value was encountered.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `propName` - the property name
        `propValue` - the property value
        `e` - the property exception caused by the invalid value
        `loc` - the location of the error or null
      Event.severity:
        ERROR

    - #### warnOnInvalidPropertyValue

          void warnOnInvalidPropertyValue(Object source,
                                          String elementName,
                                          String propName,
                                          String propValue,
                                          PropertyException e,
                                          Locator loc)

      An invalid property value was encountered.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `propName` - the property name
        `propValue` - the property value
        `e` - the property exception caused by the invalid value
        `loc` - the location of the error or null
      Event.severity:
        WARN

    - #### unimplementedFeature

          void unimplementedFeature(Object source,
                                    String elementName,
                                    String feature,
                                    Locator loc)

      A feature is not supported, yet.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `feature` - the unsupported feature
        `loc` - the location of the error or null
      Event.severity:
        WARN

    - #### missingLinkDestination

          void missingLinkDestination(Object source,
                                      String elementName,
                                      Locator loc)
                               throws ValidationException

      Missing internal-/external-destination on basic-link or bookmark.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### markerCloningFailed

          void markerCloningFailed(Object source,
                                   String markerClassName,
                                   FOPException fe,
                                   Locator loc)

      Indicates a problem while cloning a marker (ex. due to invalid property values).
      Parameters:
        `source` - the event source
        `markerClassName` - the "marker-class-name" of the marker
        `fe` - the FOP exception that cause this problem
        `loc` - the location of the error or null
      Event.severity:
        ERROR

    - #### regionNameMappedToMultipleRegionClasses

          void regionNameMappedToMultipleRegionClasses(Object source,
                                                       String regionName,
                                                       String defaultRegionClass1,
                                                       String defaultRegionClass2,
                                                       Locator loc)
                                                throws ValidationException

      A region name is mapped to multiple region classes.
      Parameters:
        `source` - the event source
        `regionName` - the region name
        `defaultRegionClass1` - the first default region class
        `defaultRegionClass2` - the second default region class
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### duplicateFlowNameInPageSequence

          void duplicateFlowNameInPageSequence(Object source,
                                               String elementName,
                                               String flowName,
                                               Locator loc)
                                        throws ValidationException

      There are multiple flows with the same name.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `flowName` - the flow name
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### flowNameNotMapped

          void flowNameNotMapped(Object source,
                                 String elementName,
                                 String flowName,
                                 Locator loc)
                          throws ValidationException

      A flow name could not be mapped to a region.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `flowName` - the flow name
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### masterNotFound

          void masterNotFound(Object source,
                              String elementName,
                              String masterReference,
                              Locator loc)
                       throws ValidationException

      A page master could not be found.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `masterReference` - the page master reference
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### illegalRegionName

          void illegalRegionName(Object source,
                                 String elementName,
                                 String regionName,
                                 Locator loc)
                          throws ValidationException

      An illegal region name was used.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `regionName` - the region name
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### nonZeroBorderPaddingOnRegion

          void nonZeroBorderPaddingOnRegion(Object source,
                                            String elementName,
                                            String regionName,
                                            boolean canRecover,
                                            Locator loc)
                                     throws ValidationException

      A non-zero border and/or padding has been encountered on a region.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `regionName` - the region name
        `canRecover` - indicates whether FOP can recover from this problem and continue working
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### columnCountErrorOnRegionBodyOverflowScroll

          void columnCountErrorOnRegionBodyOverflowScroll(Object source,
                                                          String elementName,
                                                          Locator loc)
                                                   throws ValidationException

      If overflow property is set to "scroll", a column-count other than "1" may not be specified.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### invalidFORoot

          void invalidFORoot(Object source,
                             String elementName,
                             Locator loc)
                      throws ValidationException

      fo:root must be root.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `loc` - the location of the error or null
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### emptyDocument

          void emptyDocument(Object source)
                      throws ValidationException

      No FO document was found.
      Parameters:
        `source` - the event source
      Throws:
        `ValidationException` - the validation error provoked by the method call
      Event.severity:
        FATAL

    - #### unknownFormattingObject

          void unknownFormattingObject(Object source,
                                       String elementName,
                                       org.apache.xmlgraphics.util.QName offendingNode,
                                       Locator loc)

      An unknown/unsupported formatting object has been encountered.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `offendingNode` - the offending node
        `loc` - the location of the error or null
      Event.severity:
        WARN

    - #### changeBarClassNotUnique

          void changeBarClassNotUnique(Object source,
                                       String elementName,
                                       String name,
                                       Locator loc)

      A class for change bars is not unique.
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `name` - the class name
        `loc` - the location of the error or null
      Event.severity:
        FATAL

    - #### changeBarWrongStacking

          void changeBarWrongStacking(Object source,
                                      String elementName,
                                      String beginName,
                                      String endName,
                                      Locator loc)

      Change bars were not stacked correctly
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `beginName` - the class name of the beginning change bar
        `endName` - the class name of the ending change bar
        `loc` - the location of the error or null
      Event.severity:
        FATAL

    - #### changeBarNoBegin

          void changeBarNoBegin(Object source,
                                String elementName,
                                Locator loc)

      Change bar ended without a start of bar occurred
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `loc` - the location of the error or null
      Event.severity:
        FATAL

    - #### changeBarWrongAncestor

          void changeBarWrongAncestor(Object source,
                                      String elementName,
                                      Locator loc)

      Change bar not descendant of fo:flow or fo:static-content
      Parameters:
        `source` - the event source
        `elementName` - the name of the context node
        `loc` - the location of the error or null
      Event.severity:
        FATAL

    - #### altTextMissing

          void altTextMissing(Object source,
                              String foElement,
                              Locator loc)

      Alternate text is missing for a graphic element.
      Parameters:
        `source` - the event source
        `foElement` - name of the element (external-graphic or instream-foreign-object)
        `loc` - the location of the error or null
      Event.severity:
        WARN

Copyright © 2023 Apache Software Foundation. All rights reserved.