Data constructor

Data({
  1. String? key,
  2. String? value,
  3. int? expires,
})

Implementation

Data({String? key, String? value, int? expires})
{
  key ??= S.newId();
  if (key.length > 256) key = Cryptography.hash(key: _cacheHashKey, text: key);
  _map["key"]     = key;
  _map["value"]   = value ?? "";
  _map["expires"] = expires ?? 0;
}