Event
This module contains a basic Event Model
- class loglan_core.event.BaseEvent(event_id, name, date, definition, annotation, suffix)[source]
Bases:
BaseModelBase Event’s DB Model
Describes a table structure for storing information about lexical events.
<details><summary>Show Examples</summary><p> ```python {‘suffix’: ‘INIT’, ‘definition’: ‘The initial vocabulary before updates.’,
‘date’: datetime.date(1975, 1, 1), ‘annotation’: ‘Initial’, ‘name’: ‘Start’, ‘id’: 1}
{‘suffix’: ‘RDC’, ‘definition’: ‘parsed all the words in the dictionary, identified ones that the parser did not recognize as words’, ‘date’: datetime.date(2016, 1, 15), ‘annotation’: ‘Randall Cleanup’, ‘name’: ‘Randall Dictionary Cleanup’, ‘id’: 5} ``` </p></details>
- annotation: Mapped[str_016]
Event’s annotation (displayed in old format dictionary HTML file) str : max_length=16, nullable=False, unique=False
- appeared_words: Mapped[list[BaseWord]]
- created: Mapped[datetime]
A class attribute mapped to a column in the database table. It represents the timestamp when a row is created. The default value is the current timestamp, and it can’t be null.
- Type:
datetime
- date: Mapped[datetime.date]
Event’s starting day dateime.date : nullable=False, unique=False
- definition: Mapped[str]
Event’s definition str : nullable=False, unique=False
- deprecated_words: Mapped[list[BaseWord]]
- event_id: Mapped[int]
Event’s id int : nullable=False, unique=True
- id: Mapped[int]
A class attribute mapped to a column in the database table. It serves as the primary key for the table.
- Type:
int
- name: Mapped[str_064]
Event’s short name str : max_length=64, nullable=False, unique=False
- suffix: Mapped[str_016]
Event’s suffix (used to create filename when exporting HTML file) str : max_length=16, nullable=False, unique=False
- updated: Mapped[datetime | None]
A class attribute mapped to a column in the database table. It represents the timestamp when a row is last updated. Whenever the row is updated, this timestamp is automatically set to the current time. It can be
nullif the row has never been updated.- Type:
datetime