internal UTF8Encoder(SerializationInfo info, StreamingContext context)
{
// Any info?
if (info==null) throw new ArgumentNullException("info");
// Get common info
this.m_encoding = (Encoding)info.GetValue("encoding", typeof(Encoding));
// SurrogateChar happens to mean the same thing
this.surrogateChar = (int)info.GetValue("surrogateChar", typeof(int));
try
{
this.m_fallback = (EncoderFallback) info.GetValue("m_fallback", typeof(EncoderFallback));
}
catch (SerializationException)
{
this.m_fallback = null;
}
}