Interface IXmlInternalExporter


@OpenApiAll public interface IXmlInternalExporter
An Interface for BPMN -> XML Exporters. Exporters are xsd schema based, and export Object trees created from compiled xjc classes. The bpmn model elements can be checked with the BPMN validation rules, if required. And of course the generated xml can be validated against the original schemas and then written to an OutputStream.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    the Exporter framework will call this method to test if the BPMN model elements should be validated.
    Mapping model elements to JAXB objects.
    The model elements that are to be validated with CBM internal rules
    jakarta.xml.bind.Marshaller
    Creates the Marshaller used by this exporter
    The particular JAXB Object factory needed for this exporter.
    The reference of model elements that are to be validated with CBM internal rules
    if dependent schemas are jarred, a custom Resolver is needed to locate them at xml validation time.
    The Schema sources needed to validate the resulting xml file This method can return null if xml validation is not needed.
    If the BPMN model elements were validated, this is where the results will be available.
    void
    setMarshallerProperties(jakarta.xml.bind.Marshaller m)
    Sets special properties for the marshaller before actual export.
    void
    This method will serialize the JAXB object tree to an OutputStream silently exits if all goes well
  • Method Details

    • getJAXBRootElement

      Object getJAXBRootElement()
      Mapping model elements to JAXB objects. This must return the root of the JAXB object tree.
      Returns:
      the root of the mapped model, a JAXB object
    • doValidateModel

      boolean doValidateModel()
      the Exporter framework will call this method to test if the BPMN model elements should be validated.
      Returns:
      true if the model is to be validated
    • getMappedElements

      Set<Element> getMappedElements()
      The model elements that are to be validated with CBM internal rules
      Returns:
      the elements that have to be validated
    • getRefElements

      Set<Element> getRefElements()
      The reference of model elements that are to be validated with CBM internal rules
      Returns:
      the elements that have to be validated
    • getViolations

      If the BPMN model elements were validated, this is where the results will be available.
      Returns:
      the Validation Rule Violations
    • getObjectFactoryClass

      Class<?> getObjectFactoryClass()
      The particular JAXB Object factory needed for this exporter.
      Returns:
      the JAXB ObjectFactory class
    • getSchemaSources

      StreamSource[] getSchemaSources()
      The Schema sources needed to validate the resulting xml file This method can return null if xml validation is not needed.
      Returns:
      all schemas needed for xml validation
    • setMarshallerProperties

      void setMarshallerProperties(jakarta.xml.bind.Marshaller m) throws jakarta.xml.bind.JAXBException
      Sets special properties for the marshaller before actual export.
      Parameters:
      m - the marshaller that can be customized
      Throws:
      jakarta.xml.bind.JAXBException
    • getMarshaller

      jakarta.xml.bind.Marshaller getMarshaller() throws jakarta.xml.bind.JAXBException
      Creates the Marshaller used by this exporter
      Returns:
      the Marshaller
      Throws:
      jakarta.xml.bind.JAXBException
    • write

      void write() throws jakarta.xml.bind.JAXBException, SAXParseException
      This method will serialize the JAXB object tree to an OutputStream silently exits if all goes well
      Throws:
      jakarta.xml.bind.JAXBException
      SAXParseException
    • getResolver

      LSResourceResolver getResolver()
      if dependent schemas are jarred, a custom Resolver is needed to locate them at xml validation time.
      Returns:
      the custom Resource Resolver