RetryPolicy
abstract class RetryPolicy
kotlin.Any | |
↳ | androidx.emoji.text.FontRequestEmojiCompatConfig.RetryPolicy |
Retry policy used when the font provider is not ready to give the font file. To control the thread the retries are handled on, see FontRequestEmojiCompatConfig#setHandler
.
Summary
Public constructors | |
---|---|
<init>() Retry policy used when the font provider is not ready to give the font file. |
Public methods | |
---|---|
abstract Long |
Called each time the metadata loading fails. |
Public constructors
<init>
RetryPolicy()
Retry policy used when the font provider is not ready to give the font file. To control the thread the retries are handled on, see FontRequestEmojiCompatConfig#setHandler
.
Public methods
getRetryDelay
abstract fun getRetryDelay(): Long
Called each time the metadata loading fails. This is primarily due to a pending download of the font. If a value larger than zero is returned, metadata loader will retry after the given milliseconds.
If zero
is returned, metadata loader will retry immediately.
If a value less than 0 is returned, the metadata loader will stop retrying and EmojiCompat will get into EmojiCompat#LOAD_STATE_FAILED
state.
Return | |
---|---|
Long |
long milliseconds to wait until next retry |