Interface SNResultsObserving


  • public interface SNResultsObserving
    The interface through which clients receive the results of an analysis request API-Since: 13.0
    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      default void requestDidComplete​(@NotNull SNRequest request)
      Informs the client that the analysis request was completed normally If an analysis request completes normally, that request will not produce any more results, and is in a terminal state.
      default void requestDidFailWithError​(@NotNull SNRequest request, @NotNull NSError error)
      Informs the client of an error produced during analysis If an error is produced by a request, that request will not produce any more results, and is in a terminal state.
      void requestDidProduceResult​(@NotNull SNRequest request, @NotNull SNResult result)
      Provides a new analysis result to the client with the specified time range This function will be called each time a new analysis result is available.
    • Method Detail

      • requestDidFailWithError

        default void requestDidFailWithError​(@NotNull
                                             @NotNull SNRequest request,
                                             @NotNull
                                             @NotNull NSError error)
        Informs the client of an error produced during analysis If an error is produced by a request, that request will not produce any more results, and is in a terminal state. The request:didFailWithError and requestDidComplete methods are mutually exclusive.
      • requestDidProduceResult

        void requestDidProduceResult​(@NotNull
                                     @NotNull SNRequest request,
                                     @NotNull
                                     @NotNull SNResult result)
        Provides a new analysis result to the client with the specified time range This function will be called each time a new analysis result is available. Different types of analysis may produce results at different rates, spanning different time ranges.
      • requestDidComplete

        default void requestDidComplete​(@NotNull
                                        @NotNull SNRequest request)
        Informs the client that the analysis request was completed normally If an analysis request completes normally, that request will not produce any more results, and is in a terminal state. The request:didFailWithError and requestDidComplete methods are mutually exclusive.