autodispose-lifecycle / com.uber.autodispose.lifecycle / CorrespondingEventsFunction

CorrespondingEventsFunction

interface CorrespondingEventsFunction<E : Any> : Function<E, E>

A corresponding events function that acts as a normal Function but ensures a single event type in the generic and tightens the possible exception thrown to OutsideScopeException.

Parameters

- the event type.

Functions

apply

abstract fun apply(event: E): E

Given an event event, returns the next corresponding event that this lifecycle should dispose on.