internal UnitySerializationHolder(SerializationInfo info, StreamingContext context)
{
if (info == null)
throw new ArgumentNullException("info");
m_unityType = info.GetInt32("UnityType");
if (m_unityType == MissingUnity)
return;
if (m_unityType == GenericParameterTypeUnity)
{
m_declaringMethod = info.GetValue("DeclaringMethod", typeof(MethodBase)) as MethodBase;
m_declaringType = info.GetValue("DeclaringType", typeof(Type)) as Type;
m_genericParameterPosition = info.GetInt32("GenericParameterPosition");
m_elementTypes = info.GetValue("ElementTypes", typeof(int[])) as int[];
return;
}
if (m_unityType == PartialInstantiationTypeUnity)
{
m_instantiation = info.GetValue("GenericArguments", typeof(Type[])) as Type[];
m_elementTypes = info.GetValue("ElementTypes", typeof(int[])) as int[];
}
m_data = info.GetString("Data");
m_assemblyName = info.GetString("AssemblyName");
}
#endregion