Skip to content

Commit 36d23b4

Browse files
Merge pull request #98 from xdev-software/develop
v1.0.3
2 parents d138508 + 6100b30 commit 36d23b4

File tree

10 files changed

+47
-62
lines changed

10 files changed

+47
-62
lines changed

.github/workflows/broken-links.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818

1919
- name: Link Checker
2020
id: lychee
21-
uses: lycheeverse/lychee-action@v1
21+
uses: lycheeverse/lychee-action@v2
2222

2323
- name: Find already existing issue
2424
id: find-issue

.github/workflows/sonar.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ on:
1111
- '.idea/**'
1212
- 'assets/**'
1313
pull_request:
14-
types: [opened, synchronize, reopened]
14+
branches: [ develop ]
1515
paths-ignore:
1616
- '**.md'
1717
- '.config/**'

.mvn/wrapper/maven-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@
1414
# KIND, either express or implied. See the License for the
1515
# specific language governing permissions and limitations
1616
# under the License.
17-
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.8/apache-maven-3.9.8-bin.zip
17+
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.9/apache-maven-3.9.9-bin.zip

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# 1.0.3
2+
3+
* ReportableSellerCreator can now create "Rechtsträger" like a company.
4+
15
# 1.0.2
26

37
* The alias for the private key in the keystore is now configurable (

README.md

Lines changed: 14 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -8,37 +8,24 @@
88

99
# bzst-dip-java-client
1010

11-
Client for using
12-
the [Mass data transmission DIP (mass data
13-
interface)](https://www.bzst.de/EN/Businesses/CESOP/electronic_data_transmission/electronic_data_transmission_node.html#js-toc-entry1).
11+
Client for using the [Mass data transmission DIP (mass data interface)](https://www.bzst.de/EN/Businesses/CESOP/electronic_data_transmission/electronic_data_transmission_node.html#js-toc-entry1).
1412

15-
The BZSt (Bundeszentralamt für Steuern / Federal Central Tax Office) provides the Digital Inbox (DIP) as a service
16-
for payment service providers to transmit financial data.
13+
The BZSt (Bundeszentralamt für Steuern / Federal Central Tax Office) provides the Digital Inbox (DIP) as a service for payment service providers to transmit financial data.
1714

18-
Clients need to register / login
19-
at [BZSt online.portal](https://www.bzst.de/DE/Service/Portalinformation/Massendaten/DIP/dip.html?nn=68828)
20-
through [Elster](https://www.elster.de/elsterweb/start), [BundID](https://id.bund.de/de)
21-
or [BZSt Online-Portal (BOP)](https://www.elster.de/bportal/start).
15+
Clients need to register / login at [BZSt online.portal](https://www.bzst.de/DE/Service/Portalinformation/Massendaten/DIP/dip.html?nn=68828) through [Elster](https://www.elster.de/elsterweb/start), [BundID](https://id.bund.de/de) or [BZSt Online-Portal (BOP)](https://www.elster.de/bportal/start).
2216

23-
See
24-
the [BZSt Information](https://www.bzst.de/EN/Service/Portalinformation/Login/login_node.html)
25-
for more information.
17+
See the [BZSt Information](https://www.bzst.de/EN/Service/Portalinformation/Login/login_node.html) for more information.
2618

27-
*Warning*: **BZSt Online-Portal** (deprecated) is different from **BZSt online.portal**.
19+
> [!NOTE]
20+
> **BZSt Online-Portal** (deprecated) is different from **BZSt online.portal**.
2821
2922
## Rationale
3023

3124
We created this client to make it as easy as possible for the developer to use the BZSt DIP.
32-
Through usage of the builder pattern (see [Configuration](#configuration) below), DTOs
33-
and a typesafe data model we ensure high usability and readability.
25+
Through usage of the builder pattern (see [Configuration](#configuration) below), DTOs and a typesafe data model we ensure high usability and readability.
3426

35-
The BZSt
36-
provides [XSD](https://www.bzst.de/SharedDocs/Downloads/DE/Digitale_Plattformbetreiber/amtlicher_datensatz_entwurf) that
37-
define the expected XML structure and
38-
make it possible to generate java
39-
classes ([BZSt Docs](https://www.bzst.de/DE/Unternehmen/Intern_Informationsaustausch/DAC7/Handbuecher/handbuecher.html?nn=127558#js-toc-entry2)).
40-
Our library validates each
41-
request through these XSD find errors before they are sent to the DIP.
27+
The BZSt provides [XSD](https://www.bzst.de/SharedDocs/Downloads/DE/Digitale_Plattformbetreiber/amtlicher_datensatz_entwurf) that define the expected XML structure and make it possible to generate java classes ([BZSt Docs](https://www.bzst.de/DE/Unternehmen/Intern_Informationsaustausch/DAC7/Handbuecher/handbuecher.html?nn=127558#js-toc-entry2)).<br/>
28+
Our library validates each request through these XSD find errors before they are sent to the DIP.
4229

4330
## Installation
4431
[Installation guide for the latest release](https://github.com/xdev-software/bzst-dip-java-client/releases/latest#Installation)
@@ -51,9 +38,7 @@ See the [examples in the demo package](./bzst-dip-java-client-demo/src/main/java
5138

5239
For authentification at the BZST you have to create a public- and private-key.
5340

54-
First you have to create a **PEM** file as described on
55-
the [BZST Website](https://www.bzst.de/SharedDocs/Downloads/DE/EOP_BOP/khb_dip.pdf?__blob=publicationFile&v=9) (see
56-
1.7).
41+
First you have to create a **PEM** file as described on the [BZST Website](https://www.bzst.de/DE/Service/Portalinformation/Massendaten/DIP/dip_node.html) (see 1.7).
5742

5843
OpenSSL can be downloaded from their [website](https://www.openssl.org/).
5944

@@ -67,15 +52,13 @@ Next you have to convert that file to a **PKCS12** file.
6752
openssl pkcs12 -export -in cert.pem -inkey key.pem -out certificate.p12 -name "certificate"
6853
```
6954

70-
The [keytool](https://docs.oracle.com/javase/8/docs/technotes/tools/unix/keytool.html) is contained in your JDK
71-
installation.
55+
The [keytool](https://docs.oracle.com/javase/8/docs/technotes/tools/unix/keytool.html) is contained in your JDK installation.
7256

7357
```
7458
keytool -importkeystore -srckeystore certificate.p12 -srcstoretype pkcs12 -destkeystore cert.jks
7559
```
7660

77-
The password you insert here, along with the file itself must be set in the client configuration. See example
78-
at [app.properties](./bzst-dip-java-client-demo/src/main/resources/app.properties):
61+
The password you insert here, along with the file itself must be set in the client configuration. See example at [app.properties](./bzst-dip-java-client-demo/src/main/resources/app.properties):
7962

8063
```
8164
certificate.keystore.password=SECRET_PASSWORD
@@ -101,11 +84,7 @@ client.id=abcd1234-ab12-ab12-ab12-abcdef123456
10184

10285
### Configuration
10386

104-
The client can be configured through a properties file (
105-
see [app.properties](./bzst-dip-java-client-demo/src/main/resources/app.properties)
106-
and [ApplicationWithConfigurationFromProperties.java](./bzst-dip-java-client-demo/src/main/java/software/xdev/ApplicationWithConfigurationFromProperties.java))
107-
or by creating a configuration object (
108-
see [Application.java](./bzst-dip-java-client-demo/src/main/java/software/xdev/Application.java)).
87+
The client can be configured through a properties file (see [app.properties](./bzst-dip-java-client-demo/src/main/resources/app.properties) and [ApplicationWithConfigurationFromProperties.java](./bzst-dip-java-client-demo/src/main/java/software/xdev/ApplicationWithConfigurationFromProperties.java)) or by creating a configuration object (see [Application.java](./bzst-dip-java-client-demo/src/main/java/software/xdev/Application.java)).
10988

11089
```java
11190
public static BzstDipConfiguration createConfiguration()
@@ -130,8 +109,7 @@ public static BzstDipConfiguration createConfiguration()
130109

131110
## Support
132111

133-
If you need support as soon as possible, and you can't wait for any pull request, feel free to
134-
use [our support](https://xdev.software/en/services/support).
112+
If you need support as soon as possible, and you can't wait for any pull request, feel free to use [our support](https://xdev.software/en/services/support).
135113

136114
## Contributing
137115
See the [contributing guide](./CONTRIBUTING.md) for detailed instructions on how to get started with our project.

bzst-dip-java-client-demo/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
2727
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
2828

29-
<mainClass>software.xdev.bzst.dip.client.Application</mainClass>
29+
<mainClass>software.xdev.Application</mainClass>
3030
</properties>
3131

3232
<dependencies>
@@ -38,7 +38,7 @@
3838
<dependency>
3939
<groupId>org.apache.logging.log4j</groupId>
4040
<artifactId>log4j-slf4j2-impl</artifactId>
41-
<version>2.23.1</version>
41+
<version>2.24.1</version>
4242
</dependency>
4343
</dependencies>
4444

bzst-dip-java-client/pom.xml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@
115115
<dependency>
116116
<groupId>org.slf4j</groupId>
117117
<artifactId>slf4j-api</artifactId>
118-
<version>2.0.13</version>
118+
<version>2.0.16</version>
119119
</dependency>
120120
<dependency>
121121
<groupId>com.opencsv</groupId>
@@ -138,7 +138,7 @@
138138
<dependency>
139139
<groupId>org.apache.logging.log4j</groupId>
140140
<artifactId>log4j-slf4j2-impl</artifactId>
141-
<version>2.23.1</version>
141+
<version>2.24.1</version>
142142
<scope>test</scope>
143143
</dependency>
144144
</dependencies>
@@ -177,15 +177,15 @@
177177
<plugin>
178178
<groupId>org.apache.maven.plugins</groupId>
179179
<artifactId>maven-project-info-reports-plugin</artifactId>
180-
<version>3.6.2</version>
180+
<version>3.8.0</version>
181181
</plugin>
182182
</plugins>
183183
</pluginManagement>
184184
<plugins>
185185
<plugin>
186186
<groupId>com.mycila</groupId>
187187
<artifactId>license-maven-plugin</artifactId>
188-
<version>4.5</version>
188+
<version>4.6</version>
189189
<configuration>
190190
<properties>
191191
<email>${project.organization.url}</email>
@@ -225,7 +225,7 @@
225225
<plugin>
226226
<groupId>org.apache.maven.plugins</groupId>
227227
<artifactId>maven-javadoc-plugin</artifactId>
228-
<version>3.8.0</version>
228+
<version>3.10.1</version>
229229
<executions>
230230
<execution>
231231
<id>attach-javadocs</id>
@@ -281,7 +281,7 @@
281281
<plugin>
282282
<groupId>org.apache.maven.plugins</groupId>
283283
<artifactId>maven-gpg-plugin</artifactId>
284-
<version>3.2.4</version>
284+
<version>3.2.7</version>
285285
<executions>
286286
<execution>
287287
<id>sign-artifacts</id>
@@ -324,12 +324,12 @@
324324
<plugin>
325325
<groupId>org.apache.maven.plugins</groupId>
326326
<artifactId>maven-checkstyle-plugin</artifactId>
327-
<version>3.4.0</version>
327+
<version>3.5.0</version>
328328
<dependencies>
329329
<dependency>
330330
<groupId>com.puppycrawl.tools</groupId>
331331
<artifactId>checkstyle</artifactId>
332-
<version>10.17.0</version>
332+
<version>10.18.2</version>
333333
</dependency>
334334
</dependencies>
335335
<configuration>
@@ -355,7 +355,7 @@
355355
<plugin>
356356
<groupId>org.apache.maven.plugins</groupId>
357357
<artifactId>maven-pmd-plugin</artifactId>
358-
<version>3.24.0</version>
358+
<version>3.25.0</version>
359359
<configuration>
360360
<includeTests>true</includeTests>
361361
<printFailingErrors>true</printFailingErrors>
@@ -367,12 +367,12 @@
367367
<dependency>
368368
<groupId>net.sourceforge.pmd</groupId>
369369
<artifactId>pmd-core</artifactId>
370-
<version>7.3.0</version>
370+
<version>7.6.0</version>
371371
</dependency>
372372
<dependency>
373373
<groupId>net.sourceforge.pmd</groupId>
374374
<artifactId>pmd-java</artifactId>
375-
<version>7.3.0</version>
375+
<version>7.6.0</version>
376376
</dependency>
377377
</dependencies>
378378
</plugin>
@@ -384,7 +384,7 @@
384384
<plugin>
385385
<groupId>org.apache.maven.plugins</groupId>
386386
<artifactId>maven-jxr-plugin</artifactId>
387-
<version>3.4.0</version>
387+
<version>3.5.0</version>
388388
</plugin>
389389
</plugins>
390390
</reporting>

bzst-dip-java-client/src/main/java/software/xdev/bzst/dip/client/model/message/BzstDipCorrectableReportableSellerType.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,11 @@ public CorrectableReportableSellerType toXmlType(final BzstDipConfiguration conf
4949
this.tin.toXmlType(),
5050
this.handelsregisternummer,
5151
this.vat,
52-
this.firstName,
52+
this.firstName == null ? ReportableSellerCreator.NULL_STRING : this.firstName,
5353
this.lastName,
54-
this.birthDate.format(DateTimeFormatter.ISO_LOCAL_DATE),
54+
this.birthDate == null
55+
? ReportableSellerCreator.NULL_STRING
56+
: this.birthDate.format(DateTimeFormatter.ISO_LOCAL_DATE),
5557
this.legalAddress.toXmlType(),
5658
this.addressFix.toXmlType(),
5759
this.numberOfActivities.toXmlType(),

bzst-dip-java-client/src/main/java/software/xdev/bzst/dip/client/xmldocument/ReportableSellerCreator.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
public class ReportableSellerCreator
5151
{
5252
private static final Logger LOGGER = LoggerFactory.getLogger(ReportableSellerCreator.class);
53+
public static final String NULL_STRING = "NULL";
5354
private final BzstDipConfiguration configuration;
5455

5556
public ReportableSellerCreator(final BzstDipConfiguration configuration)
@@ -337,7 +338,7 @@ private static OrganisationPartyType createOrganisationPartyType(
337338
*/
338339
public static boolean isNULLAsString(final String checkNULLString)
339340
{
340-
return checkNULLString.equals("NULL");
341+
return checkNULLString.equals(NULL_STRING);
341342
}
342343

343344
private static OrganisationINType createIN(final String in)

pom.xml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,12 @@
4040
<plugin>
4141
<groupId>org.apache.maven.plugins</groupId>
4242
<artifactId>maven-checkstyle-plugin</artifactId>
43-
<version>3.4.0</version>
43+
<version>3.5.0</version>
4444
<dependencies>
4545
<dependency>
4646
<groupId>com.puppycrawl.tools</groupId>
4747
<artifactId>checkstyle</artifactId>
48-
<version>10.17.0</version>
48+
<version>10.18.2</version>
4949
</dependency>
5050
</dependencies>
5151
<configuration>
@@ -70,7 +70,7 @@
7070
<plugin>
7171
<groupId>org.apache.maven.plugins</groupId>
7272
<artifactId>maven-pmd-plugin</artifactId>
73-
<version>3.24.0</version>
73+
<version>3.25.0</version>
7474
<configuration>
7575
<includeTests>true</includeTests>
7676
<printFailingErrors>true</printFailingErrors>
@@ -82,12 +82,12 @@
8282
<dependency>
8383
<groupId>net.sourceforge.pmd</groupId>
8484
<artifactId>pmd-core</artifactId>
85-
<version>7.3.0</version>
85+
<version>7.6.0</version>
8686
</dependency>
8787
<dependency>
8888
<groupId>net.sourceforge.pmd</groupId>
8989
<artifactId>pmd-java</artifactId>
90-
<version>7.3.0</version>
90+
<version>7.6.0</version>
9191
</dependency>
9292
</dependencies>
9393
</plugin>
@@ -99,7 +99,7 @@
9999
<plugin>
100100
<groupId>org.apache.maven.plugins</groupId>
101101
<artifactId>maven-jxr-plugin</artifactId>
102-
<version>3.4.0</version>
102+
<version>3.5.0</version>
103103
</plugin>
104104
</plugins>
105105
</reporting>

0 commit comments

Comments
 (0)