# PdfWriteHandle

Artifact: [androidx.pdf:pdf-core](https://developer.android.com/jetpack/androidx/releases/pdf) [View Source](https://cs.android.com/search?q=file:androidx/pdf/PdfWriteHandle.kt+class:androidx.pdf.PdfWriteHandle) Added in [1.0.0-beta01](https://developer.android.com/jetpack/androidx/releases/pdf#1.0.0-beta01)

*** ** * ** ***


```
interface PdfWriteHandle : Closeable
```

<br />

*** ** * ** ***

Represents a handle for writing the contents of a PDF to a destination.

## Summary

| ### Public functions |
|---|---|
| `suspend https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/pdf/PdfWriteHandle#writeTo(android.os.ParcelFileDescriptor)(destination: https://developer.android.com/reference/android/os/ParcelFileDescriptor.html)` Writes the contents of the PDF to `https://developer.android.com/reference/kotlin/androidx/pdf/PdfWriteHandle#writeTo(android.os.ParcelFileDescriptor)`. |

### Inherited functions

From [java.io.Closeable](https://developer.android.com/reference/java/io/Closeable.html) `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` `https://developer.android.com/reference/java/io/Closeable.html#close()()`

## Public functions

### writeTo

Added in [1.0.0-beta01](https://developer.android.com/jetpack/androidx/releases/pdf#1.0.0-beta01)

```
suspend fun writeTo(destination: ParcelFileDescriptor): Unit
```

Writes the contents of the PDF to `https://developer.android.com/reference/kotlin/androidx/pdf/PdfWriteHandle#writeTo(android.os.ParcelFileDescriptor)`.

| Parameters |
|---|---|
| `destination: https://developer.android.com/reference/android/os/ParcelFileDescriptor.html` | The `https://developer.android.com/reference/android/os/ParcelFileDescriptor.html` to write to. The caller is responsible for closing `https://developer.android.com/reference/kotlin/androidx/pdf/PdfWriteHandle#writeTo(android.os.ParcelFileDescriptor)`. |