in src/nms-api/Util/Convert.cs [111:134]
internal static object DeserializeObjFromMessage(IMessage message)
{
ITextMessage textMessage = message as ITextMessage;
if (null == textMessage)
{
return null;
}
if (string.IsNullOrEmpty(textMessage.NMSType))
{
Tracer.ErrorFormat("NMSType not set on message. Could not deserializing XML object.");
return null;
}
Type objType = GetRuntimeType(textMessage.NMSType);
if (null == objType)
{
Tracer.ErrorFormat("Could not load type for {0} while deserializing XML object.", textMessage.NMSType);
return null;
}
return XmlUtil.Deserialize(objType, textMessage.Text);
}