Udostępnij za pośrednictwem


FieldInfo.IsNotSerialized Property

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Gets a value that indicates whether this field has the NotSerialized attribute.

Namespace:  System.Reflection
Assembly:  mscorlib (in mscorlib.dll)

Syntax

'Declaration
Public ReadOnly Property IsNotSerialized As Boolean
public bool IsNotSerialized { get; }

Property Value

Type: System.Boolean
true if the field has the NotSerialized attribute set; otherwise, false.

Exceptions

Exception Condition
MethodAccessException

This member is invoked late-bound through mechanisms such as Type.InvokeMember.

Remarks

The IsNotSerialized property returns true when the field is marked with the NotSerialized flag. When this flag is set on a field, it indicates that the field does not have to be serialized when the type is remoted.

Version Information

Silverlight

Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1, Windows Phone OS 7.0

XNA Framework

Supported in: Xbox 360, Windows Phone OS 7.0

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.