Announcement

Collapse

Mirth Connect 4.3.0 Released!

Mirth Connect 4.3.0 is now available as an appliance update and on our GitHub page.

This is a major release containing new features like adding new functionality to the Mirth Connect Setup Wizard, adding the ability for resource and channel-specific classloaders to load child-first or parent-first, and added a default implementation of the getObjectsForSwaggerExamples() method in the ServicePlugin class. This release also contains enhancements for the Mirth Connect Administrator Launcher, the Mirth Connect Docker images, and several bug fixes and security improvements.

Download | See What's New | Upgrade Guide | Release Notes

For discussion on this release, see this thread.
See more
See less

Transforming to xml

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Transforming to xml

    While I still have some design decisions on how best to do this. Today I am transforming the incoming message to an XML format. If I use plain XML without an XSD I have to write some code that is hard to maintain to dynamically build the xml.

    e.g.

    for (i=0; i< msg['definition']['attributes']['children'].length(); i++) {
    // expand XML
    tmp['ArchetypeClusterModel'][i] = "<ArchetypeClusterModel><activeInd>1</activeInd><archetypeCategoryRef><id>0</id><display></display><idvalue></idvalue></archetypeCategoryRef><archetypeClusterId>0</archetypeClusterId><archetypeClusterRef><id>...... etc ";
    }
    // populate
    tmp['ArchetypeClusterModel'][i]['archetypeClusterRef']['idvalue'] = msg['definition']['attributes']['children']['rm_type_name'].toString();
    }

    Is there any plans to be able to define an XSD so I can programmtically extends the model e.g.

    for (i=0; i< msg['definition']['attributes']['children'].length(); i++) {
    // expand XML
    tmp['ArchetypeClusterModel'][i] = new tmp['ArchetypeClusterModel'];
    // populate
    tmp['ArchetypeClusterModel'][i]['archetypeClusterRef']['idvalue'] = msg
    }

  • #2
    Re:Transforming to xml

    Hi.

    I can't understand you well: incoming messages are allways transformed to XML (mirth works internaly with XML). Why you need XSD ? Why can't you use an output template ?

    Comment

    Working...
    X