Redigera

Dela via


LinkedResource Constructors

Definition

Initializes a new instance of LinkedResource.

Overloads

LinkedResource(Stream)

Initializes a new instance of LinkedResource using the supplied Stream.

LinkedResource(String)

Initializes a new instance of LinkedResource using the specified file name.

LinkedResource(Stream, ContentType)

Initializes a new instance of LinkedResource with the values supplied by Stream and ContentType.

LinkedResource(Stream, String)

Initializes a new instance of LinkedResource with the specified Stream and media type.

LinkedResource(String, ContentType)

Initializes a new instance of LinkedResource with the specified file name and content type.

LinkedResource(String, String)

Initializes a new instance of LinkedResource with the specified file name and media type.

LinkedResource(Stream)

Source:
LinkedResource.cs
Source:
LinkedResource.cs
Source:
LinkedResource.cs

Initializes a new instance of LinkedResource using the supplied Stream.

public:
 LinkedResource(System::IO::Stream ^ contentStream);
public LinkedResource (System.IO.Stream contentStream);
new System.Net.Mail.LinkedResource : System.IO.Stream -> System.Net.Mail.LinkedResource
Public Sub New (contentStream As Stream)

Parameters

contentStream
Stream

A stream that contains the content for this embedded resource.

Exceptions

contentStream is null.

Applies to

LinkedResource(String)

Source:
LinkedResource.cs
Source:
LinkedResource.cs
Source:
LinkedResource.cs

Initializes a new instance of LinkedResource using the specified file name.

public:
 LinkedResource(System::String ^ fileName);
public LinkedResource (string fileName);
new System.Net.Mail.LinkedResource : string -> System.Net.Mail.LinkedResource
Public Sub New (fileName As String)

Parameters

fileName
String

The file name holding the content for this embedded resource.

Exceptions

fileName is null.

Applies to

LinkedResource(Stream, ContentType)

Source:
LinkedResource.cs
Source:
LinkedResource.cs
Source:
LinkedResource.cs

Initializes a new instance of LinkedResource with the values supplied by Stream and ContentType.

public:
 LinkedResource(System::IO::Stream ^ contentStream, System::Net::Mime::ContentType ^ contentType);
public LinkedResource (System.IO.Stream contentStream, System.Net.Mime.ContentType? contentType);
public LinkedResource (System.IO.Stream contentStream, System.Net.Mime.ContentType contentType);
new System.Net.Mail.LinkedResource : System.IO.Stream * System.Net.Mime.ContentType -> System.Net.Mail.LinkedResource
Public Sub New (contentStream As Stream, contentType As ContentType)

Parameters

contentStream
Stream

A stream that contains the content for this embedded resource.

contentType
ContentType

The type of the content.

Exceptions

contentStream is null.

contentType is not a valid value.

Applies to

LinkedResource(Stream, String)

Source:
LinkedResource.cs
Source:
LinkedResource.cs
Source:
LinkedResource.cs

Initializes a new instance of LinkedResource with the specified Stream and media type.

public:
 LinkedResource(System::IO::Stream ^ contentStream, System::String ^ mediaType);
public LinkedResource (System.IO.Stream contentStream, string? mediaType);
public LinkedResource (System.IO.Stream contentStream, string mediaType);
new System.Net.Mail.LinkedResource : System.IO.Stream * string -> System.Net.Mail.LinkedResource
Public Sub New (contentStream As Stream, mediaType As String)

Parameters

contentStream
Stream

A stream that contains the content for this embedded resource.

mediaType
String

The MIME media type of the content.

Exceptions

contentStream is null.

mediaType is not a valid value.

Applies to

LinkedResource(String, ContentType)

Source:
LinkedResource.cs
Source:
LinkedResource.cs
Source:
LinkedResource.cs

Initializes a new instance of LinkedResource with the specified file name and content type.

public:
 LinkedResource(System::String ^ fileName, System::Net::Mime::ContentType ^ contentType);
public LinkedResource (string fileName, System.Net.Mime.ContentType? contentType);
public LinkedResource (string fileName, System.Net.Mime.ContentType contentType);
new System.Net.Mail.LinkedResource : string * System.Net.Mime.ContentType -> System.Net.Mail.LinkedResource
Public Sub New (fileName As String, contentType As ContentType)

Parameters

fileName
String

The file name that holds the content for this embedded resource.

contentType
ContentType

The type of the content.

Exceptions

fileName is null.

contentType is not a valid value.

Applies to

LinkedResource(String, String)

Source:
LinkedResource.cs
Source:
LinkedResource.cs
Source:
LinkedResource.cs

Initializes a new instance of LinkedResource with the specified file name and media type.

public:
 LinkedResource(System::String ^ fileName, System::String ^ mediaType);
public LinkedResource (string fileName, string? mediaType);
public LinkedResource (string fileName, string mediaType);
new System.Net.Mail.LinkedResource : string * string -> System.Net.Mail.LinkedResource
Public Sub New (fileName As String, mediaType As String)

Parameters

fileName
String

The file name that holds the content for this embedded resource.

mediaType
String

The MIME media type of the content.

Exceptions

fileName is null.

mediaType is not a valid value.

Applies to