HUBViewModelLoaderDelegate
@protocol HUBViewModelLoaderDelegate <NSObject>
Delegate protocol for HUBViewModelLoader
Conform to this protocol in a custom object to get notified when a view model was loaded, or if an error occured in the loading process.
-
Sent to a view model loader’s delegate when a view model was loaded
Note that this method might be called multiple times during a view model loader’s lifecycle, as it will be called whenever a view model finished loading. This might happen either as the result of calling
loadViewModel, whenever a content operation was rescheduled and completed, or whenever the current connectivity state was changed.Declaration
Objective-C
- (void)viewModelLoader:(nonnull id<HUBViewModelLoader>)viewModelLoader didLoadViewModel:(nonnull id<HUBViewModel>)viewModel;Parameters
viewModelLoaderThe view model loader that loaded a view model
viewModelThe view model that was loaded
-
Sent to a view model loader’s delegate when an error occured, causing the loader to fail
Declaration
Objective-C
- (void)viewModelLoader:(nonnull id<HUBViewModelLoader>)viewModelLoader didFailLoadingWithError:(nonnull NSError *)error;Parameters
viewModelLoaderThe view model loader that encountered the error
errorThe error that was encountered
View on GitHub
Install in Dash
HUBViewModelLoaderDelegate Protocol Reference