# HyperLinkSelection

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

*** ** * ** ***


```
public final class HyperLinkSelection implements LinkSelection
```

<br />

*** ** * ** ***

A `https://developer.android.com/reference/androidx/pdf/selection/Selection` for a hyperlink.

This represents a text range that is also a hyperlink, containing both the link and the text that is displayed.

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/androidx/pdf/selection/model/HyperLinkSelection#HyperLinkSelection(android.net.Uri,kotlin.CharSequence,kotlin.collections.List)( @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/android/net/Uri.html link, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html linkText, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/util/List.html<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/pdf/PdfRect> bounds )` |

| ### Public methods |
|---|---|
| `boolean` | `https://developer.android.com/reference/androidx/pdf/selection/model/HyperLinkSelection#equals(kotlin.Any)(https://developer.android.com/reference/java/lang/Object.html other)` |
| `@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/util/List.html<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/pdf/PdfRect>` | `https://developer.android.com/reference/androidx/pdf/selection/model/HyperLinkSelection#getBounds()()` The list of bounding boxes for the text. |
| `final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/android/net/Uri.html` | `https://developer.android.com/reference/androidx/pdf/selection/model/HyperLinkSelection#getLink()()` The URL of the hyperlink. |
| `@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html` | `https://developer.android.com/reference/androidx/pdf/selection/model/HyperLinkSelection#getLinkText()()` The text that is displayed as a hyperlink. |
| `int` | `https://developer.android.com/reference/androidx/pdf/selection/model/HyperLinkSelection#hashCode()()` |
| `@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html` | `https://developer.android.com/reference/androidx/pdf/selection/model/HyperLinkSelection#toString()()` |

## Public constructors

### HyperLinkSelection

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

```
public HyperLinkSelection(
    @NonNull Uri link,
    @NonNull CharSequence linkText,
    @NonNull List<@NonNull PdfRect> bounds
)
```

## Public methods

### equals

```
public boolean equals(Object other)
```

### getBounds

```
public @NonNull List<@NonNull PdfRect> getBounds()
```

The list of bounding boxes for the text.

### getLink

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

```
public final @NonNull Uri getLink()
```

The URL of the hyperlink.

### getLinkText

```
public @NonNull CharSequence getLinkText()
```

The text that is displayed as a hyperlink.

### hashCode

```
public int hashCode()
```

### toString

```
public @NonNull String toString()
```