Struct gedcomx::Event[][src]

#[non_exhaustive]
pub struct Event {
Show fields pub id: Option<Id>, pub lang: Option<Lang>, pub sources: Vec<SourceReference>, pub analysis: Option<ResourceReference>, pub notes: Vec<Note>, pub confidence: Option<ConfidenceLevel>, pub attribution: Option<Attribution>, pub extracted: Option<bool>, pub evidence: Vec<EvidenceReference>, pub media: Vec<SourceReference>, pub identifiers: Vec<Identifier>, pub event_type: Option<EventType>, pub date: Option<Date>, pub place: Option<PlaceReference>, pub roles: Vec<EventRole>,
}
Expand description

A description of a historical event.

Events Versus Facts

GEDCOM X implementations need to be able to recognize the difference between the concept of an “event” and the concept of a “fact” as defined by this specification in order to correctly use the data types associated with these concepts. This section is provided for the purpose of explicitly defining and distinguishing the two concepts.

An “event” is an occurrence that happened at a specific time or period of time, often at a specific place or set of places. Genealogically relevant events are often described by referencing the persons that played a role in that event. Hence events often refer to persons and might infer relationships, but events are described independently of those persons and relationships.

A “fact” is a data item that is presumed to be true about a specific subject, such as a person or relationship. A time or place is often, but not always, applicable to a fact. Facts do not exist outside the scope of the subject to which they apply.

Events are often used to infer facts. A marriage event, for example, infers the fact that two persons were married, and birth event infers the fact that a person was born. Facts also sometimes infer events, but the existence of a fact might not always justify a description of an event. For example, a birth fact provided by a census record might not warrant a description of a birth event, even though the existence of such an event is implied. On the other hand, a birth record that provides information about biological parents, adoptive parents, additional witnesses, etc. might justify a description of the event in addition to descriptions of any facts provided by the record.

Despite the occasional inference of facts from events and vice versa, this specification dictates that the two concepts are described independently. This version of the specification does not provide a direct association between instances of the two data types, although an indirect association can be found via the event role.

Fields (Non-exhaustive)

This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.
id: Option<Id>

An identifier for the conclusion data. The id is to be used as a “fragment identifier” as defined by RFC 3986, Section 3.5.

lang: Option<Lang>

The locale identifier for the conclusion.

sources: Vec<SourceReference>

The list of references to the sources of related to this conclusion. Note that the sources referenced from conclusions are also considered to be sources of the entities that contain them. For example, a source associated with the Name of a Person is also source for the Person.

analysis: Option<ResourceReference>

A reference to the analysis document explaining the analysis that went into this conclusion. If provided, MUST resolve to an instance of Document of type Analysis.

notes: Vec<Note>

A list of notes about this conclusion.

confidence: Option<ConfidenceLevel>

The level of confidence the contributor has about the data.

attribution: Option<Attribution>

The attribution of this conclusion. If not provided, the attribution of the containing data set (e.g. file) of the conclusion is assumed.

extracted: Option<bool>

Whether this subject is to be constrained as an extracted conclusion.

evidence: Vec<EvidenceReference>

References to other subjects that support this subject.

If provided, each reference MUST resolve to an instance of subject of the same type as this instance (e.g., if the subject is an instance of Person, all of its evidence references must resolve to instances of Person).

media: Vec<SourceReference>

References to multimedia resources for this subject, such as photos or videos, intended to provide additional context or illustration for the subject and not considered evidence supporting the identity of the subject or its supporting conclusions.

Media references SHOULD be ordered by priority such that applications that wish to display a single media item (such as an image) MAY choose the first applicable media reference. Note that the SourceReference is used for multimedia references and therefore MUST resolve to a SourceDescription of the resource, which in turn provides a reference to the resource itself.

identifiers: Vec<Identifier>

A list of identifiers for the subject.

event_type: Option<EventType>

The type of the event.

date: Option<Date>

The date of the event.

place: Option<PlaceReference>

A reference to the place applicable to this event.

roles: Vec<EventRole>

Information about how persons participated in the event.

Implementations

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Deserialize this value from the given Serde deserializer. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Serialize this value into the given Serde serializer. Read more

The type returned in the event of a conversion error.

Performs the conversion.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.