• DR-IT Software
  • Products
  • Documentation
  • Product page
  • Examples
  • API reference
  • Support
Show / Hide Table of Contents

Class PortfolioFolderCollection

Folder entries at a portfolio root or nested folder scope.

Inheritance
object
PortfolioFolderCollection
Implements
IEnumerable<PortfolioFolder>
IEnumerable
Inherited Members
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
object.GetType()
Namespace: DRIT.Pdf.EmbeddedFiles
Assembly: DRIT.Pdf.dll
Syntax
public sealed class PortfolioFolderCollection : IEnumerable<PortfolioFolder>, IEnumerable

Properties

Count

Gets the number of folders in this collection.

Declaration
public int Count { get; }
Property Value
Type Description
int

this[int]

Gets the folder at the specified index.

Declaration
public PortfolioFolder this[int index] { get; }
Parameters
Type Name Description
int index

The zero-based index.

Property Value
Type Description
PortfolioFolder

Methods

Add(string, bool)

Adds a folder and all its files from disk.

Declaration
public PortfolioFolder Add(string folderPath, bool recursive = false)
Parameters
Type Name Description
string folderPath

The path to the folder to add.

bool recursive

Whether to include subfolders. Default is false.

Returns
Type Description
PortfolioFolder

The created folder entry.

Exceptions
Type Condition
ArgumentNullException

Thrown when folderPath is null.

DirectoryNotFoundException

Thrown when the folder does not exist.

AddEmpty(string)

Adds an empty folder with the specified name.

Declaration
public PortfolioFolder AddEmpty(string name)
Parameters
Type Name Description
string name

The folder name.

Returns
Type Description
PortfolioFolder

The created folder entry.

Exceptions
Type Condition
ArgumentException

Thrown when name is null or empty.

GetEnumerator()

Returns an enumerator for iterating over folders.

Declaration
public IEnumerator<PortfolioFolder> GetEnumerator()
Returns
Type Description
IEnumerator<PortfolioFolder>

Implements

IEnumerable<T>
IEnumerable
Back to top

DR-IT Software documentation

DR-IT Software · Products · Documentation index · Product page · Downloads · Support · Licensing

Generated by DocFX