AngleSharp by AngleSharp

<PackageReference Include="AngleSharp" Version="0.9.7" />

 FileDataSetEntry

A file entry in a form.
using AngleSharp.Dom.Io; using AngleSharp.Network; using System.IO; using System.Text; namespace AngleSharp.Html { internal sealed class FileDataSetEntry : FormDataSetEntry { private readonly IFile _value; public string FileName { get { if (_value == null) return string.Empty; return _value.Name; } } public string ContentType { get { if (_value == null) return MimeTypeNames.Binary; return _value.Type; } } public FileDataSetEntry(string name, IFile value, string type) : base(name, type) { _value = value; } public override bool Contains(string boundary, Encoding encoding) { if (_value != null) { Stream body = _value.Body; } return false; } public override void Accept(IFormDataSetVisitor visitor) { visitor.File(this, FileName, ContentType, _value); } } }