In the documentation for the CPAN module DateTime I found the following:
Once you set the formatter, the overloaded stringification method will use th
Stringification methods are called when an object is used in a context where a string is expected. The method describes how to represent the object as a string. So for instance, if you say print object;
then since print is expecting a string, it's actually passing the result of the stringify method to print.