I built a system where I work now that separates format from processing. We use it for exports, imports, reports, etc. But it doesn't have at its core any existing format. Instead, it maps inputs to a commom row-oriented object format, provides ways to plug in filters against those objects as they "flow" through a transform, then allows any number of formatting outputs to be placed on the other end.

So, in short, don't struggle with what format to pick so much as the design of the system. Ours handles XML, HTML, fixed width, delimited, CSV, database tables, formatted text, etc. on either end -- all due to the design's allowance to plug these in easily. I end up mostly using CPAN modules to implement the plug-ins (What can I say, I'm a lazy old guy).

I'd like to make this generally available at some point but right now it's built on top of some proprietary pieces. If I can just squeeze a few more hours out of the day, maybe I can recreate a clean version on my own time ...

Also, having recently started using Template::Toolkit I suspect it will now do a lot of what I'm doing (although I like mine now of course!). There are other monks here I see on the TT mailing list so they may have comments on that one.

Also realize the HTML, XML, etc. are all based on a broader specification known as SGML. At one job there was a movement to specify everything in SGML as a common format. I've never really been convinced of that approach though. Standards change all the time and today's pick may look lousy in a year or two. I much prefer to build flexible systems that allow things to be pulled in and out with ease, and while keeping most clients insulated from the underlying changes.


In reply to Re: Is XML the only generic layout system out there? by steves
in thread Is XML the only generic layout system out there? by dragonchild

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.