betty.entities.event module

Data types to describe events.

final class betty.entities.event.Event

Bases: HasAnyDate, HasFileReferences, HasCitations, HasNotes, HasDescription, HasPrivacy, HasLinks

The event entity plugin.

Plugin ID

event

Class

Event

Configuration

not configurable

__init__(*, id: str | None = None, event_type: EventType | None = None, date: AnyDate | None = None, file_references: ToManyAssociates[FileReference] = (), citations: ToManyAssociates[Citation] = (), notes: ToManyAssociates[Note] = (), privacy: Privacy = Privacy.UNDETERMINED, place: ToZeroOrOneAssociate[Place] = None, description: ResolvableLocalizable | None = None, presences: ToManyAssociates[Presence] = (), name: ResolvableLocalizable | None = None)
async dump_linked_data(project: Project, /) PortableMapping

Dump this instance to JSON-LD.

event_type

The type of event.

has_any_date_linked_data_contexts() tuple[str | None, str | None, str | None]

Get the JSON-LD context term definition IRIs for the possible dates.

Returns:

A 3-tuple with the IRI for a single date, a start date, and an end date, respectively.

property label: Localizable

The entity’s human-readable label.

async classmethod linked_data_schema(project: Project, /) JsonLdObject

Define the JSON Schema for betty.linked_data.LinkedDataDumpable.dump_linked_data().

name

The event’s name, if it has any.

place

The place the event happened.

presences

People’s presences at this event.