This project is read-only.

portable class library support

Sep 24, 2011 at 5:42 PM

Are you planning to support portable class libraries?

looks like a very good fit for the project

Sep 25, 2011 at 1:35 PM

hi, many thanks for the link. However I don't know if making SharpSerializer portable is necessary.There are no complains upto now.

If SharpSerializer would be unified for all the plattforms (.NET Full, Silverlight, WP7) it should resign serializing of:

  • LowerBound of an array
  • decimal type

in .NET full, as this is not supported by Silverlight and WP7.

Sep 25, 2011 at 8:25 PM

The reason I got interested is mostly related to wp7/silverlight development.

The problem with silverlight class libraries is that you cannot use them with the normal Unit Test packages. To be honest, silverlight testing is pain the rear. When portable library came into existence it allowed me to push significant part of functionality into portable libraries with decent unit test framework.

You're right, you indeed would have to give up on lowerbound and decimal type. I actually downloaded your code and tried to do exactly that  - cut out these features and compile sharpSerializer as a portable library. 

When I looked at source control I found out that I modified:

  • SharpSerializer.cs
  • BinaryPropertyDeserializer.cs
  • BinaryPropertySerializer.cs
  • SharpSerialiPropertySerializer.cs
  • SharpSerialiProperty.cs
  • Tools.cs
  • SharpSerialiObjectFactory.cs
  • SharpSerialiAssemblyInfo.cs
  • SharpSerialiPropertyFactory.cs



I ran over the budget of time I gave myself to do it (4 hours). So now I am using standard serialization provided by the silverlight runtime though I think sharpSerializer is a better fit.

sharpSerializer is a great product and not having support for the portable lib is definitely not a show stopper but I think it is reasonable to have a portable library without these two features, and two more libraries  built against .Net and Silverlight with the features.