コード例 #1
0
    def delete(cls, key):
        if not cls.group:
            raise ValueError()

        # Delete from memory cache
        cache[cls.group].delete(key)

        # Delete from disk
        if not os.path.exists(cls.group_path()):
            os.makedirs(cls.group_path())

        path = cls.item_path(key)

        if not FileIO.exists(path):
            return

        FileIO.delete(path)