Greetings,
I’m wrting my own classes that inherit from TObject, but I don’t understand the source of the following warning. I have searched the forums, searched the manual, and googled. I am in the process of trying to reproducing it with the smallest amount of code possible, but any suggestions for where to look for the source of the warning would be appreciated.
[Given at run time:]
[quote]Warning in TKey::TKey: since TStudy_Data had no public constructor
which can be called without argument, objects of this class
can not be read with the current library. You would need to
add a default constructor before attempting to read it.[/quote]
Whats confusing is that I’m using the default constructor in the context which this appears:
TStudy_Data *study_data = new TStudy_Data();
study_data->Write("test_write",TObject::kOverwrite);
No warnings occur at compile or link time. TStudy_Data inherits publicly from TStudy(pure abstract), which inherits publicly from TObject.
I found this:
[quote]Warning in TBuffer::WriteObjectAny: since Trk::Segment had no public constructor
which can be called without argument, objects of this class
can not be read with the current library. You would need to
add a default constructor before attempting to read it.
Solution
This is a very confusing error message. What it actually means is that there is no dictionary for the concrete implementation of Segment (in this case MuonSegment). The fix was to create the selection.xml etc for MuonSegment, and then to add the dict jobOptions to the top jobOptions. [/quote]
at this atlas wiki: https://twiki.cern.ch/twiki/bin/view/Atlas/TroubleshootingPersistency, but its not really helpful, as that my dictionary for this class seems to be complete, and all my methods are defined, so the vtable should be complete, too. All constructors and methods for this class seem to be working when called in my code, but TKey, TBuffer etc don’t seem to be getting all the information they need.
Thanks,
Homer