Maps: Difference between revisions

From Commander4j
Created page with "A map in simple terms is a configuration which defines what you want the middleware to take as input and what you want it to generate as output. The middleware can handle multiple maps and each map can have 1 inbound connection and multiple outbound connections. The configuration for maps is within an xml file called config.xml An example of a map is shown below. In this example the system is configured to read an xml file and write the data out to 2 files, one ASCII..."
 
No edit summary
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
[[Category: Middleware4j]]
A map in simple terms is a configuration which defines what you want the middleware to take as input and what you want it to generate as output.
A map in simple terms is a configuration which defines what you want the middleware to take as input and what you want it to generate as output.


Line 7: Line 8:
An example of a map is shown below. In this example the system is configured to read an xml file and write the data out to 2 files, one ASCII (flat file) and one CSV (Comma separated variables file).
An example of a map is shown below. In this example the system is configured to read an xml file and write the data out to 2 files, one ASCII (flat file) and one CSV (Comma separated variables file).


 
<syntaxhighlight lang="xml">
     <map id="map413" enabled="Y"
     <map id="map413" enabled="Y"
         description="GEN C4J Prod Dec XML to Dual Output (ASCII and CSV Files)">
         description="GEN C4J Prod Dec XML to Dual Output (ASCII and CSV Files)">
Line 17: Line 18:
             <XSLT/>
             <XSLT/>
         </input>
         </input>
         <output id="out1" enabled="Y" description="Write ASCII File">
         <output id="out1" enabled="Y" description="Write ASCII File">
             <path>./interface/output/413 (GEN Dual Output ASCII and CSV)</path>
             <path>./interface/output/413 (GEN Dual Output ASCII and CSV)</path>
Line 25: Line 25:
             <XSLT>C4J_PRODDEC_XML_to_ASCII_Flat_File.xsl</XSLT>
             <XSLT>C4J_PRODDEC_XML_to_ASCII_Flat_File.xsl</XSLT>
         </output>
         </output>
         <output id="out2" enabled="Y" description="Write CSV">
         <output id="out2" enabled="Y" description="Write CSV">
             <path>./interface/output/413 (GEN Dual Output ASCII and CSV)</path>
             <path>./interface/output/413 (GEN Dual Output ASCII and CSV)</path>
Line 35: Line 34:
         </output>
         </output>
     </map>
     </map>
</syntaxhighlight>


 
Refer to [[Middleware4j Example Configuration|Example Configuration]] for a overview of how maps and connectors work.
Refer to [[Example Configuration]] for a overview of how maps and connectors work.

Latest revision as of 10:26, 25 August 2024

A map in simple terms is a configuration which defines what you want the middleware to take as input and what you want it to generate as output.

The middleware can handle multiple maps and each map can have 1 inbound connection and multiple outbound connections.

The configuration for maps is within an xml file called config.xml

An example of a map is shown below. In this example the system is configured to read an xml file and write the data out to 2 files, one ASCII (flat file) and one CSV (Comma separated variables file).

    <map id="map413" enabled="Y"
        description="GEN C4J Prod Dec XML to Dual Output (ASCII and CSV Files)">
        <input id="in1" description="Read XML File">
            <type>XML</type>
            <path>./interface/input/413 (GEN XML to Dual Output)</path>
            <mask/>
            <pollingInterval>1000</pollingInterval>
            <XSLT/>
        </input>
        <output id="out1" enabled="Y" description="Write ASCII File">
            <path>./interface/output/413 (GEN Dual Output ASCII and CSV)</path>
            <type>ASCII</type>
            <outputPattern>1-10,12-21,23-32</outputPattern>
            <outputFileExtension>txt</outputFileExtension>
            <XSLT>C4J_PRODDEC_XML_to_ASCII_Flat_File.xsl</XSLT>
        </output>
        <output id="out2" enabled="Y" description="Write CSV">
            <path>./interface/output/413 (GEN Dual Output ASCII and CSV)</path>
            <type>CSV</type>
            <optionDelimeter>^</optionDelimeter>
            <csvOptions>separator=,^quote=""</csvOptions>
            <outputFileExtension>csv</outputFileExtension>
            <XSLT>C4J_PRODDEC_XML_to_SAGEX3_GoodsReceipt_CSV.xsl</XSLT>
        </output>
    </map>

Refer to Example Configuration for a overview of how maps and connectors work.