Get all of the serializable members for a particular class.
[Visual Basic] Overloads Public Shared Function GetSerializableMembers( _ ByVal type As Type, _ ByVal context As StreamingContext _ ) As MemberInfo () [C#] public static MemberInfo[] GetSerializableMembers( Type type, StreamingContext context ); [C++] public: static MemberInfo* GetSerializableMembers( Type* type, StreamingContext context ) []; [JScript] public static function GetSerializableMembers( type : Type, context : StreamingContext ) : MemberInfo[];
Exception Type | Condition |
---|---|
ArgumentNullException | The type parameter is a null reference (in Visual Basic Nothing). |
For all practical intents and purposes, the serializable members of a class are the non-transient, non-static members (fields and properties). In order to be included, properties must have both a getter and a setter. A class, which implements ISerializable or has a serialization surrogate may not use all of these members (or may have additional members).
Currently, we only do anything different if context has the StreamingContextStates value Clone set.
FormatterServices Class | FormatterServices Members | System.Runtime.Serialization Namespace | FormatterServices.GetSerializableMembers Overload List