Interface DocViewParserHandler


  • public interface DocViewParserHandler
    Handler to be used with DocViewParser.
    • Method Detail

      • startDocViewNode

        void startDocViewNode​(@NotNull
                              @NotNull java.lang.String nodePath,
                              @NotNull
                              @NotNull DocViewNode2 docViewNode,
                              @NotNull
                              @NotNull java.util.Optional<DocViewNode2> parentDocViewNode,
                              int line,
                              int column)
                       throws java.io.IOException,
                              RepositoryException
        Called for each element in the docview xml representing a node
        Parameters:
        nodePath - the absolute node path of the node
        docViewNode - the deserialized node (incl. its properties)
        parentDocViewNode - the parent deserialized node (only present if docViewNode is not the root node in the docview xml)
        line - the current line number in the docview xml
        column - the current column number in the docview xml
        Throws:
        java.io.IOException
        RepositoryException
      • endDocViewNode

        void endDocViewNode​(@NotNull
                            @NotNull java.lang.String nodePath,
                            @NotNull
                            @NotNull DocViewNode2 docViewNode,
                            @NotNull
                            @NotNull java.util.Optional<DocViewNode2> parentDocViewNode,
                            int line,
                            int column)
                     throws java.io.IOException,
                            RepositoryException
        Called at the end of each element in the docview xml representing a node. At this point in time all child nodes have been processed.
        Parameters:
        nodePath - the absolute node path of the node
        docViewNode - the deserialized node (incl. its properties)
        parentDocViewNode - the parent deserialized node (only present if docViewNode is not the root node in the docview xml)
        line - the current line number in the docview xml
        column - the current column number in the docview xml
        Throws:
        java.io.IOException
        RepositoryException
      • endDocument

        default void endDocument()
                          throws RepositoryException,
                                 java.io.IOException
        Called once when the end of a docview file has been reached.
        Throws:
        RepositoryException
        java.io.IOException
      • startPrefixMapping

        default void startPrefixMapping​(java.lang.String prefix,
                                        java.lang.String uri)
        Called when a namespace mapping is defined in the docview xml. Rather use setNameResolver(NameResolver) instead if you just need to resolve JCR names.
        Parameters:
        prefix - the namespace prefix
        uri - the namespace uri
      • endPrefixMapping

        default void endPrefixMapping​(java.lang.String prefix)
        Called when a namespace mapping end in the docview xml. Rather use setNameResolver(NameResolver) instead if you just need to resolve JCR names.
        Parameters:
        prefix - the namespace prefix