diff --git a/android/src/com/mapswithme/maps/news/IntroductionDialogFragment.java b/android/src/com/mapswithme/maps/news/IntroductionDialogFragment.java index 7b686f43c7..49152240b3 100644 --- a/android/src/com/mapswithme/maps/news/IntroductionDialogFragment.java +++ b/android/src/com/mapswithme/maps/news/IntroductionDialogFragment.java @@ -30,7 +30,7 @@ public class IntroductionDialogFragment extends BaseMwmDialogFragment fragment.show(fm, IntroductionDialogFragment.class.getName()); Statistics.INSTANCE.trackEvent(Statistics.EventName.ONBOARDING_DEEPLINK_SCREEN_SHOW, Statistics.params().add(Statistics.EventParam.TYPE, - factory.getStatisticalName())); + factory.toStatisticValue())); } @NonNull @@ -72,7 +72,7 @@ public class IntroductionDialogFragment extends BaseMwmDialogFragment factory.createButtonClickListener().onIntroductionButtonClick(requireActivity(), deepLink); Statistics.INSTANCE.trackEvent(Statistics.EventName.ONBOARDING_DEEPLINK_SCREEN_ACCEPT, Statistics.params().add(Statistics.EventParam.TYPE, - factory.getStatisticalName())); + factory.toStatisticValue())); dismissAllowingStateLoss(); } @@ -82,7 +82,7 @@ public class IntroductionDialogFragment extends BaseMwmDialogFragment super.onCancel(dialog); Statistics.INSTANCE.trackEvent(Statistics.EventName.ONBOARDING_DEEPLINK_SCREEN_DECLINE, Statistics.params().add(Statistics.EventParam.TYPE, - getScreenFactory().getStatisticalName())); + getScreenFactory().toStatisticValue())); } @Override diff --git a/android/src/com/mapswithme/maps/news/IntroductionScreenFactory.java b/android/src/com/mapswithme/maps/news/IntroductionScreenFactory.java index 52e0e4c653..40cf7aa289 100644 --- a/android/src/com/mapswithme/maps/news/IntroductionScreenFactory.java +++ b/android/src/com/mapswithme/maps/news/IntroductionScreenFactory.java @@ -9,15 +9,15 @@ import com.mapswithme.maps.R; import com.mapswithme.maps.bookmarks.BookmarkCategoriesActivity; import com.mapswithme.maps.bookmarks.BookmarksCatalogActivity; import com.mapswithme.maps.bookmarks.BookmarksPageFactory; -import com.mapswithme.util.statistics.StatisticalNameProvider; +import com.mapswithme.util.statistics.StatisticValueConverter; -public enum IntroductionScreenFactory implements StatisticalNameProvider +public enum IntroductionScreenFactory implements StatisticValueConverter { FREE_GUIDE { @NonNull @Override - public String getStatisticalName() + public String toStatisticValue() { return "catalogue"; } @@ -66,7 +66,7 @@ public enum IntroductionScreenFactory implements StatisticalNameProvider { @NonNull @Override - public String getStatisticalName() + public String toStatisticValue() { return "guides_page"; } diff --git a/android/src/com/mapswithme/util/statistics/StatisticalNameProvider.java b/android/src/com/mapswithme/util/statistics/StatisticValueConverter.java similarity index 55% rename from android/src/com/mapswithme/util/statistics/StatisticalNameProvider.java rename to android/src/com/mapswithme/util/statistics/StatisticValueConverter.java index 857405a88c..3d5e520b14 100644 --- a/android/src/com/mapswithme/util/statistics/StatisticalNameProvider.java +++ b/android/src/com/mapswithme/util/statistics/StatisticValueConverter.java @@ -2,8 +2,8 @@ package com.mapswithme.util.statistics; import android.support.annotation.NonNull; -public interface StatisticalNameProvider +public interface StatisticValueConverter { @NonNull - public String getStatisticalName(); + T toStatisticValue(); }