International-Data-Spaces-Association / Java-Representation-of-IDS-Information-Model

Apache License 2.0
2 stars 7 forks source link

Feature Request: Overload toString #3

Open brianjahnke opened 3 years ago

brianjahnke commented 3 years ago

Hi,

at the moment the Infomodel does not overload the toString method and I would like to propose the toString method to return the same output as the toRdf method.

The output of toString at the moment look quite similiar to the output of toRdf, which leads to rather hard to spot errors. Also it would make it possible to drop the toRdf in some cases (e.g. when creating a HttpResponse in a SpringBoot controller where a Infomodel Object is returned as body), where the toString is automatically called. This would make the usage easier and safer.