wallet tron transactions
This commit is contained in:
23
app/Cache/Key/TronKeyCache.php
Normal file
23
app/Cache/Key/TronKeyCache.php
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
namespace App\Cache\Key;
|
||||
|
||||
use App\Cache\Base\KeyBaseCache;
|
||||
|
||||
class TronKeyCache extends KeyBaseCache
|
||||
{
|
||||
protected string $prefix = 'WalletTronKeyCache:'; //缓存前缀
|
||||
|
||||
const NOW_BLOCK = 'nowBlock'; //当前区块
|
||||
|
||||
function setNowBlock(string $block): bool
|
||||
{
|
||||
return $this->setKey(self::NOW_BLOCK, $block);
|
||||
}
|
||||
|
||||
function getNowBlock(): bool|array|string|null
|
||||
{
|
||||
return $this->getByKey(self::NOW_BLOCK);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user