public class CrashlyticsCore
extends io.fabric.sdk.android.Kit<Void>
| Modifier and Type | Class and Description |
|---|---|
static class |
CrashlyticsCore.Builder
Fluent API for creating
CrashlyticsCore instances. |
| Modifier and Type | Field and Description |
|---|---|
static String |
TAG |
| Constructor and Description |
|---|
CrashlyticsCore() |
| Modifier and Type | Method and Description |
|---|---|
void |
crash()
The easiest way to cause a crash - great for testing!
|
protected Void |
doInBackground() |
String |
getIdentifier() |
static CrashlyticsCore |
getInstance() |
PinningInfoProvider |
getPinningInfoProvider() |
String |
getVersion() |
void |
log(int priority,
String tag,
String msg)
Add text logging that will be sent with your next report, using
log(String). |
void |
log(String msg)
Add text logging that will be sent with your next report.
|
void |
logException(Throwable throwable)
Logs a non-fatal Throwable on the Crashlytics servers.
|
protected boolean |
onPreExecute() |
void |
setBool(String key,
boolean value)
Sets a value to be associated with a given key for your crash data.
|
void |
setDouble(String key,
double value)
Sets a value to be associated with a given key for your crash data.
|
void |
setFloat(String key,
float value)
Sets a value to be associated with a given key for your crash data.
|
void |
setInt(String key,
int value)
Sets a value to be associated with a given key for your crash data.
|
void |
setListener(CrashlyticsListener listener)
Deprecated.
|
void |
setLong(String key,
long value)
Sets a value to be associated with a given key for your crash data.
|
void |
setString(String key,
String value)
Set a value to be associated with a given key for your crash data.
|
void |
setUserEmail(String email)
Optionally set a end-user's name or username for display within the Crashlytics UI.
|
void |
setUserIdentifier(String identifier)
Many of our customers have requested the ability to tie crashes to specific end-users of their
application in order to facilitate responses to support requests or permit the ability to reach out for
more information.
|
void |
setUserName(String name)
Optionally set a end-user's name or username for display within the Crashlytics UI.
|
boolean |
verifyPinning(URL url)
Helper method to verify SSL pinning is properly configured.
|
public static final String TAG
protected boolean onPreExecute()
onPreExecute in class io.fabric.sdk.android.Kit<Void>protected Void doInBackground()
doInBackground in class io.fabric.sdk.android.Kit<Void>public String getIdentifier()
getIdentifier in class io.fabric.sdk.android.Kit<Void>public String getVersion()
getVersion in class io.fabric.sdk.android.Kit<Void>public static CrashlyticsCore getInstance()
public PinningInfoProvider getPinningInfoProvider()
public void logException(Throwable throwable)
public void log(String msg)
logException(Throwable)public void log(int priority,
String tag,
String msg)
log(String). The
message will also be printed to LogCat using android.util.Log.println(priority, tag, msg).priority - The priority/type constant of this log message, as defined in android.util.Log. One of:
ERROR, WARN, INFO, DEBUG, VERBOSE.tag - Used to identify the source of a log message. It usually identifies the class or activity
where the log call occurs.msg - The message you would like logged.log(String),
Log.println(int, String, String)public void setUserIdentifier(String identifier)
public void setUserName(String name)
for more information.public void setUserEmail(String email)
for more information.public void setString(String key,
String value)
String.trim()),
and keys or values that exceed 1024 characters will be truncated.NullPointerException - if key is null.public void setBool(String key,
boolean value)
setString(String,String)public void setDouble(String key,
double value)
setString(String,String)public void setFloat(String key,
float value)
setString(String,String)public void setInt(String key,
int value)
setString(String,String)public void setLong(String key,
long value)
setString(String,String)public void crash()
public boolean verifyPinning(URL url)
@Deprecated public void setListener(CrashlyticsListener listener)
CrashlyticsCore.Builder.listener(CrashlyticsListener) instead