dartlcemodel_lce library

State for "Loading-Content-Error" resource which retrieves DATA

Classes

LceContent<DATA extends Object>
DATA is loaded data State data dataIsValid Data validity at the time of emission
LceError<DATA extends Object>
DATA load error. May contain some data if cached data State data dataIsValid Data validity at the time of emission error Error occurred
LceLoading<DATA extends Object>
DATA is loading data is the current data if any dataIsValid Data validity at the time of emission type Loading type
LceState<DATA extends Object>
State for 'Loading-Content-Error' resource which retrieves DATA
LceTerminated<DATA extends Object>
A special state that may be used to terminate state emission in cases we always need a latest state to proceed For example we have a view that subscribes to LceState for a resource identified with some PARAMS. Than a delete operation is performed on that resource and it is not available anymore. The one may emit LceTerminated to do a special processing (e.g. close the corresponding view) instead of doing it through server request that will return a Not found error and doing a special case processing afterwards. Also useful when onComplete from state-emitter can't be processed by the end-subscriber. For example LiveData does not emit completion and caches the latest emission. So converting stream to LiveData will loose Rx completion logic.

Enums

LoadingType
Loading type

Extensions

LceStateUtils on LceState<DATA_1>
LceState extensions