Package 

Class InteractionTrackingKt

    • Method Summary

      Modifier and Type Method Description
      final static Function0<Unit> trackClick(String targetName, Map<String, Object> attributes, SdkCore sdkCore, Function0<Unit> onClick) Creates a proxy around click listener, which will report clicks to Datadog.
      final static Unit TrackInteractionEffect(String targetName, InteractionSource interactionSource, InteractionType interactionType, Map<String, Object> attributes, SdkCore sdkCore) When TrackInteractionEffect enters composition, it will start tracking interactions (swipe or scroll) emitted by the given interaction source in the composition's CoroutineContext.
      • Methods inherited from class java.lang.Object

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

      • trackClick

         final static Function0<Unit> trackClick(String targetName, Map<String, Object> attributes, SdkCore sdkCore, Function0<Unit> onClick)

        Creates a proxy around click listener, which will report clicks to Datadog.

        Parameters:
        targetName - Name of the click target.
        attributes - Additional custom attributes to attach to the action.
        sdkCore - the SDK instance to use.
        onClick - Click listener.
      • TrackInteractionEffect

         final static Unit TrackInteractionEffect(String targetName, InteractionSource interactionSource, InteractionType interactionType, Map<String, Object> attributes, SdkCore sdkCore)

        When TrackInteractionEffect enters composition, it will start tracking interactions (swipe or scroll) emitted by the given interaction source in the composition's CoroutineContext. Tracking will be cancelled once effect leaves the composition.

        For tracking clicks check trackClick.

        Parameters:
        targetName - Name of the tracking target.
        interactionSource - InteractionSource which hosts the flow of interactions happening.
        interactionType - Type of the interaction, either InteractionType.Scroll or InteractionType.Swipe
        attributes - Additional custom attributes to attach to the action.
        sdkCore - the SDK instance to use.