YandexMetrica.YandexMetricaConfig class
yandex.metrica
public class YandexMetrica.YandexMetricaConfig
This class contains the extended startup configuration for the library.
Methods
void | SetCustomLocation(YandexMetrica.Location location) Задает собственную информацию о местоположении устройства. |
void | SetCustomLocation(YandexMetrica.Location location) Задает собственную информацию о местоположении устройства. |
Properties
Guid | ApiKey | The API key of the application. |
bool | CrashTracking | Sets/returns a flag indicating the status of tracking unhandled exceptions. |
string | CustomAppId | Sets/returns the app ID. |
Version | CustomAppVersion | Sets/returns the app version. |
bool | HandleFirstActivationAsUpdate | Sets/returns a flag indicating that the first launch of the app is an update (not an installation). |
Version | LibraryVersion | Returns the current version of the AppMetrica library. |
bool | LocationTracking | Sets/returns a flag indicating the status of device location tracking. |
bool | OfflineMode | Sets/returns a flag indicating the status of sending statistics to the AppMetrica server. |
TimeSpan | SessionTimeout | Sets/returns the session timeout in seconds. |
Guid | ApiKey | The API key of the application. |
bool | CrashTracking | Sets/returns a flag indicating the status of tracking unhandled exceptions. |
string | CustomAppId | Sets/returns the app ID. |
Version | CustomAppVersion | Sets/returns the app version. |
bool | HandleFirstActivationAsUpdate | Sets/returns a flag indicating that the first launch of the app is an update (not an installation). |
Version | LibraryVersion | Returns the current version of the AppMetrica library. |
bool | LocationTracking | Sets/returns a flag indicating the status of device location tracking. |
bool | OfflineMode | Sets/returns a flag indicating the status of sending statistics to the AppMetrica server. |
TimeSpan | SessionTimeout | Sets/returns the session timeout in seconds. |
Method descriptions
SetCustomLocation
public void SetCustomLocation(YandexMetrica.Location location)
Sets custom location of the device.
location | Information about the location of the device. |
location | Information about the location of the device. |
Property descriptions
ApiKey
public Guid ApiKey { get; }
The API key of the application.
CrashTracking
public bool CrashTracking { get; set; }
Sets/returns a flag indicating the status of tracking unhandled exceptions.
The default value is true
.
true
— Monitoring unhandled exceptions is enabled.false
— Monitoring unhandled exceptions is disabled.
CustomAppId
public string CustomAppId { get; set; }
Sets/returns the app ID.
- For mobile apps is a package name.
- For desktop applications is a name of the main build.
CustomAppVersion
public Version CustomAppVersion { get; set; }
Sets/returns the app version.
The default version is the app version specified in the AssemblyInfo.cs
file for the application's main build.
HandleFirstActivationAsUpdate
public bool HandleFirstActivationAsUpdate { get; set; }
Sets/returns a flag indicating that the first launch of the app is an update (not an installation).
The default value is false
.
Possible values:
true
— The first launch is defined as an update.false
— The first launch is defined as a new installation.
LibraryVersion
public Version LibraryVersion { get; }
Returns the current version of the AppMetrica library.
LocationTracking
public bool LocationTracking { get; set; }
Sets/returns a flag indicating the status of device location tracking.
The default value is true
.
true
— Monitoring unhandled exceptions is enabled.false
— Monitoring unhandled exceptions is disabled.
OfflineMode
public bool OfflineMode { get; set; }
Sets/returns a flag indicating the status of sending statistics to the AppMetrica server.
The default value is false
.
true
— Sending statistics is disabled.false
— Sending statistics is enabled.
SessionTimeout
public TimeSpan SessionTimeout { get; set; }
Sets/returns the session timeout in seconds.
The default value is 10
(minimum allowed value).