TAGContainerCallback Protocol Reference

  • The TAGContainerCallback protocol allows clients to receive information about the status of container loading, including success or failure.

  • The protocol defines three key methods: containerRefreshBegin:refreshType:, containerRefreshSuccess:refreshType:, and containerRefreshFailure:failure:refreshType:.

  • containerRefreshBegin:refreshType: is always called before the corresponding success or failure callbacks, signaling the start of a refresh operation.

  • While a kTAGContainerCallbackRefreshTypeSaved refresh may occur before a kTAGContainerCallbackRefreshTypeNetwork refresh, there are no other guarantees about the order of refresh events.

  • Two refreshes, both kTAGContainerCallbackRefreshTypeSaved and kTAGContainerCallbackRefreshTypeNetwork, can be outstanding concurrently.

TAGContainerCallback Protocol Reference

Overview

A protocol that a client may implement to receive information when the contents of the container has been successfully loaded or failed to load.

You may rely on the fact that containerRefreshBegin:refreshType: (TAGContainerCallback-p) will be called for a given TAGContainerCallbackRefreshType before its associated containerRefreshSuccess:refreshType: (TAGContainerCallback-p) or containerRefreshFailure:failure:refreshType: (TAGContainerCallback-p), but shouldn't make any other assumptions about ordering. In particular, there may be two refreshes outstanding at once (both kTAGContainerCallbackRefreshTypeSaved and kTAGContainerCallbackRefreshTypeNetwork), or a kTAGContainerCallbackRefreshTypeSaved refresh may occur before a kTAGContainerCallbackRefreshTypeNetwork refresh.

Public Member Functions

(void) - containerRefreshBegin:refreshType:
 Called before the refresh is about to begin.
(void) - containerRefreshSuccess:refreshType:
 Called when a refresh has successfully completed for the given refresh type.
(void) - containerRefreshFailure:failure:refreshType:
 Called when a refresh has failed to complete for the given refresh type.

Member Function Documentation

- (void) containerRefreshBegin: (TAGContainer *)  container
refreshType: (TAGContainerCallbackRefreshType refreshType 

Called before the refresh is about to begin.

Parameters:
containerThe container being refreshed.
refreshTypeThe type of refresh which is starting.
- (void) containerRefreshSuccess: (TAGContainer *)  container
refreshType: (TAGContainerCallbackRefreshType refreshType 

Called when a refresh has successfully completed for the given refresh type.

Parameters:
containerThe container being refreshed.
refreshTypeThe type of refresh which completed successfully.
- (void) containerRefreshFailure: (TAGContainer *)  container
failure: (TAGContainerCallbackRefreshFailure failure
refreshType: (TAGContainerCallbackRefreshType refreshType 

Called when a refresh has failed to complete for the given refresh type.

Parameters:
containerThe container being refreshed.
failureThe reason for the refresh failure.
refreshTypeThe type of refresh which failed.