BrickTracker/bricktracker/fields.py

14 lines
340 B
Python
Raw Normal View History

2025-01-17 11:03:00 +01:00
from typing import Any
# SQLite record fields
class BrickRecordFields(object):
def __getattr__(self, name: str, /) -> Any:
if name not in self.__dict__:
raise AttributeError(name)
2025-01-17 11:03:00 +01:00
return self.__dict__[name]
def __setattr__(self, name: str, value: Any, /) -> None:
self.__dict__[name] = value