Formatter.SurrogateSelector Formatter.SurrogateSelector Formatter.SurrogateSelector Formatter.SurrogateSelector Property

定義

當覆寫於衍生類別時,取得或設定與目前的格式子使用的 ISurrogateSelectorWhen overridden in a derived class, gets or sets the ISurrogateSelector used with the current formatter.

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

屬性值

搭配目前格式器使用的 ISurrogateSelectorThe ISurrogateSelector used with the current formatter.

實作

備註

使用SurrogateSelector查閱實作ISerializationSurrogate,以控制特定類型的序列化。Use the SurrogateSelector to look up implementations of ISerializationSurrogate that control the serialization of a particular type.

如果物件型別具有相符的 surrogate,則序列化和還原序列化會遞交給代理即使該類型實作了ISerializable介面。If an object type has a matching surrogate, then serialization and deserialization are handed off to the surrogate even if the type implements the ISerializable interface.

給繼承者的注意事項

您必須在衍生類別中實作這個屬性。You must implement this property in a derived class.

適用於