Class StreamResourceInfo
Provides resource stream information for application resources or other packages obtained through the GetResourceStream(StreamResourceInfo, Uri) method.
Inheritance
System.Object
StreamResourceInfo
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: System.Windows.Resources
Assembly: OpenSilver.dll
Syntax
public class StreamResourceInfo
Constructors
| Improve this Doc View SourceStreamResourceInfo()
Initializes a new instance of the StreamResourceInfo class.
Declaration
public StreamResourceInfo()
StreamResourceInfo(Stream, String)
Initializes a new instance of the StreamResourceInfo class.
Declaration
public StreamResourceInfo(Stream stream, string contentType)
Parameters
Type | Name | Description |
---|---|---|
System.IO.Stream | stream | The stream to use to create the resource. |
System.String | contentType | The MIME type of the content. |
Exceptions
Type | Condition |
---|---|
System.ArgumentNullException | stream is null. |
Properties
| Improve this Doc View SourceContentType
Gets the MIME type of the content in the stream.
Declaration
public string ContentType { get; }
Property Value
Type | Description |
---|---|
System.String | The MIME type of the content in the stream, as a string. |
Stream
Gets the stream that is contained by the resource.
Declaration
public Stream Stream { get; }
Property Value
Type | Description |
---|---|
System.IO.Stream | The stream that is contained by the resource. |