pub struct InputReference { /* private fields */ }Expand description
The Reference model: a class-specific overlay reachable through accessor methods.
All shared bibliographic data (id, title, contributors, dates, publisher, …)
lives inside the class-specific payload in extension. The accessor methods
(id(), title(), etc.) dispatch through the extension and are the public
read path; the typed setters (set_id, …) are the public mutation path.
Implementations§
Source§impl InputReference
impl InputReference
Sourcepub fn class(&self) -> ReferenceClass
pub fn class(&self) -> ReferenceClass
Return the typed class discriminator.
Sourcepub fn extension(&self) -> &ClassExtension
pub fn extension(&self) -> &ClassExtension
Return the active class-specific overlay.
Sourcepub fn extension_mut(&mut self) -> &mut ClassExtension
pub fn extension_mut(&mut self) -> &mut ClassExtension
Return the mutable active class-specific overlay.
Sourcepub fn as_monograph(&self) -> Option<&Monograph>
pub fn as_monograph(&self) -> Option<&Monograph>
Return monograph data when this reference is a monograph.
Sourcepub fn as_collection_component(&self) -> Option<&CollectionComponent>
pub fn as_collection_component(&self) -> Option<&CollectionComponent>
Return collection-component data when this reference is a collection component.
Sourcepub fn as_serial_component(&self) -> Option<&SerialComponent>
pub fn as_serial_component(&self) -> Option<&SerialComponent>
Return serial-component data when this reference is a serial component.
Sourcepub fn as_collection(&self) -> Option<&Collection>
pub fn as_collection(&self) -> Option<&Collection>
Return collection data when this reference is a collection.
Sourcepub fn as_legal_case(&self) -> Option<&LegalCase>
pub fn as_legal_case(&self) -> Option<&LegalCase>
Return legal-case data when this reference is a legal case.
Sourcepub fn as_statute(&self) -> Option<&Statute>
pub fn as_statute(&self) -> Option<&Statute>
Return statute data when this reference is a statute.
Sourcepub fn as_hearing(&self) -> Option<&Hearing>
pub fn as_hearing(&self) -> Option<&Hearing>
Return hearing data when this reference is a hearing.
Sourcepub fn as_regulation(&self) -> Option<&Regulation>
pub fn as_regulation(&self) -> Option<&Regulation>
Return regulation data when this reference is a regulation.
Sourcepub fn as_classic(&self) -> Option<&Classic>
pub fn as_classic(&self) -> Option<&Classic>
Return classic-work data when this reference is a classic.
Sourcepub fn as_dataset(&self) -> Option<&Dataset>
pub fn as_dataset(&self) -> Option<&Dataset>
Return dataset data when this reference is a dataset.
Sourcepub fn as_standard(&self) -> Option<&Standard>
pub fn as_standard(&self) -> Option<&Standard>
Return standard data when this reference is a standard.
Sourcepub fn as_software(&self) -> Option<&Software>
pub fn as_software(&self) -> Option<&Software>
Return software data when this reference is software.
Sourcepub fn as_audio_visual(&self) -> Option<&AudioVisualWork>
pub fn as_audio_visual(&self) -> Option<&AudioVisualWork>
Return audio-visual data when this reference is audio-visual.
Sourcepub fn unknown_class(&self) -> Option<&UnknownClassData>
pub fn unknown_class(&self) -> Option<&UnknownClassData>
Return unknown-class data when this reference names an unknown class.
Sourcepub fn numbering_value(&self, numbering_type: &NumberingType) -> Option<String>
pub fn numbering_value(&self, numbering_type: &NumberingType) -> Option<String>
Return the numbering value for an arbitrary numbering kind.
Return the author.
pub fn editor(&self) -> Option<Contributor>
Sourcepub fn translator(&self) -> Option<Contributor>
pub fn translator(&self) -> Option<Contributor>
Return the translator.
Sourcepub fn contributor(&self, role: ContributorRole) -> Option<Contributor>
pub fn contributor(&self, role: ContributorRole) -> Option<Contributor>
Returns contributors matching role for any reference class that
carries a contributors list.
Returns None if no contributors with the given role exist.
Returns a single Contributor directly, or folds multiple into a ContributorList.
Sourcepub fn contributor_entries(
&self,
role: &ContributorRole,
) -> Vec<&ContributorEntry>
pub fn contributor_entries( &self, role: &ContributorRole, ) -> Vec<&ContributorEntry>
Return all contributor entries matching the requested role.
Sourcepub fn all_contributor_entries(&self) -> &[ContributorEntry]
pub fn all_contributor_entries(&self) -> &[ContributorEntry]
Return all contributor entries regardless of role.
Sourcepub fn created(&self) -> Option<EdtfString>
pub fn created(&self) -> Option<EdtfString>
Return the creation or origination date.
Sourcepub fn issued(&self) -> Option<EdtfString>
pub fn issued(&self) -> Option<EdtfString>
Return the explicit publication or release date.
Sourcepub fn csl_issued_date(&self) -> Option<EdtfString>
pub fn csl_issued_date(&self) -> Option<EdtfString>
Return the effective issued date used for compatibility layers.
Sourcepub fn ads_bibcode(&self) -> Option<String>
pub fn ads_bibcode(&self) -> Option<String>
Return the ADS bibcode.
Sourcepub fn publisher_place(&self) -> Option<String>
pub fn publisher_place(&self) -> Option<String>
Return the publisher place.
Sourcepub fn publisher_str(&self) -> Option<String>
pub fn publisher_str(&self) -> Option<String>
Return the publisher as a string.
Sourcepub fn genre(&self) -> Option<String>
pub fn genre(&self) -> Option<String>
Return the genre/type as string, normalized to canonical kebab-case.
Sourcepub fn archive_location(&self) -> Option<String>
pub fn archive_location(&self) -> Option<String>
Return the archive shelfmark or repository location.
Sourcepub fn archive_name(&self) -> Option<MultilingualString>
pub fn archive_name(&self) -> Option<MultilingualString>
Return the archive name from structured ArchiveInfo.
Sourcepub fn archive_place(&self) -> Option<String>
pub fn archive_place(&self) -> Option<String>
Return the archive geographic place from structured ArchiveInfo.
Sourcepub fn archive_collection(&self) -> Option<String>
pub fn archive_collection(&self) -> Option<String>
Return the archive collection name from structured ArchiveInfo.
Sourcepub fn archive_collection_id(&self) -> Option<String>
pub fn archive_collection_id(&self) -> Option<String>
Return the archive collection identifier from structured ArchiveInfo.
Sourcepub fn archive_series(&self) -> Option<String>
pub fn archive_series(&self) -> Option<String>
Return the archive series from structured ArchiveInfo.
Sourcepub fn archive_box(&self) -> Option<String>
pub fn archive_box(&self) -> Option<String>
Return the archive box number from structured ArchiveInfo.
Sourcepub fn archive_folder(&self) -> Option<String>
pub fn archive_folder(&self) -> Option<String>
Return the archive folder from structured ArchiveInfo.
Sourcepub fn archive_item(&self) -> Option<String>
pub fn archive_item(&self) -> Option<String>
Return the archive item identifier from structured ArchiveInfo.
Sourcepub fn archive_url(&self) -> Option<Url>
pub fn archive_url(&self) -> Option<Url>
Return the archive URL from structured ArchiveInfo.
Sourcepub fn eprint_server(&self) -> Option<String>
pub fn eprint_server(&self) -> Option<String>
Return the eprint server name.
Sourcepub fn eprint_class(&self) -> Option<String>
pub fn eprint_class(&self) -> Option<String>
Return the eprint subject class.
Sourcepub fn abstract_text(&self) -> Option<RichText>
pub fn abstract_text(&self) -> Option<RichText>
Return the abstract.
Sourcepub fn container_title(&self) -> Option<Title>
pub fn container_title(&self) -> Option<Title>
Return the container-style title for parent works, reporters, or codes.
Sourcepub fn collection_number(&self) -> Option<String>
pub fn collection_number(&self) -> Option<String>
Return the collection number (series number).
Return the authority (court, legislative body, standards org, etc.).
Sourcepub fn report_number(&self) -> Option<String>
pub fn report_number(&self) -> Option<String>
Return the report identifier.
Sourcepub fn accessed(&self) -> Option<EdtfString>
pub fn accessed(&self) -> Option<EdtfString>
Return the accessed date.
Sourcepub fn original_date(&self) -> Option<EdtfString>
pub fn original_date(&self) -> Option<EdtfString>
Return the original publication date.
Sourcepub fn original_title(&self) -> Option<Title>
pub fn original_title(&self) -> Option<Title>
Return the original title.
Sourcepub fn original_publisher_str(&self) -> Option<String>
pub fn original_publisher_str(&self) -> Option<String>
Return the original publisher as a string.
Sourcepub fn original_publisher_place(&self) -> Option<String>
pub fn original_publisher_place(&self) -> Option<String>
Return the original publisher place.
Sourcepub fn field_languages(&self) -> &FieldLanguageMap
pub fn field_languages(&self) -> &FieldLanguageMap
Return field-level language overrides.
Source§impl InputReference
impl InputReference
Sourcepub fn Monograph(reference: Box<Monograph>) -> Self
pub fn Monograph(reference: Box<Monograph>) -> Self
Construct a monograph reference (transitional; see block note above).
Sourcepub fn CollectionComponent(reference: Box<CollectionComponent>) -> Self
pub fn CollectionComponent(reference: Box<CollectionComponent>) -> Self
Construct a collection-component reference.
Sourcepub fn SerialComponent(reference: Box<SerialComponent>) -> Self
pub fn SerialComponent(reference: Box<SerialComponent>) -> Self
Construct a serial-component reference.
Sourcepub fn Collection(reference: Box<Collection>) -> Self
pub fn Collection(reference: Box<Collection>) -> Self
Construct a collection reference.
Sourcepub fn Regulation(reference: Box<Regulation>) -> Self
pub fn Regulation(reference: Box<Regulation>) -> Self
Construct a regulation reference.
Sourcepub fn AudioVisual(reference: Box<AudioVisualWork>) -> Self
pub fn AudioVisual(reference: Box<AudioVisualWork>) -> Self
Construct an audio-visual reference.
Sourcepub fn Unknown(reference: Box<UnknownClassData>) -> Self
pub fn Unknown(reference: Box<UnknownClassData>) -> Self
Construct an unknown-class reference.
Trait Implementations§
Source§impl Clone for InputReference
impl Clone for InputReference
Source§fn clone(&self) -> InputReference
fn clone(&self) -> InputReference
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for InputReference
impl Debug for InputReference
Source§impl<'de> Deserialize<'de> for InputReference
impl<'de> Deserialize<'de> for InputReference
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Source§impl PartialEq for InputReference
impl PartialEq for InputReference
Source§fn eq(&self, other: &InputReference) -> bool
fn eq(&self, other: &InputReference) -> bool
self and other values to be equal, and is used by ==.