//workflow/com.squareup.workflow1.ui.backstack/ViewStateCache/update
update¶
[androidJvm]
Content
fun update(retainedRenderings: Collection<Named<*>>, oldViewMaybe: View?, newView: View)
More info
Return¶
true if newView has been restored.
Parameters¶
androidJvm
retainedRenderings | the renderings to be considered hidden after this update. Any associated view state will be retained in the cache, possibly to be restored to newView on a succeeding call to his method. Any other cached view state will be dropped. |
oldViewMaybe | the view that is being removed, if any, which is expected to be showing a Named rendering. If that rendering is compatible with a member of retainedRenderings, its state will be saved. |
newView | the view that is about to be displayed, which must be showing a Named rendering. If compatible view state is found in the cache, it is restored. |