# OrderedScatterSetKt

Added in 1.5.0

*** ** * ** ***


```
public final class OrderedScatterSetKt
```

<br />

*** ** * ** ***

## Summary

| ### Public methods |
|---|---|
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#emptyOrderedScatterSet()()` Returns an empty, read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet`. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#mutableOrderedScatterSetOf()()` Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet`. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#mutableOrderedScatterSetOf(kotlin.Any)(@https://developer.android.com/reference/androidx/annotation/NonNull E element1)` Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any)` in it. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#mutableOrderedScatterSetOf(kotlin.Array)(@https://developer.android.com/reference/androidx/annotation/NonNull E... elements)` Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with the specified contents. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any)( @https://developer.android.com/reference/androidx/annotation/NonNull E element1, @https://developer.android.com/reference/androidx/annotation/NonNull E element2 )` Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any)` and `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any)` in it. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)( @https://developer.android.com/reference/androidx/annotation/NonNull E element1, @https://developer.android.com/reference/androidx/annotation/NonNull E element2, @https://developer.android.com/reference/androidx/annotation/NonNull E element3 )` Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)`, `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)`, and `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)` in it. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#orderedScatterSetOf()()` Returns an empty, read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet`. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#orderedScatterSetOf(kotlin.Any)(@https://developer.android.com/reference/androidx/annotation/NonNull E element1)` Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any)` in it. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#orderedScatterSetOf(kotlin.Array)(@https://developer.android.com/reference/androidx/annotation/NonNull E... elements)` Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Array)` in it. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#orderedScatterSetOf(kotlin.Any,kotlin.Any)(@https://developer.android.com/reference/androidx/annotation/NonNull E element1, @https://developer.android.com/reference/androidx/annotation/NonNull E element2)` Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any)` and `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any)` in it. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#orderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)( @https://developer.android.com/reference/androidx/annotation/NonNull E element1, @https://developer.android.com/reference/androidx/annotation/NonNull E element2, @https://developer.android.com/reference/androidx/annotation/NonNull E element3 )` Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)`, `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)`, and `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)` in it. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#(kotlin.collections.Collection).toMutableOrderedScatterSet()( @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/util/Collection.html<@https://developer.android.com/reference/androidx/annotation/NonNull E> receiver )` Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with the specified contents. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#(androidx.collection.OrderedScatterSet).toMutableOrderedScatterSet()( @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E> receiver )` Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with the specified contents. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#(kotlin.collections.Collection).toOrderedScatterSet()(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/util/Collection.html<@https://developer.android.com/reference/androidx/annotation/NonNull E> receiver)` Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with the specified contents. |
| `static final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E>` | `<E extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/OrderedScatterSetKt#(androidx.collection.OrderedScatterSet).toOrderedScatterSet()( @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/OrderedScatterSet<@https://developer.android.com/reference/androidx/annotation/NonNull E> receiver )` Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with the specified contents. |

## Public methods

### emptyOrderedScatterSet

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:emptyOrderedScatterSet) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull OrderedScatterSet<@NonNull E> <E extends Object> emptyOrderedScatterSet()
```

Returns an empty, read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet`.

### mutableOrderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:mutableOrderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull MutableOrderedScatterSet<@NonNull E> <E extends Object> mutableOrderedScatterSetOf()
```

Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet`.

### mutableOrderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:mutableOrderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull MutableOrderedScatterSet<@NonNull E> <E extends Object> mutableOrderedScatterSetOf(@NonNull E element1)
```

Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any)` in it.

### mutableOrderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:mutableOrderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull MutableOrderedScatterSet<@NonNull E> <E extends Object> mutableOrderedScatterSetOf(@NonNull E... elements)
```

Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with the specified contents.

### mutableOrderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:mutableOrderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull MutableOrderedScatterSet<@NonNull E> <E extends Object> mutableOrderedScatterSetOf(
    @NonNull E element1,
    @NonNull E element2
)
```

Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any)` and `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any)` in it.

### mutableOrderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:mutableOrderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull MutableOrderedScatterSet<@NonNull E> <E extends Object> mutableOrderedScatterSetOf(
    @NonNull E element1,
    @NonNull E element2,
    @NonNull E element3
)
```

Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)`, `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)`, and `https://developer.android.com/reference/androidx/collection/package-summary#mutableOrderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)` in it.

### orderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:orderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull OrderedScatterSet<@NonNull E> <E extends Object> orderedScatterSetOf()
```

Returns an empty, read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet`.

### orderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:orderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull OrderedScatterSet<@NonNull E> <E extends Object> orderedScatterSetOf(@NonNull E element1)
```

Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any)` in it.

### orderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:orderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull OrderedScatterSet<@NonNull E> <E extends Object> orderedScatterSetOf(@NonNull E... elements)
```

Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Array)` in it.

### orderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:orderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull OrderedScatterSet<@NonNull E> <E extends Object> orderedScatterSetOf(@NonNull E element1, @NonNull E element2)
```

Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any)` and `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any)` in it.

### orderedScatterSetOf

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:orderedScatterSetOf) Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/collection#1.5.0)

```
public static final @NonNull OrderedScatterSet<@NonNull E> <E extends Object> orderedScatterSetOf(
    @NonNull E element1,
    @NonNull E element2,
    @NonNull E element3
)
```

Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with only `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)`, `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)`, and `https://developer.android.com/reference/androidx/collection/package-summary#orderedScatterSetOf(kotlin.Any,kotlin.Any,kotlin.Any)` in it.

### toMutableOrderedScatterSet

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:toMutableOrderedScatterSet)

```
public static final @NonNull MutableOrderedScatterSet<@NonNull E> <E extends Object> toMutableOrderedScatterSet(
    @NonNull Collection<@NonNull E> receiver
)
```

Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with the specified contents.

The `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` is created with an initial capacity sufficient to hold the content in the specified `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-collection/index.html`.

### toMutableOrderedScatterSet

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:toMutableOrderedScatterSet) Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/collection#1.7.0)

```
public static final @NonNull MutableOrderedScatterSet<@NonNull E> <E extends Object> toMutableOrderedScatterSet(
    @NonNull OrderedScatterSet<@NonNull E> receiver
)
```

Returns a new `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` with the specified contents.

The `https://developer.android.com/reference/androidx/collection/MutableOrderedScatterSet` is created with an initial capacity sufficient to hold the content in the specified `https://developer.android.com/reference/androidx/collection/OrderedScatterSet`.

### toOrderedScatterSet

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:toOrderedScatterSet)

```
public static final @NonNull OrderedScatterSet<@NonNull E> <E extends Object> toOrderedScatterSet(@NonNull Collection<@NonNull E> receiver)
```

Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with the specified contents.

### toOrderedScatterSet

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/OrderedScatterSet.kt+function:toOrderedScatterSet) Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/collection#1.7.0)

```
public static final @NonNull OrderedScatterSet<@NonNull E> <E extends Object> toOrderedScatterSet(
    @NonNull OrderedScatterSet<@NonNull E> receiver
)
```

Returns a new read-only `https://developer.android.com/reference/androidx/collection/OrderedScatterSet` with the specified contents.