25 public static function put(
string $key, $value){
26 self::$datas[$key]=$value;
35 public static function get(
string $key,$default=
null){
36 return self::$datas[$key]??$default;
44 return \array_keys(self::$datas);
60 public static function exists(
string $key){
61 return isset(self::$datas[$key]);
69 public static function search($value){
70 return \array_search($value,self::$datas);
84 public static function remove(
string $key){
85 unset(self::$datas[$key]);
Data storage for async platforms.
static exists(string $key)
Check if a key exists or not.
static clear()
Clear all values in storage.
static search($value)
Search for a given value and returns the first corresponding key if successful.
static getAllKeys()
Return all keys in storage.
static getAll()
Return all datas in storage.
static put(string $key, $value)
Put a value in storage at key position.