本文整理汇总了Java中com.crashlytics.android.answers.SignUpEvent类的典型用法代码示例。如果您正苦于以下问题:Java SignUpEvent类的具体用法?Java SignUpEvent怎么用?Java SignUpEvent使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
SignUpEvent类属于com.crashlytics.android.answers包,在下文中一共展示了SignUpEvent类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: eventLogin
import com.crashlytics.android.answers.SignUpEvent; //导入依赖的package包/类
public static void eventLogin(Context context,boolean success){
//Fabric
Answers.getInstance().logSignUp(new SignUpEvent()
.putMethod("Normal")
.putSuccess(success));
//Firebase
Bundle params = new Bundle();
params.putBoolean("Success",success);
FirebaseAnalytics.getInstance(context).logEvent(AnalyticsConstants.EVENT_LOGIN,params);
//Amplitude
try {
Amplitude.getInstance().logEvent(AnalyticsConstants.EVENT_LOGIN,new JSONObject().put("Success",success));
} catch (JSONException e) {
Crashlytics.logException(e);
}
}
开发者ID:Bruno125,项目名称:Unofficial-Ups,代码行数:20,代码来源:AnalyticsManager.java
示例2: sendUserProperties
import com.crashlytics.android.answers.SignUpEvent; //导入依赖的package包/类
@Override
public void sendUserProperties(String name, String value) {
switch (name) {
case AnalyticConstant.USER_EMAIL:
Crashlytics.setUserEmail(value);
break;
case AnalyticConstant.USER_NAME:
Crashlytics.setUserName(value);
break;
case AnalyticConstant.USER_SIGN_IN:
Answers.getInstance().logLogin(new LoginEvent().putMethod(value).putSuccess(true));
break;
case AnalyticConstant.USER_SIGN_UP:
Answers.getInstance().logSignUp(new SignUpEvent().putMethod(value).putSuccess(true));
break;
default:
Answers.getInstance().logCustom(new CustomEvent("Custom_Event").putCustomAttribute(name, value));
break;
}
}
开发者ID:afiqiqmal,项目名称:My-Android-Base-Code,代码行数:22,代码来源:CrashLyticManager.java
示例3: test_buildAnswersSignUpEvent
import com.crashlytics.android.answers.SignUpEvent; //导入依赖的package包/类
@Test
public void test_buildAnswersSignUpEvent()
{
SignUpEvent result = logger.buildAnswersSignUpEvent(signupEvent);
Map<String, Object> predefinedAttributes = PackageScopeWrappedCalls.getPredefinedAttributes(result);
assertThat(predefinedAttributes.size()).isEqualTo(2);
assertThat(predefinedAttributes).containsKey(Attributes.SignUp.METHOD);
assertThat(predefinedAttributes).containsKey(Attributes.SignUp.SUCCESS);
Map<String, Object> customAttributes = PackageScopeWrappedCalls.getCustomAttributes(result);
assertThat(customAttributes.size()).isEqualTo(1);
assertThat(customAttributes).containsKey(CUSTOM_KEY);
}
开发者ID:busybusy,项目名称:AnalyticsKit-Android,代码行数:17,代码来源:SignUpLoggerTest.java
示例4: logSpecificEvent
import com.crashlytics.android.answers.SignUpEvent; //导入依赖的package包/类
@Override
public void logSpecificEvent(@NonNull AnalyticsEvent event)
{
SignUpEvent SignUpEvent = buildAnswersSignUpEvent(event);
answers.logSignUp(SignUpEvent);
}
开发者ID:busybusy,项目名称:AnalyticsKit-Android,代码行数:8,代码来源:SignUpLogger.java
示例5: sendSignUp
import com.crashlytics.android.answers.SignUpEvent; //导入依赖的package包/类
public void sendSignUp(final JSONArray data, final CallbackContext context) {
this.cordova.getActivity().runOnUiThread(new Runnable() {
@Override
public void run() {
SignUpEvent evt = new SignUpEvent();
Answers.getInstance()
.logSignUp(evt);
}
});
}
开发者ID:napolitano,项目名称:cordova-plugin-answers,代码行数:11,代码来源:AnswersPlugin.java
示例6: logSignUp
import com.crashlytics.android.answers.SignUpEvent; //导入依赖的package包/类
public static void logSignUp(String method) {
if (!BuildConfig.DEBUG && sEnabled)
Answers.getInstance().logSignUp(new SignUpEvent()
.putMethod(method)
.putSuccess(true));
}
开发者ID:kontalk,项目名称:androidclient,代码行数:7,代码来源:ReportingManager.java
注:本文中的com.crashlytics.android.answers.SignUpEvent类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论