Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to modifiy this String template?
    text
    copied!<p>Following is the String Template : </p> <pre><code> XYZ PROCESSING SERVICES GMBH HAHNSTR. 25 60528 CITY BEGLEITZETTEL ZU CORT UMSATZBAND - GUTSCHRIFT SAMMEL UEBERWEISUNGSAUFTRAG CASSETTENNUMMER : ERSTELLUNGSDATUM : $FileCreationDate$ ZEICHENDICHTE : 38K HEADER-ANZAHL : 1 ANZAHL SATZ C : $ANZAHLSATZC$ EUR SUMME SATZ C : $EURSUMMESATZC$ KONTROLSUMME KTONR. : $KONTROLSUMMEKTONR$ KONTROLSUMME BLZ : $KONTROLSUMMEBLZ$ EMPFÄNGER NAME : L CONSORS S.A. EMPFÄNGER BLZ : 12345678 EMPFÄNGER KTONR. : 0987654321 ORT : CITY DATUM : $Datum$ </code></pre> <p>But when you run the Java Program with this Template, you get the following output, i.e. the position of first line is moved automatically, but the required output is the same as mentioned above :</p> <pre><code> XYZ PROCESSING SERVICES GMBH HAHNSTR. 25 60528 CITY BEGLEITZETTEL ZU CORT UMSATZBAND - GUTSCHRIFT SAMMEL UEBERWEISUNGSAUFTRAG CASSETTENNUMMER : ERSTELLUNGSDATUM : $FileCreationDate$ ZEICHENDICHTE : 38K HEADER-ANZAHL : 1 ANZAHL SATZ C : $ANZAHLSATZC$ EUR SUMME SATZ C : $EURSUMMESATZC$ KONTROLSUMME KTONR. : $KONTROLSUMMEKTONR$ KONTROLSUMME BLZ : $KONTROLSUMMEBLZ$ EMPFÄNGER NAME : L CONSORS S.A. EMPFÄNGER BLZ : 12345678 EMPFÄNGER KTONR. : 0987654321 ORT : CITY </code></pre> <p>The java Code for this is :</p> <pre><code>StringTemplateGroup templateGroup = new StringTemplateGroup( "spam group", "src/main/resources"); StringTemplate logDTABegleitzettel = templateGroup .getInstanceOf("Template"); logDTABegleitzettel.setAttribute("FileCreationDate", fileCreationDate); logDTABegleitzettel.setAttribute("ANZAHLSATZC", numberofCRecords); logDTABegleitzettel.setAttribute("EURSUMMESATZC", sumofTranxAmounts); logDTABegleitzettel.setAttribute("KONTROLSUMMEKTONR", sumofAccountNumbers); logDTABegleitzettel.setAttribute("KONTROLSUMMEBLZ", sumofBankSortCodes); logDTABegleitzettel.setAttribute("Datum", dateOfFile); </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload