Struct gedcomx::Fact[][src]

#[non_exhaustive]
pub struct Fact { 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 fact_type: FactType, pub date: Option<Date>, pub place: Option<PlaceReference>, pub value: Option<String>, pub qualifiers: Vec<Qualifier>, }
Expand description

A data item that is presumed to be true about a specific subject, such as a person or relationship.

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.

fact_type: FactType

The type of the fact.

date: Option<Date>

The date of applicability of the fact.

place: Option<PlaceReference>

A reference to the place applicable to this fact.

value: Option<String>

The value of the fact.

qualifiers: Vec<Qualifier>

Qualifiers to add additional details about the fact.

If present, use of a FactQualifier is RECOMMENDED.

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

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.