Class DocViewNode2

    • Method Detail

      • getName

        @NotNull
        public @NotNull Name getName()
        Returns:
        the name of the Node represented by this class
      • getIndex

        public int getIndex()
        Returns:
        0, except if there is a same-name sibling in the docview. In that case the index gives the 1-based order of the SNS nodes.
        See Also:
        Same-Name Siblings
      • getProperties

        @NotNull
        public @NotNull Collection<DocViewProperty2> getProperties()
        Returns:
        all direct properties of the node represented by this object
      • hasProperty

        public boolean hasProperty​(Name name)
      • getPropertyValues

        @NotNull
        public @NotNull Collection<String> getPropertyValues​(@NotNull
                                                             @NotNull Name name)
      • getPropertyValue

        @NotNull
        public @NotNull Optional<String> getPropertyValue​(@NotNull
                                                          @NotNull Name name)
      • getPrimaryType

        @NotNull
        public @NotNull Optional<String> getPrimaryType()
      • getIdentifier

        @NotNull
        public @NotNull Optional<String> getIdentifier()
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • writeStart

        public void writeStart​(@NotNull
                               @NotNull XMLStreamWriter writer,
                               @NotNull
                               @NotNull NamespaceResolver nsResolver,
                               @NotNull
                               @NotNull Iterable<String> namespacePrefixes)
                        throws NamespaceException,
                               XMLStreamException
        Writes the node's start tag (including the attributes for the properties and optionally the namespace declarations) to the given XMLStreamWriter. Use the following writer for properly formatting the output according to FileVault standards: FormattingXmlStreamWriter.create(out, new DocViewFormat().getXmlOutputFormat()).
        Parameters:
        writer - the XMLStreamWriter to write to
        nsResolver - the namespace resolver to use for retrieving prefixes for namespace URIs of getName() and DocViewProperty2.getName()
        namespacePrefixes - the namespace prefixes for which to emit namespace declarations in this node
        Throws:
        NamespaceException - in case no prefix is defined for the namespace URI of a name (either node's or property's)
        XMLStreamException
        Since:
        3.6.2
      • writeEnd

        public static void writeEnd​(@NotNull
                                    @NotNull XMLStreamWriter writer)
                             throws XMLStreamException
        Writes the node's end tag to the given XMLStreamWriter. Use the following writer for properly formatting the output according to FileVault standards: FormattingXmlStreamWriter.create(out, new DocViewFormat().getXmlOutputFormat()).
        Parameters:
        writer - the XMLStreamWriter to write to
        Throws:
        XMLStreamException
        Since:
        3.6.2