[FEATURE] Make sample transformation a singleton

To show a bette example, make the sample transformation class
a singleton.

Resolves: #58399
Releases: 2.3
Change-Id: I5ffa55069cc424baf47c1127652ee8344d817980
Reviewed-on: https://review.typo3.org/30505
Reviewed-by: Francois Suter
Tested-by: Francois Suter