Written by

Senior Cloud Architect at InterSystems
MOD
Question Eduard Lebedyuk · Jun 7, 2019

Different XML projections for the same class

I have one persistent, xml-enabled class.
I need to convert objects of this class to XML.
However I need to project each object in different ways (depending on
where I send it), for example:

  • Different list of attributes are projected
  • Attributes have different names
  • ...

Is there a way to do that with XML Adaptor?

Comments

Dmitry Maslennikov · Jun 7, 2019

I would try two options:

  • Use descendent abstract class, which will redefine some XML related parameters, as needed.
  • SImplify XML Export, and use one or more XSLT files, so, I could transform basic view to some another one or more.
0