[Mono-list] Re: System.Xml.Serialization.XmlSerializer
ginga@kit.hi-ho.ne.jp
ginga@kit.hi-ho.ne.jp
Fri, 31 Jan 2003 04:21:53 +0900
Hello,
> Does the mono implementation of System.Xml.Serialization.XmlSerializer al=
low
> methods or properties to use interfaces? An interface and an abstract cl=
ass
> should work exchangeable but the Microsoft runtime does not allow interfa=
ces
> even when using the XmlElement(Type =3D typeof(someType)) attribute on th=
at
> property.
=2E..Oops, your code didn't work well with current mono library.
There must be something wrong with XmlSerializer class;-)
IMHO, it it impossible to serialize instance fields because we cannot
decide that interface field is of a public class, and we cannot create
instance only from interface information (i.e. without any concrete
class information). Hmm... I wonder how Castor handles such things...
This page might informative for you:
http://www.dotnet247.com/247reference/msgs/16/80980.aspx
Cheers,
-- Atsushi Eno