The decorator pattern has been added.
The Magic methods  have been corrected.