Esempio n. 1
0
        public override object Deserialize(IDictionary <string, object> dictionary, Type type, JavaScriptSerializer serializer)
        {
            WfUserResourceDescriptor userResourceDesp = (WfUserResourceDescriptor)base.Deserialize(dictionary, type, serializer);
            IUser user = JSONSerializerExecute.Deserialize <OguUser>(dictionary["User"]);

            userResourceDesp.User = user;

            return(userResourceDesp);
        }
Esempio n. 2
0
        public override IDictionary <string, object> Serialize(object obj, JavaScriptSerializer serializer)
        {
            WfUserResourceDescriptor userResourceDesp = (WfUserResourceDescriptor)obj;

            IDictionary <string, object> dictionary = base.Serialize(obj, serializer);

            dictionary.Add("User", userResourceDesp.User);

            return(dictionary);
        }