private void InitReadConstructor(Type objectType, ISurrogateSelector surrogateSelector, StreamingContext context)
{
if (objectType.IsArray)
{
InitNoMembers();
return;
}
ISurrogateSelector surrogateSelectorTemp = null;
if (surrogateSelector != null)
{
_serializationSurrogate = surrogateSelector.GetSurrogate(objectType, context, out surrogateSelectorTemp);
}
if (_serializationSurrogate != null)
{
_isSi = true;
}
else if (!ReferenceEquals(objectType, Converter.s_typeofObject) && Converter.s_typeofISerializable.IsAssignableFrom(objectType))
{
_isSi = true;
}
if (_isSi)
{
InitSiRead();
}
else
{
InitMemberInfo();
}
}