Class FileAttachment
- Namespace
- Rustaveli.Pdf
- Assembly
- Rustaveli.Pdf.Operations.dll
A file carried inside a PDF, listed among its attachments: the XML of an electronic invoice, a spreadsheet of the figures a report shows, the source a drawing was made from.
public sealed class FileAttachment
- Inheritance
-
FileAttachment
- Inherited Members
Constructors
FileAttachment(string, byte[])
An attachment of content, listed as name.
public FileAttachment(string name, byte[] content)
Parameters
Properties
Content
public byte[] Content { get; }
Property Value
- byte[]
CreationDate
public DateTimeOffset? CreationDate { get; init; }
Property Value
Description
What the file is, as readers show it beside the name.
public string? Description { get; init; }
Property Value
MediaType
The file's media type, such as text/xml; PDF/A-3 requires one.
public string? MediaType { get; init; }
Property Value
ModificationDate
When the file last changed; PDF/A-3 requires one, and the moment of saving stands in when none is given.
public DateTimeOffset? ModificationDate { get; init; }
Property Value
Name
The file's name as readers list it, such as factur-x.xml.
public string Name { get; }
Property Value
Relationship
How the file relates to the document, as PDF/A-3 records it.
public AttachmentRelationship Relationship { get; init; }
Property Value
Methods
FromFile(string)
An attachment of the file at path, listed by its file name.
public static FileAttachment FromFile(string path)
Parameters
pathstring