Muokkaa

Jaa


BinaryFormatter.SurrogateSelector Property

Definition

Gets or sets a ISurrogateSelector that controls type substitution during serialization and deserialization.

public:
 property System::Runtime::Serialization::ISurrogateSelector ^ SurrogateSelector { System::Runtime::Serialization::ISurrogateSelector ^ get(); void set(System::Runtime::Serialization::ISurrogateSelector ^ value); };
public System.Runtime.Serialization.ISurrogateSelector? SurrogateSelector { get; set; }
public System.Runtime.Serialization.ISurrogateSelector SurrogateSelector { get; set; }
member this.SurrogateSelector : System.Runtime.Serialization.ISurrogateSelector with get, set
Public Property SurrogateSelector As ISurrogateSelector

Property Value

The surrogate selector to use with this formatter.

Implements

Remarks

Warning

BinaryFormatter is insecure and can't be made secure. For more information, see the BinaryFormatter security guide.

The surrogate selector is used by System.Runtime.Remoting to generate ObjRef instances for objects that derive from MarshalByRefObject.

Applies to

See also