📅  最后修改于: 2023-12-03 14:45:38.621000             🧑  作者: Mango
PPCM stands for Python Persistent Cache Manager. It is a lightweight cache manager for Python applications.
pip install ppcm
from ppcm import CacheManager
cache = CacheManager()
cache.set("key", "value")
value = cache.get("key")
cache.delete("key")
cache.set("key", "value", ttl=60) #data in the cache will expire after 60 seconds
if cache.exists("key"):
value = cache.get("key")
else:
# do something else
cache.clear()
PPCM is a simple and efficient cache manager for Python applications. It can be used to cache data that does not change frequently and can greatly improve the performance of an application.