StreamingContext Constructors
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Initializes a new instance of the StreamingContext class.
StreamingContext(StreamingContextStates) |
Obsolete.
Initializes a new instance of the StreamingContext class with a given context state. |
StreamingContext(StreamingContextStates, Object) |
Obsolete.
Initializes a new instance of the StreamingContext class with a given context state, and some additional information. |
- Source:
- StreamingContext.cs
- Source:
- StreamingContext.cs
- Source:
- StreamingContext.cs
Caution
Formatter-based serialization is obsolete and should not be used.
Initializes a new instance of the StreamingContext class with a given context state.
public:
StreamingContext(System::Runtime::Serialization::StreamingContextStates state);
public StreamingContext (System.Runtime.Serialization.StreamingContextStates state);
[System.Obsolete("Formatter-based serialization is obsolete and should not be used.", DiagnosticId="SYSLIB0050", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public StreamingContext (System.Runtime.Serialization.StreamingContextStates state);
new System.Runtime.Serialization.StreamingContext : System.Runtime.Serialization.StreamingContextStates -> System.Runtime.Serialization.StreamingContext
[<System.Obsolete("Formatter-based serialization is obsolete and should not be used.", DiagnosticId="SYSLIB0050", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
new System.Runtime.Serialization.StreamingContext : System.Runtime.Serialization.StreamingContextStates -> System.Runtime.Serialization.StreamingContext
Public Sub New (state As StreamingContextStates)
Parameters
- state
- StreamingContextStates
A bitwise combination of the StreamingContextStates values that specify the source or destination context for this StreamingContext.
- Attributes
See also
Applies to
.NET 9 and other versions
Product | Versions (Obsolete) |
---|---|
.NET | Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7 (8, 9) |
.NET Framework | 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0, 2.1 |
- Source:
- StreamingContext.cs
- Source:
- StreamingContext.cs
- Source:
- StreamingContext.cs
Caution
Formatter-based serialization is obsolete and should not be used.
Initializes a new instance of the StreamingContext class with a given context state, and some additional information.
public:
StreamingContext(System::Runtime::Serialization::StreamingContextStates state, System::Object ^ additional);
public StreamingContext (System.Runtime.Serialization.StreamingContextStates state, object? additional);
[System.Obsolete("Formatter-based serialization is obsolete and should not be used.", DiagnosticId="SYSLIB0050", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public StreamingContext (System.Runtime.Serialization.StreamingContextStates state, object? additional);
public StreamingContext (System.Runtime.Serialization.StreamingContextStates state, object additional);
new System.Runtime.Serialization.StreamingContext : System.Runtime.Serialization.StreamingContextStates * obj -> System.Runtime.Serialization.StreamingContext
[<System.Obsolete("Formatter-based serialization is obsolete and should not be used.", DiagnosticId="SYSLIB0050", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
new System.Runtime.Serialization.StreamingContext : System.Runtime.Serialization.StreamingContextStates * obj -> System.Runtime.Serialization.StreamingContext
Public Sub New (state As StreamingContextStates, additional As Object)
Parameters
- state
- StreamingContextStates
A bitwise combination of the StreamingContextStates values that specify the source or destination context for this StreamingContext.
- additional
- Object
Any additional information to be associated with the StreamingContext. This information is available to any object that implements ISerializable or any serialization surrogate. Most users do not need to set this parameter.
- Attributes
See also
Applies to
.NET 9 and other versions
Product | Versions (Obsolete) |
---|---|
.NET | Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7 (8, 9) |
.NET Framework | 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0, 2.1 |
.NET feedback
.NET is an open source project. Select a link to provide feedback: