view asyncio_threads/database/main.py @ 116:7bd795bac997

[Postdog] Added scrollable area to inputs and history files, buttons to delete and view.
author June Park <parkjune1995@gmail.com>
date Wed, 07 Jan 2026 04:52:17 -0800
parents 46daba6e3cf4
children
line wrap: on
line source

class Database:

    def __init__(self):
        self.db = {}
        self.state = 'idle'

    def set(self, key, value):
        self.db[key] = value

    def get(self, key):
        return self.db[key]

    def unset(self, key):
        del self.db[key]