public static final class TextSelection.Request
extends Object

   ↳ androidx.textclassifier.TextSelection.Request

A request object for generating TextSelection.


Nested classes

class TextSelection.Request.Builder

A builder for building TextSelection requests. 

Public methods

static TextSelection.Request createFromBundle(Bundle bundle)

Extracts a Request from a bundle that was added using toBundle().

LocaleListCompat getDefaultLocales()
int getEndIndex()

Returns end index of the selected part of text.

Bundle getExtras()

Returns the extended, vendor specific data.

int getStartIndex()

Returns start index of the selected part of text.

CharSequence getText()

Returns the text providing context for the selected text (which is specified by the sub sequence starting at startIndex and ending at endIndex).

Bundle toBundle()

Adds this Request to a Bundle that can be read back with the same parameters to createFromBundle(Bundle).

Inherited methods