ResolvedResource Constructor (Stream, Encoding, string)ResolvedResource Constructor (Stream, Encoding, String)ResolvedResource Constructor (Stream^, Encoding^, String^)

Initializes a new instance of the ResolvedResourceResolvedResourceResolvedResource class.

Syntax

Public Sub New ( _
    stream As System.IO.Stream, _
    encoding As System.Text.Encoding, _
    mediaType As String _
)
public ResolvedResource(
    System.IO.Stream stream,
    System.Text.Encoding encoding,
    string mediaType
)
public:
ResolvedResource(
    System.IO::Stream^ stream, 
    System.Text::Encoding^ encoding, 
    String^ mediaType
)
 

Parameters

stream

Type: System.IO.StreamSystem.IO.StreamSystem.IO::Stream^

The resource.

encoding

Type: System.Text.EncodingSystem.Text.EncodingSystem.Text::Encoding^

The encoding of the resource (or null a null reference (Nothing in Visual Basic) nullptr if this is not known).

mediaType

Type: System.StringSystem.StringSystem::String^

The media type of the resource (or null a null reference (Nothing in Visual Basic) nullptr if this is not known).

Exceptions

ExceptionCondition
ArgumentNullExceptionArgumentNullExceptionArgumentNullExceptionstream is null a null reference (Nothing in Visual Basic) nullptr.
ArgumentExceptionArgumentExceptionArgumentException mediaType is not a valid media type, or contains a charset parameter that refers to a different encoding than encoding.

Remarks

If the media type has a charset parameter and encoding is null a null reference (Nothing in Visual Basic) nullptr then the charset parameter is used to identify the encoding.