StreamingContextStates 列舉

定義

警告

Formatter-based serialization is obsolete and should not be used.

定義一組旗標,指定序列化期間資料流的來源或目的內容。

此列舉支援其成員值的位元組合。

public enum class StreamingContextStates
[System.Flags]
public enum StreamingContextStates
[System.Flags]
[System.Obsolete("Formatter-based serialization is obsolete and should not be used.", DiagnosticId="SYSLIB0050", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public enum StreamingContextStates
[System.Flags]
[System.Serializable]
public enum StreamingContextStates
[System.Flags]
[System.Serializable]
[System.Runtime.InteropServices.ComVisible(true)]
public enum StreamingContextStates
[<System.Flags>]
type StreamingContextStates = 
[<System.Flags>]
[<System.Obsolete("Formatter-based serialization is obsolete and should not be used.", DiagnosticId="SYSLIB0050", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
type StreamingContextStates = 
[<System.Flags>]
[<System.Serializable>]
type StreamingContextStates = 
[<System.Flags>]
[<System.Serializable>]
[<System.Runtime.InteropServices.ComVisible(true)>]
type StreamingContextStates = 
Public Enum StreamingContextStates
繼承
StreamingContextStates
屬性

欄位

All 255

指定序列化的資料可以傳輸到或接收自任何其他內容。

Clone 64

指定物件圖形會被複製。 使用者可以假設複製的圖形將會繼續存在相同的處理序內,且存取控制代碼或其他未受管理資源的參考是安全的。

CrossAppDomain 128

指定來源或目的內容為不同的 AppDomain。 (如需 AppDomain 的描述,請參閱應用程式定義域)。

CrossMachine 2

指定來源或目的內容為不同的電腦。

CrossProcess 1

指定來源或目的內容為相同電腦上的不同處理序。

File 4

指定來源或目的內容為檔案。 使用者可以假設檔案將會比建立它們的處理序更持久,並且不會以還原序列化將需要存取來自目前處理序之任何資料的方式序列化物件。

Other 32

指定序列化內容為未知。

Persistence 8

指定來源或目的內容為持續性存放區,其中可包括資料庫、檔案或其他備份存放區。 使用者可以假設持續性資料將會比建立該資料的處理序更持久,並且不會序列化物件,如此還原序列化將需要存取來自目前處理序的任何資料。

Remoting 16

指定資料是在未知的位置中遠端處理至內容。 無論這是否在相同電腦上,使用者無法做出任何假設。

適用於

另請參閱