protected virtual IDictionary <string, string> DeserializeStringDictionary(string inputText) { var stringDictionaryParser = new MvxStringDictionaryParser(); var dictionary = stringDictionaryParser.Parse(inputText); return(dictionary); }
protected virtual MvxViewModelRequest DeserializeViewModelRequest(string inputText) { var stringDictionaryParser = new MvxStringDictionaryParser(); var dictionary = stringDictionaryParser.Parse(inputText); var toReturn = new MvxViewModelRequest(); var viewModelTypeName = SafeGetValue(dictionary, "Type"); toReturn.ViewModelType = DeserializeViewModelType(viewModelTypeName); toReturn.ParameterValues = stringDictionaryParser.Parse(SafeGetValue(dictionary, "Params")); toReturn.PresentationValues = stringDictionaryParser.Parse(SafeGetValue(dictionary, "Pres")); return toReturn; }
protected virtual MvxViewModelRequest DeserializeViewModelRequest(string inputText) { var stringDictionaryParser = new MvxStringDictionaryParser(); var dictionary = stringDictionaryParser.Parse(inputText); var toReturn = new MvxViewModelRequest(); var viewModelTypeName = this.SafeGetValue(dictionary, "Type"); toReturn.ViewModelType = this.DeserializeViewModelType(viewModelTypeName); toReturn.RequestedBy = new MvxRequestedBy { Type = (MvxRequestedByType)int.Parse(this.SafeGetValue(dictionary, "By")), AdditionalInfo = this.SafeGetValue(dictionary, "Info") }; toReturn.ParameterValues = stringDictionaryParser.Parse(this.SafeGetValue(dictionary, "Params")); toReturn.PresentationValues = stringDictionaryParser.Parse(this.SafeGetValue(dictionary, "Pres")); return(toReturn); }