Class JadiceXmlBuilder

java.lang.Object
com.saperion.ngc.viewer.virtualviewer.annotation.JadiceXmlBuilder

public class JadiceXmlBuilder extends Object
Resolve INI Format into Jadice XML Annotation Format.
  • Field Details

    • DOUBLEBYTE_ENCODING

      public static final String DOUBLEBYTE_ENCODING
      Constant for double byte encoding.
      See Also:
    • XML_ENCODING

      public static final String XML_ENCODING
      The encoding of the resulting Xml.
      See Also:
    • ANNOTATION_LINE_SEPARATOR

      public static final String ANNOTATION_LINE_SEPARATOR
      The string the "" part in Saperion annotations is replaced with.
      See Also:
    • LOGGER

      protected static final com.saperion.common.logging.Logger LOGGER
      Logger.
  • Constructor Details

    • JadiceXmlBuilder

      public JadiceXmlBuilder()
  • Method Details

    • parseIni

      public List<Section> parseIni(String iniContent)
      Parses the annotations defined by the specified ini-string and returns a list of parsed sections.
      Parameters:
      iniContent - content of the ini-file as string
      Returns:
      list of sections
    • buildXml

      public com.saperion.ngc.viewer.virtualviewer.jadice.xml.Annotations buildXml(List<Section> parsedIniSections, String ixosAnnotationsIni, int ixosPage)
      Builds the xml.
      Parameters:
      parsedIniSections - the parsed ini sections
      ixosAnnotationsIni - IXOS annotations
      ixosPage - IXOS Page
      Returns:
      the document
    • getSectionsByPage

      public Map<String,List<Section>> getSectionsByPage(List<Section> components)
      Get the Annotations sorted by Page The Hashmap key is the PageNumber, The Hashmap value is a ArrayList of Sections.
      Parameters:
      components - components
      Returns:
      pageSections
    • getBufferedReader

      public static BufferedReader getBufferedReader(String iniData)
      Get The BufferedReader from a iniData String.
      Parameters:
      iniData - iniData
      Returns:
      br BufferedReader
    • writeDocumentToByteArray

      public static byte[] writeDocumentToByteArray(com.saperion.ngc.viewer.virtualviewer.jadice.xml.Annotations document)
      Write the given xml Snowbound Document to byte Array .
      Parameters:
      document - document
      Returns:
      byteArrayOutputStream byteArrayOutputStream
    • setDocumentImageSize

      public void setDocumentImageSize(Node aDocumentImageSize)
      Parameters:
      aDocumentImageSize - documentImageSize