Java 类com.google.android.gms.analytics.HitBuilders.ScreenViewBuilder 实例源码

项目:vuze-remote-for-android    文件:VuzeEasyTrackerNew.java   
public void activityStart(Activity activity) {

        try {
            mTracker.setScreenName(activity.getClass().getSimpleName());
            ScreenViewBuilder builder = new ScreenViewBuilder();
            builder.set(SCREEN_NAME, activity.getClass().getSimpleName());
            Intent intent = activity.getIntent();
            if (intent != null) {
                Uri data = intent.getData();
                if (data != null) {
                    builder.setAll(getReferrerMapFromUri(data));
                }
            }
            mTracker.send(builder.build());
        } catch (Throwable t) {
            if (AndroidUtils.DEBUG) {
                Log.e(TAG, "activityStart", t);
            }
        }

    }
项目:vuze-remote-for-android    文件:VuzeEasyTrackerNew.java   
public void fragmentStart(@Nullable Fragment fragment, String name) {
    try {
        mTracker.setScreenName(name);
        ScreenViewBuilder builder = new ScreenViewBuilder();
        builder.set(SCREEN_NAME, name);
        mTracker.send(builder.build());
    } catch (Throwable t) {
        if (AndroidUtils.DEBUG) {
            Log.e(TAG, "fragmentStart", t);
        }
    }
}
项目:barterli_android    文件:GoogleAnalyticsManager.java   
/**
 * Inform a screen hit to Google Analytics
 *
 * @param screenName A name for the screen
 */
public void sendScreenHit(String screenName) {

    mApplicationTracker.setScreenName(screenName);
    final ScreenViewBuilder screenViewBuilder = new ScreenViewBuilder();
    screenViewBuilder.set(ParamKeys.LOGGED_IN, TextUtils
            .isEmpty(UserInfo.INSTANCE.getId()) ? ParamValues.NO
            : ParamValues.YES);
    mApplicationTracker.send(screenViewBuilder.build());
}
项目:GithubTrends    文件:AnalyticsHelper.java   
public static void sendView(final String pScreenName) {
    AnalyticsHelper.sTracker.setScreenName(pScreenName);
    AnalyticsHelper.sTracker.send(new ScreenViewBuilder().build());
    AnalyticsHelper.sTracker.setScreenName(null);
}
项目:Augendiagnose    文件:TrackingUtil.java   
/**
 * Send a screen opening event.
 *
 * @param object The activity or fragment showing the screen.
 */
public static void sendScreen(final Object object) {
    getDefaultTracker();
    mTracker.setScreenName(object.getClass().getSimpleName());
    mTracker.send(new ScreenViewBuilder().build());
}
项目:Augendiagnose    文件:TrackingUtil.java   
/**
 * Start a new session.
 */
public static void startSession() {
    mTracker.send(new ScreenViewBuilder().setNewSession().build());
}