---
title: "init(name:elements:)"
framework: coredata
role: symbol
role_heading: Initializer
path: "coredata/nsfetchindexdescription/init(name:elements:)"
---

# init(name:elements:)

Creates a fetch index description using the specified name and element descriptions.

## Declaration

```swift
init(name: String, elements: [NSFetchIndexElementDescription]?)
```

## Parameters

- `name`: The name of the fetch index description.
- `elements`: An array of fetch index element descriptions.
