put

abstract fun put(key: String, value: DataItem, expiry: Expiry): Single<TealiumResult<Unit>>

Puts a single key-value pair into the DataStore

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The identifier to store the value under

value

The DataItem to be stored

expiry

The expiration policy for this DataItem


abstract fun put(key: String, value: DataItem): Single<TealiumResult<Unit>>

Puts a single key-value pair into the DataStore

The data will be expired according to the default Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The identifier to store the value under

value

The DataItem to be stored


abstract fun put(key: String, value: DataItemConvertible, expiry: Expiry): Single<TealiumResult<Unit>>

Stores a DataItemConvertible at the given key. The value will be eagerly converted to a DataItem on the caller thread.

The data will be expired according to the given Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store

expiry

The time to store the value for


abstract fun put(key: String, value: DataItemConvertible): Single<TealiumResult<Unit>>

Stores a DataItemConvertible at the given key. The value will be eagerly converted to a DataItem on the caller thread.

The data will be expired according to the default Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store


abstract fun put(key: String, value: String, expiry: Expiry): Single<TealiumResult<Unit>>

Stores a String at the given key.

The data will be expired according to the given Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store

expiry

The time to store the value for


abstract fun put(key: String, value: String): Single<TealiumResult<Unit>>

Stores a String at the given key.

The data will be expired according to the default Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store


abstract fun put(key: String, value: Int, expiry: Expiry): Single<TealiumResult<Unit>>

Stores an Int at the given key.

The data will be expired according to the given Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store

expiry

The time to store the value for


abstract fun put(key: String, value: Int): Single<TealiumResult<Unit>>

Stores an Int at the given key.

The data will be expired according to the default Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store


abstract fun put(key: String, value: Double, expiry: Expiry): Single<TealiumResult<Unit>>

Stores a Double at the given key.

The data will be expired according to the given Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store

expiry

The time to store the value for


abstract fun put(key: String, value: Double): Single<TealiumResult<Unit>>

Stores a Double at the given key.

The data will be expired according to the default Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store


abstract fun put(key: String, value: Long, expiry: Expiry): Single<TealiumResult<Unit>>

Stores a Long at the given key.

The data will be expired according to the given Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store

expiry

The time to store the value for


abstract fun put(key: String, value: Long): Single<TealiumResult<Unit>>

Stores a Long at the given key.

The data will be expired according to the default Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store


abstract fun put(key: String, value: Boolean, expiry: Expiry): Single<TealiumResult<Unit>>

Stores a Boolean at the given key.

The data will be expired according to the given Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store

expiry

The time to store the value for


abstract fun put(key: String, value: Boolean): Single<TealiumResult<Unit>>

Stores a Boolean at the given key.

The data will be expired according to the default Expiry

Return

A Single which can be used to subscribe a block of code to receive any errors that occur

Parameters

key

The key to store the value under for future retrieval

value

The value to store