public static final class DDNA.Configuration
extends java.lang.Object
DDNA.initialise(Configuration)
inside of an
Application
class.Modifier and Type | Field and Description |
---|---|
protected android.app.Application |
application |
protected Settings |
settings |
Constructor and Description |
---|
Configuration(android.app.Application application,
java.lang.String environmentKey,
java.lang.String collectUrl,
java.lang.String engageUrl) |
Modifier and Type | Method and Description |
---|---|
DDNA.Configuration |
clientVersion(java.lang.String clientVersion)
Sets the client version.
|
DDNA.Configuration |
hashSecret(java.lang.String hashSecret)
Sets the hash secret.
|
DDNA.Configuration |
platform(java.lang.String platform)
Sets the value for the platform field.
|
DDNA.Configuration |
userId(java.lang.String userId)
Sets the user id.
|
DDNA.Configuration |
withSettings(DDNA.SettingsModifier modifier)
Allows changing of
Settings values. |
protected final android.app.Application application
protected final Settings settings
public Configuration(android.app.Application application, java.lang.String environmentKey, java.lang.String collectUrl, java.lang.String engageUrl)
public DDNA.Configuration hashSecret(@Nullable java.lang.String hashSecret)
hashSecret
- the hash secretDDNA.Configuration
instancepublic DDNA.Configuration clientVersion(@Nullable java.lang.String clientVersion)
Could be the VERSION_NAME
from your application's
BuildConfig
.
clientVersion
- the client versionDDNA.Configuration
instancepublic DDNA.Configuration userId(@Nullable java.lang.String userId)
You may use this method to set the user id if you create
one in your Application
class, else you may ignore
it and set the id later, or let the SDK create its own id.
userId
- the user idDDNA.Configuration
instancepublic DDNA.Configuration platform(java.lang.String platform)
If not set the value will default to ClientInfo.platform()
.
platform
- the platformDDNA.Configuration
instanceClientInfo.PLATFORM_ANDROID
,
ClientInfo.PLATFORM_AMAZON
public DDNA.Configuration withSettings(DDNA.SettingsModifier modifier)
Settings
values.modifier
- the settings modifierDDNA.Configuration
instance