LinkedResource 類別

定義

表示電子郵件附件中的內嵌外部資源,例如 HTML 附件中的影像。Represents an embedded external resource in an email attachment, such as an image in an HTML attachment.

public ref class LinkedResource : System::Net::Mail::AttachmentBase
public class LinkedResource : System.Net.Mail.AttachmentBase
type LinkedResource = class
    inherit AttachmentBase
Public Class LinkedResource
Inherits AttachmentBase
繼承
LinkedResource

建構函式

LinkedResource(Stream)

使用所提供的 LinkedResource,初始化 Stream 的新執行個體。Initializes a new instance of LinkedResource using the supplied Stream.

LinkedResource(Stream, ContentType)

使用 LinkedResourceStream 所提供的值,初始化 ContentType 的新執行個體。Initializes a new instance of LinkedResource with the values supplied by Stream and ContentType.

LinkedResource(Stream, String)

使用指定的 LinkedResource 和媒體類型,初始化 Stream 的新執行個體。Initializes a new instance of LinkedResource with the specified Stream and media type.

LinkedResource(String)

使用指定的檔案名稱,初始化 LinkedResource 的新執行個體。Initializes a new instance of LinkedResource using the specified file name.

LinkedResource(String, ContentType)

使用指定的檔案名稱和內容類型,初始化 LinkedResource 的新執行個體。Initializes a new instance of LinkedResource with the specified file name and content type.

LinkedResource(String, String)

使用指定的檔案名稱和媒體類型,初始化 LinkedResource 的新執行個體。Initializes a new instance of LinkedResource with the specified file name and media type.

屬性

ContentId

取得或設定這個附件的 MIME 內容識別碼。Gets or sets the MIME content ID for this attachment.

(繼承來源 AttachmentBase)
ContentLink

取得或設定資源必須符合的 URI。Gets or sets a URI that the resource must match.

ContentStream

取得這個附件的內容資料流。Gets the content stream of this attachment.

(繼承來源 AttachmentBase)
ContentType

取得這個附件的內容類型。Gets the content type of this attachment.

(繼承來源 AttachmentBase)
TransferEncoding

取得或設定這個附件的編碼方式。Gets or sets the encoding of this attachment.

(繼承來源 AttachmentBase)

方法

CreateLinkedResourceFromString(String)

從要包含在電子郵件附件中做為內嵌資源的字串,建立 LinkedResource 物件。Creates a LinkedResource object from a string to be included in an email attachment as an embedded resource. 預設媒體類型為純文字,而預設內容類型為 ASCII。The default media type is plain text, and the default content type is ASCII.

CreateLinkedResourceFromString(String, ContentType)

使用指定的內容類型以及純文字的媒體類型,從要包含在電子郵件附件中做為內嵌資源的字串,建立 LinkedResource 物件。Creates a LinkedResource object from a string to be included in an email attachment as an embedded resource, with the specified content type, and media type as plain text.

CreateLinkedResourceFromString(String, Encoding, String)

使用指定的內容類型和媒體類型,從要包含在電子郵件附件中做為內嵌資源的字串,建立 LinkedResource 物件。Creates a LinkedResource object from a string to be included in an email attachment as an embedded resource, with the specified content type, and media type.

Dispose()

釋放 AttachmentBase 使用的資源。Releases the resources used by the AttachmentBase.

(繼承來源 AttachmentBase)
Dispose(Boolean)

釋放 AttachmentBase 所使用的 Unmanaged 資源,並選擇性地釋放 Managed 資源。Releases the unmanaged resources used by the AttachmentBase and optionally releases the managed resources.

(繼承來源 AttachmentBase)
Equals(Object)

判斷指定的物件是否等於目前的物件。Determines whether the specified object is equal to the current object.

(繼承來源 Object)
GetHashCode()

作為預設雜湊函數。Serves as the default hash function.

(繼承來源 Object)
GetType()

取得目前執行個體的 TypeGets the Type of the current instance.

(繼承來源 Object)
MemberwiseClone()

建立目前 Object 的淺層複製。Creates a shallow copy of the current Object.

(繼承來源 Object)
ToString()

傳回代表目前物件的字串。Returns a string that represents the current object.

(繼承來源 Object)

適用於