Hmmm... well we've just reached one of FlexXB's limitations. FlexXB
will not be able to properly deserialize the field because it desn't
know which field name we need to take into account since the name is
based on the value's type. ON serialize everything is fine. However on
deserialize, it doesn't know where to take the xml name from since it
has no fixed alias nor a fixed type.
What you can do is use virtual paths to have a well known element
wrapping your xml value:
[XmlClass(alias="TestVO")]
public class testVO {
[XmlElement(alias="intTest/*",getRunTimeType="true")]
public var intTest:ITest;
[XmlElement(alias="intTest1/*",getRunTimeType="true")]
public var intTest1:ITest;
public function testVO() {
}
}
The xml will look different but now the deserialization will work
properly because the engine knows where to look for the value
regardless of its type.
your xml will look like:
<TestVO>
<intTest>
<testVO6 test7Inst="test7"/>
</intTest>
<intTest1>
<testVO7 test6Inst="test6"/>
</intTest1>
</TestVO>
If this is not how your xml should look like then I'm sorry to say
that there is no way to fix this automatically and you should try the
manual way by implementing the ISerializable interface to add you type
detection and dispatching logic.
> > > > >
http://groups.google.com/group/flexxb?hl=en.-Hidequoted text -
>
> > > > - Show quoted text -
>
> > > --
> > > You received this message because you are subscribed to the Google Groups
> > > "FxWorks" group.
> > > To post to this group, send email to
fle...@googlegroups.com.
> > > To unsubscribe from this group, send email to
> > >
flexxb+un...@googlegroups.com.
> > > For more options, visit this group at
> > >
http://groups.google.com/group/flexxb?hl=en.- Ascundeţi textul citat -
>
> - Afişare text în citat -