Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

android: simplify session replay configuration #119

Merged
merged 1 commit into from
Nov 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import android.content.Context
import androidx.startup.Initializer

/**
* Allows Bitdrift to be initialized with the host ApplicationContext instance
* Allows Capture SDK to be initialized with the host ApplicationContext instance
*/
class ContextHolder : Initializer<ContextHolder> {
override fun create(context: Context): ContextHolder {
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@
package io.bitdrift.capture.replay

/**
* A configuration used to configure Bitdrift session replay feature.
* @param replayMapperConfiguration Map used to matching third party Android views to Bitdrift view types.
* A configuration used to configure bitdrift session replay feature.
*
* @param categorizers Map used to matching third party Android views to bitdrift view types.
*/
data class SessionReplayConfiguration @JvmOverloads constructor(
val replayMapperConfiguration: ReplayMapperConfiguration? = null,
val categorizers: Map<ReplayType, List<String>>? = null,
)
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import io.bitdrift.capture.replay.ReplayType

internal class ViewMapperConfiguration(
private val externalMapper: Map<ReplayType, List<String>>? =
ReplayModule.replayDependencies.sessionReplayConfiguration.replayMapperConfiguration?.customMapper,
ReplayModule.replayDependencies.sessionReplayConfiguration.categorizers,
) {

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@ public struct SessionReplayConfiguration {

/// Initializes a new session replay configuration.
///
/// - parameter categorizers: A mapping that provides additional instructions on how views implemented
/// with specific class names should be represented in session replay
/// capture visualizations.
/// - parameter categorizers: Map used to match third-party views to bitdrift session replay view types.
public init(categorizers: [String: AnnotatedView] = [:]) {
self.categorizers = categorizers
}
Expand Down
Loading