Hi there,
it seems the XML mapping framework requires a class to define all mapped instance variables in the public interface.
If you have an attribute mapping like this:
<AttributeMapping ClassAttribute="firstname">
<Attribute>firstName</Attribute>
</AttributeMapping>
The instance variable of the mapped class will remain nil when deserialising as long as there is no attribute definition for the variable.
I'd consider this a bug, because I see no reason for an attribute definition in here at all, UNLESS there also is an InstVarMapping hidden somewhere in the framework...?
A simple approach to improving this is probably to first check for an attribute and after that a setter method of the same name, thus the existence of an attribute in the PI of a class would be respected, but if there is none, the instVar would be filled nevertheless.
I know I can add information on getters and setters in a mapping spec, but for cases in which getter and setter simply are the same as the instvar name (I guess 87 % of the time this is the case) this seems like overhead to me...
Ah, I've tried in VAST 8.0 and 7.5.
cu
Joachim