Problem with a two level dictionary return values.

Options
markharoldr
edited March 2012 in Photon Server
Hello Everyone,

I created an object in the server with the type Dictionary<string,Dictionary<string,string>>. When I try to retrieve it from the client, a casting error appears because its type became a Dictionary<string,IDictionary>.

How can i solve this?

Yours,
Mark

Comments

  • dreamora
    Options
    write an own serialization that can handle that.

    Generally Dictionary<,> is not serializable itself, as such it has explicit code to cover it, you would need to use SerializableDictionary (google it) in case there is 'automatic reflection' for such cases where you need Dictionary + serializable
  • Tobias
    Options
    Which client do you use?
    Dictionary<type,type> should work (also as type in something else).