All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.com.algolia.instantsearch.insights.exception.InsightsException.kt Maven / Gradle / Ivy

Go to download

InstantSearch Android is a library providing widgets and helpers to help you build the best instant-search experience on Android with Algolia. It is built on top of Algolia's Kotlin API Client to provide you a high-level solution to quickly build various search interfaces.

There is a newer version: 3.3.1
Show newest version
package com.algolia.instantsearch.insights.exception

/**
 * InstantSearch Insights exceptions.
 */
public sealed class InsightsException(override val message: String? = null) : Exception(message) {

    /**
     * Will be thrown when you try to access an index through the Insights.shared
     * method without having registered the index through the Insights.register method first.
     */
    public class IndexNotRegistered : InsightsException("You need to call Insights.register before Insights.shared")

    /**
     * Will be thrown when you call Insights.viewed without Insights.userToken first.
     */
    public class NoUserToken : InsightsException("You need to set Insights.userToken first.")
    // TODO: Remove exception once default userToken
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy