Show / Hide Table of Contents

Class AttachmentContainer

A container for attachment files, which may or may not have been downloaded into local memory or storage.

Inheritance
System.Object
AttachmentContainer
Implements
IAttachmentContainer
System.Collections.Generic.IEnumerable<AttachmentInfo>
System.Collections.IEnumerable
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: CrashCABN.Metadata
Assembly: CrashCABN.Metadata.Attachments.dll
Syntax
public sealed class AttachmentContainer : IAttachmentContainer, IEnumerable<AttachmentInfo>, IEnumerable

Constructors

View Source

AttachmentContainer(IAttachmentProcessor, AttachmentInfo[])

Initializes a new instance of the AttachmentContainer class.

Declaration
public AttachmentContainer(IAttachmentProcessor processor, params AttachmentInfo[] attachments)
Parameters
Type Name Description
IAttachmentProcessor processor

The attachment processor.

AttachmentInfo[] attachments

The attachments.

Methods

View Source

GetEnumerator()

Gets the attachments.

Declaration
public IEnumerator<AttachmentInfo> GetEnumerator()
Returns
Type Description
System.Collections.Generic.IEnumerator<AttachmentInfo>
View Source

Load(String)

Declaration
public async ValueTask<object> Load(string name)
Parameters
Type Name Description
System.String name
Returns
Type Description
System.Threading.Tasks.ValueTask<System.Object>
View Source

Load<T>(String)

Declaration
public async ValueTask<T> Load<T>(string name)
Parameters
Type Name Description
System.String name
Returns
Type Description
System.Threading.Tasks.ValueTask<T>
Type Parameters
Name Description
T
View Source

TryLoad(String)

Loads an attachment from the IAttachmentContainer.

Declaration
public async ValueTask<object> TryLoad(string name)
Parameters
Type Name Description
System.String name

The name of the attachment to load.

Returns
Type Description
System.Threading.Tasks.ValueTask<System.Object>

A task representing the attachment contents, or null if the attachment was missing.

Explicit Interface Implementations

View Source

IEnumerable.GetEnumerator()

Declaration
IEnumerator IEnumerable.GetEnumerator()
Returns
Type Description
System.Collections.IEnumerator

Implements

IAttachmentContainer
System.Collections.Generic.IEnumerable<T>
System.Collections.IEnumerable
  • View Source
In This Article
Back to top Generated by DocFX