Package 

Class Interceptor.Builder

    • Method Summary

      Modifier and Type Method Description
      final Unit onCheck(Boolean isOverride, Function2<INTERACTION, ASSERTION, Unit> interceptor) Sets the interceptor for the check operation for a given interaction.
      final Unit onPerform(Boolean isOverride, Function2<INTERACTION, ACTION, Unit> interceptor) Sets the interceptor for the perform operation for a given interaction.
      final Unit onAll(Boolean isOverride, Function1<INTERACTION, Unit> interceptor) Sets the interceptor for the check and perform operations for a given interaction.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Interceptor.Builder

        Interceptor.Builder()
    • Method Detail

      • onCheck

         final Unit onCheck(Boolean isOverride, Function2<INTERACTION, ASSERTION, Unit> interceptor)

        Sets the interceptor for the check operation for a given interaction. If overridden, breaks the call chain of operation and transfers the responsibility to invoke the Espresso on the developer.

        Parameters:
        isOverride - if true - breaks the call chain, false otherwise
        interceptor - lambda with intercepting logic
      • onPerform

         final Unit onPerform(Boolean isOverride, Function2<INTERACTION, ACTION, Unit> interceptor)

        Sets the interceptor for the perform operation for a given interaction. If overridden, breaks the call chain of operation and transfers the responsibility to invoke the Espresso on the developer.

        Parameters:
        isOverride - if true - breaks the call chain, false otherwise
        interceptor - lambda with intercepting logic
      • onAll

         final Unit onAll(Boolean isOverride, Function1<INTERACTION, Unit> interceptor)

        Sets the interceptor for the check and perform operations for a given interaction. If overridden, breaks the call chain of operation and transfers the responsibility to invoke the Espresso on the developer.

        This interceptor is prioritized and is being invoked first for both operations.

        Parameters:
        isOverride - if true - breaks the call chain, false otherwise
        interceptor - lambda with intercepting logic