Skip to content

Overview

The CTXBaseGuideController class is the backbone of GuideBlocks and needs to be subclassed by your component in order to be used by the Contextual SDK.

Overridable Methods

There are two overridable methods which must be implemented:

Method Description
presentGuideBlock This method is invoked by the Contextual SDK once a guide has satisified its trigger conditions and should be shown to the user. Details of the parameters of this method can be found below: PresentGuideBlock
isDismissingGuide This method is invoked by the Contextual SDK once a guide is being dismissed, either by a user or by the SDK itself, and as such you should ensure the guide is removed from the view hierarchy

Convenience Methods

There are a few convenience methods provided by the base class so that you can easily dismiss a guide, proceed to the next step of the guide, go back to the previous step of the guide (if any) and tap inside of or tap outside of the guide (the consequences of which are configured on the Contextual Dashboard on a per guide basis)

Method Description
dismissGuide Informs the Contextual SDK that the guide should be dismissed
previousStepOfGuide Informs the Contextual SDK that it should go back to the previous step of the guide
nextStepOfGuide Informs the Contextual SDK that it should go to the next step of the guide
tapInsideOfGuide Informs the Contextual SDK that the guide has been tapped inside and it should perform whatever was configured on the "Tap inside" section of the Dashboard for this guide
tapOutsideOfGuide Informs the Contextual SDK that the guide has been tapped outside of the guide container and it should perform whatever was configured on the "Tap outside" section of the Dashboard for this guide

Last update: 2024-01-30