Skip to content

Commit

Permalink
updated javadocs
Browse files Browse the repository at this point in the history
jstaerk committed Nov 18, 2024
1 parent a1eb76f commit 803778d
Showing 3 changed files with 12 additions and 10 deletions.
12 changes: 7 additions & 5 deletions library/src/main/java/org/mustangproject/Invoice.java
Original file line number Diff line number Diff line change
@@ -478,7 +478,9 @@ public BigDecimal getRoundingAmount() {
}

/***
* for currency rounding differences to 5ct e.g. in Netherlands ("Rappenrundung")
* set the cent e.g. to reach the next 5ct mark for currencies in certain countries
* e.g. in the Netherlands ("Rappenrundung")
* @param amount
* @return fluent setter
*/
public Invoice setRoundingAmount(BigDecimal amount) {
@@ -543,8 +545,8 @@ public IZUGFeRDAllowanceCharge[] getZFAllowances() {

/***
* this is wrong and only used from jackson
* @param iza
* @return
* @param iza the Array of allowances/charges
* @return fluent setter
*/
public Invoice setZFAllowances(Allowance[] iza) {
Allowances=new ArrayList<>();
@@ -567,8 +569,8 @@ public IZUGFeRDAllowanceCharge[] getZFCharges() {

/***
* this is wrong and only used from jackson
* @param iza
* @return
* @param iza the array of charges
* @return fluent setter
*/
public Invoice setZFCharges(Charge[] iza) {
Charges=new ArrayList<>();
4 changes: 2 additions & 2 deletions library/src/main/java/org/mustangproject/XMLTools.java
Original file line number Diff line number Diff line change
@@ -92,7 +92,7 @@ public static BigDecimal tryBigDecimal(Node node) {
/***
* formats a number so that at least minDecimals are displayed but at the maximum maxDecimals are there, i.e.
* cuts potential 0s off the end until minDecimals
* @param value
* @param value the value to be formatted
* @param maxDecimals number of maximal scale
* @param minDecimals number of minimal scale
* @return value as String with decimals in the specified range
@@ -138,7 +138,7 @@ public static Date tryDate(String toParse) {
}

/***
* relplaces some entities like < , > and & with their escaped pendant like &lt;
* relplaces some entities like &lt; , &gt; and &amp; with their escaped pendant like &amp;lt;
* @param s the string
* @return the "safe" string
*/
Original file line number Diff line number Diff line change
@@ -101,7 +101,7 @@ public void setInputStream(InputStream pdfStream) {

/***
* return the file names of all files embedded into the PDF
* @see for XML embedded files please use ZUGFeRDInvoiceImporter.getFileAttachmentsXML
* @see ZUGFeRDInvoiceImporter for XML embedded files please use ZUGFeRDInvoiceImporter.getFileAttachmentsXML
* @return a ArrayList of FileAttachments, empty if none
*/
public List<FileAttachment> getFileAttachmentsPDF() {
@@ -228,7 +228,7 @@ private void extractFiles(Map<String, PDComplexFileSpecification> names) throws
* set the xml of a CII invoice
* @param rawXML the xml string
* @param doParse automatically parse input for zugferdImporter (not ZUGFeRDInvoiceImporter)
* @throws IOException
* @throws IOException if parsing xml throws it (unlikely its string based)
*/
public void setRawXML(byte[] rawXML, boolean doParse) throws IOException {
this.containsMeta = true;
@@ -248,7 +248,7 @@ public void setRawXML(byte[] rawXML, boolean doParse) throws IOException {
/***
* set the xml of a CII invoice, simple version
* @param rawXML the cii(?) as a string
* @throws IOException
* @throws IOException if parsing xml throws it (unlikely its string based)
*/
public void setRawXML(byte[] rawXML) throws IOException {
setRawXML(rawXML, true);

0 comments on commit 803778d

Please sign in to comment.