Question:
Say, I've three different modules, built with class objects tied to the module, and each of the three modules, have a common class object in a separate file for that class.
such that,
widget_processor_one
widget_processor_one.module
ClassObjectOne.php
ClassCommonThing.php
widget_processor_two
widget_processor_two.module
ClassObjectTwo.php
ClassCommonThing.php
widget_processor_three
widget_processor_three.module
ClassObjectThree.php
ClassCommonThing.php
when run, I end up with a "Fatal error: Cannot redeclare class ClassCommonThing...."
Does drupal have a common library area to put such things, such as a libs directory?
I doubt that "includes" was meant for this type of thing.
It doesn't seem that this type of structure is allowed.
How do I avoid class name collision and reuse the same class object without having to rename the thing?
Or is it intended that each module is independent and such sharing is not the drupal way.
Thanks