# Collection Class

> Allows for manipulation of PDF collections, or portfolios.

- Product: Adobe PDF Library 21
- Language: .NET Framework
- Version: APDFL21.0.0PlusP1e
- HTML page: https://docs.datalogics.com/apdfl21/DotNetFramework/APDFL21.0.0PlusP1e/class/Collection
- Version index: https://docs.datalogics.com/apdfl21/DotNetFramework/APDFL21.0.0PlusP1e/llms.txt

```csharp
class Collection : SystemIDisposable
```

**Namespace:** `Datalogics::PDFL`

**Inherits from:** `SystemIDisposable`

## Description

Allows for manipulation of PDF collections, or portfolios.

The class illustrates how to process a collection's schema. It also describes sorting of a portfolio.

**Referenced by:** [`Document`](https://docs.datalogics.com/apdfl21/DotNetFramework/APDFL21.0.0PlusP1e/class/Document.md)

**Uses types:** [`CollectionSchema`](https://docs.datalogics.com/apdfl21/DotNetFramework/APDFL21.0.0PlusP1e/class/CollectionSchema.md), [`CollectionSortItem`](https://docs.datalogics.com/apdfl21/DotNetFramework/APDFL21.0.0PlusP1e/class/CollectionSortItem.md), [`CollectionSplitType`](https://docs.datalogics.com/apdfl21/DotNetFramework/APDFL21.0.0PlusP1e/enum/CollectionSplitType.md), [`CollectionViewType`](https://docs.datalogics.com/apdfl21/DotNetFramework/APDFL21.0.0PlusP1e/enum/CollectionViewType.md)

## Properties

### Schema

```csharp
CollectionSchema Datalogics.PDFL.Collection.Schema { get; }
```

GetSchema allows to obtain Schema object for current Collection.

The Schema object does not have constructor. Only Collection is able to create Schema.

### Sort

```csharp
System.Collections.Generic.IList<CollectionSortItem> Datalogics.PDFL.Collection.Sort { get; set; }
```

GetSort gets sort parameters for the Collection.

## Methods

### ChangeCollectionViewMode

```csharp
void Datalogics.PDFL.Collection.ChangeCollectionViewMode(CollectionViewType view, CollectionSplitType split)
```

**Parameters**

- `view` ([`CollectionViewType`](https://docs.datalogics.com/apdfl21/DotNetFramework/APDFL21.0.0PlusP1e/enum/CollectionViewType.md)): one of the members of CollectionViewMode enum.
- `split` ([`CollectionSplitType`](https://docs.datalogics.com/apdfl21/DotNetFramework/APDFL21.0.0PlusP1e/enum/CollectionSplitType.md)): enum of split mode (selector)

**Returns:** `void`

SetCollectionView sets view mode value to the Collection.

### Dispose

```csharp
void Datalogics.PDFL.Collection.Dispose()
```

**Returns:** `void`
