# CollectionSortItem Class

> Stores data about fields that viewers use for sorting collection items.

- Product: Adobe PDF Library 18
- Language: Java
- Version: APDFL18.0.5PlusP2a
- HTML page: https://docs.datalogics.com/apdfl18/Java/APDFL18.0.5PlusP2a/class/CollectionSortItem
- Version index: https://docs.datalogics.com/apdfl18/Java/APDFL18.0.5PlusP2a/llms.txt

```java
class CollectionSortItem
```

**Namespace:** `com::datalogics::PDFL`

## Description

Stores data about fields that viewers use for sorting collection items. Collections are aslo known as portfolios.

**Referenced by:** [`Collection`](https://docs.datalogics.com/apdfl18/Java/APDFL18.0.5PlusP2a/class/Collection.md), [`CollectionSortItemPtrVector`](https://docs.datalogics.com/apdfl18/Java/APDFL18.0.5PlusP2a/class/CollectionSortItemPtrVector.md)

## Constructors

### CollectionSortItem

```java
com.datalogics.PDFL.CollectionSortItem.CollectionSortItem(String fieldID, boolean order)
```

*constructor*

**Parameters**

- `fieldID` (`String`): the schema field's id.
- `order` (`boolean`): true for ascending, false for descending

CCollectionSortItem allows to construct sort item which will be used for collection sorting.

## Methods

### delete

```java
synchronized void com.datalogics.PDFL.CollectionSortItem.delete(Boolean disposing)
```

*protected*

**Parameters**

- `disposing` (`Boolean`)

**Returns:** `synchronized void`

### delete

```java
synchronized void com.datalogics.PDFL.CollectionSortItem.delete()
```

**Returns:** `synchronized void`

### finalize

```java
void com.datalogics.PDFL.CollectionSortItem.finalize()
```

*protected*

**Returns:** `void`

### getAscending

```java
boolean com.datalogics.PDFL.CollectionSortItem.getAscending()
```

**Returns:** `boolean`

sort order

GetAscending allows to know whether ascending order is used for sorting.

### getName

```java
String com.datalogics.PDFL.CollectionSortItem.getName()
```

**Returns:** `String`

the filed name to sort by

GetName allows to get name to sort by.
