Apply() public method

public Apply ( string text ) : string
text string
return string
		private IMessage[] ApplyPatchesAndDeserialize(SerializationPatcher serializationPatcher, XmlDocument xmlDocument)
		{
			var patchedText = serializationPatcher.Apply(xmlDocument.InnerXml);
			var patchedXmlDocument = new XmlDocument();
			patchedXmlDocument.LoadXml(patchedText);
			return Deserialize(patchedXmlDocument).Item1;
		}
		public static object Deserialize(XDocument stateData, string keyType)
		{
			try
			{
				return DeserializeInternal(stateData, keyType);
			}
			catch (Exception)
			{
				var reader = stateData.CreateReader();
				reader.MoveToContent();
				var readOuterXml = reader.ReadOuterXml();
				var serializationPatcher = new SerializationPatcher(new[] { new RemoveBackingFieldPatch(keyType) });
				if (serializationPatcher.ShouldApply(readOuterXml))
				{
					var patchedText = serializationPatcher.Apply(readOuterXml);
					return DeserializeInternal(XDocument.Parse(patchedText), keyType);
				}

				throw;
			}
		}