FormatterServices FormatterServices FormatterServices FormatterServices Class

定義

提供靜態方法,協助序列化 (Serialization) Formatter 的實作。Provides static methods to aid with the implementation of a Formatter for serialization. 這個類別無法被繼承。This class cannot be inherited.

public ref class FormatterServices abstract sealed
[System.Runtime.InteropServices.ComVisible(true)]
public static class FormatterServices
type FormatterServices = class
Public Class FormatterServices
繼承
FormatterServicesFormatterServicesFormatterServicesFormatterServices
屬性

方法

CheckTypeSecurity(Type, TypeFilterLevel) CheckTypeSecurity(Type, TypeFilterLevel) CheckTypeSecurity(Type, TypeFilterLevel) CheckTypeSecurity(Type, TypeFilterLevel)

判斷 Type 屬性設為 Low 時是否可還原序列化指定的 TypeFilterLevelDetermines whether the specified Type can be deserialized with the TypeFilterLevel property set to Low.

GetObjectData(Object, MemberInfo[]) GetObjectData(Object, MemberInfo[]) GetObjectData(Object, MemberInfo[]) GetObjectData(Object, MemberInfo[])

從指定物件擷取資料,並將它傳回為物件陣列。Extracts the data from the specified object and returns it as an array of objects.

GetSafeUninitializedObject(Type) GetSafeUninitializedObject(Type) GetSafeUninitializedObject(Type) GetSafeUninitializedObject(Type)

建立指定物件型別的新執行個體。Creates a new instance of the specified object type.

GetSerializableMembers(Type) GetSerializableMembers(Type) GetSerializableMembers(Type) GetSerializableMembers(Type)

為指定 Type 的類別取得所有可序列化成員。Gets all the serializable members for a class of the specified Type.

GetSerializableMembers(Type, StreamingContext) GetSerializableMembers(Type, StreamingContext) GetSerializableMembers(Type, StreamingContext) GetSerializableMembers(Type, StreamingContext)

為指定 Type 的類別,並在所提供的 StreamingContext 中,取得所有可序列化成員。Gets all the serializable members for a class of the specified Type and in the provided StreamingContext.

GetSurrogateForCyclicalReference(ISerializationSurrogate) GetSurrogateForCyclicalReference(ISerializationSurrogate) GetSurrogateForCyclicalReference(ISerializationSurrogate) GetSurrogateForCyclicalReference(ISerializationSurrogate)

傳回指定之 ISerializationSurrogate 的序列化代理。Returns a serialization surrogate for the specified ISerializationSurrogate.

GetTypeFromAssembly(Assembly, String) GetTypeFromAssembly(Assembly, String) GetTypeFromAssembly(Assembly, String) GetTypeFromAssembly(Assembly, String)

在所提供的 Type 中查詢指定物件的 AssemblyLooks up the Type of the specified object in the provided Assembly.

GetUninitializedObject(Type) GetUninitializedObject(Type) GetUninitializedObject(Type) GetUninitializedObject(Type)

建立指定物件型別的新執行個體。Creates a new instance of the specified object type.

PopulateObjectMembers(Object, MemberInfo[], Object[]) PopulateObjectMembers(Object, MemberInfo[], Object[]) PopulateObjectMembers(Object, MemberInfo[], Object[]) PopulateObjectMembers(Object, MemberInfo[], Object[])

將取自物件資料陣列每個欄位的值填入指定物件。Populates the specified object with values for each field drawn from the data array of objects.

適用於

另請參閱