Google is committed to advancing racial equity for Black communities. See how.

ClipboardManager

interface ClipboardManager
androidx.ui.core.clipboard.ClipboardManager

Interface for managing the Clipboard.

Summary

Public methods
abstract AnnotatedString?

This method get the text from the Clipboard.

abstract Unit
setText(annotatedString: AnnotatedString)

This method put the text into the Clipboard.

Public methods

getText

abstract fun getText(): AnnotatedString?

This method get the text from the Clipboard.

Return
The text in the Clipboard. It could be null due to 2 reasons: 1. Clipboard is empty; 2. Cannot convert the CharSequence text in Clipboard to AnnotatedString.

setText

abstract fun setText(annotatedString: AnnotatedString): Unit

This method put the text into the Clipboard.

Parameters
annotatedString: AnnotatedString The AnnotatedString to be put into Clipboard.