Struct gedcomx::NamePart[][src]

#[non_exhaustive]
pub struct NamePart { pub part_type: Option<NamePartType>, pub value: String, pub qualifiers: Vec<Qualifier>, }
Expand description

A portion of a full name, including the terms that make up that portion.

Some name parts may have qualifiers to provide additional semantic meaning to the name part (e.g., “given name” or “surname”).

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.
part_type: Option<NamePartType>

The type of the name part.

value: String

The term(s) from the name that make up this name part.

A name part value MAY contain more than one term from the full name, such as in the name part “John Fitzgerald” from the full name “John Fitzgerald Kennedy”. If multiple terms are detailed in a single NamePart, these terms SHOULD be separated using the name separator appropriate to the locale applicable to the containing name form.

qualifiers: Vec<Qualifier>

Qualifiers to add additional semantic meaning to the name part.

If present, use of a NamePartQualifier 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.