Back to Exoplayer

FlagSet (ExoPlayer library)

docs/doc/reference/com/google/android/exoplayer2/util/FlagSet.html

latest3.4 KB
Original Source

Package com.google.android.exoplayer2.util

Class FlagSet


[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")public final classFlagSetextends[Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")

Deprecated. com.google.android.exoplayer2 is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.

A set of integer flags.

Intended for usages where the number of flags may exceed 32 and can no longer be represented by an IntDef.

Instances are immutable.

Nested Class Summary

Nested Classes | Modifier and Type | Class | Description | | --- | --- | --- | | static class | FlagSet.Builder | Deprecated.

A builder for FlagSet instances. |

Method Summary

All Methods Instance Methods Concrete Methods Deprecated Methods | Modifier and Type | Method | Description | | --- | --- | --- | | boolean | contains​(int flag) | Deprecated.

Returns whether the set contains the given flag. | | boolean | containsAny​(int... flags) | Deprecated.

Returns whether the set contains at least one of the given flags. | | boolean | equals​(Object o) | Deprecated. | | int | get​(int index) | Deprecated.

Returns the flag at the given index. | | int | hashCode() | Deprecated. | | int | size() | Deprecated.

Returns the number of flags in this set. |

- 

Methods inherited from class java.lang.Object

clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait

Method Detail

- 

contains

public boolean contains​(int flag)

Deprecated.

Returns whether the set contains the given flag. Parameters:flag - The flag.Returns:Whether the set contains the flag.

- 

containsAny

public boolean containsAny​(int... flags)

Deprecated.

Returns whether the set contains at least one of the given flags. Parameters:flags - The flags.Returns:Whether the set contains at least one of the flags.

- 

size

public int size()

Deprecated.

Returns the number of flags in this set.

- 

get

public int get​(int index)

Deprecated.

Returns the flag at the given index. Parameters:index - The index. Must be between 0 (inclusive) and size() (exclusive).Returns:The flag at the given index.Throws:IndexOutOfBoundsException - If index is outside the allowed range.

- 

equals

public boolean equals​(@Nullable[Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")o)

Deprecated. Overrides:equals in class Object

- 

hashCode

public int hashCode()

Deprecated. Overrides:hashCode in class Object