Adding to existing DSL


A question regarding expanding the DSL with a plugin.

Is there a way to know the file (name/path) from which a POJO was define during the configuration time?

To be more concrete, users can add gradle files and in them lets say that they can define some Books DSL objects ( they can add those files in any depth in a specific directory.)
When using some of the plugin tasks, the code scan the whole directory and create the Book objects as defined by the users. In addition to capture the Book it self into a NamedDomainObjectContainer object i would like to capture the file (path) itself where the Book was define. Any suggestion?