Library
API reference
Pubid
from_hash(data)
Build an identifier from its serialized hash, without naming its flavor —
locate_stage(abbr, flavor: nil)
Typed-stage lookup by abbreviation, across flavors.
locate_stage_flavors(abbr)
Every flavor that knows +abbr+ — the diagnostic companion to
parse(string, format: :auto)
Unified parse entry point with auto-detection
parse_by_prefix(string)
Route a human-readable identifier to its flavor by leading prefix token.
prefix_flavors
Reverse index mapping every canonical prefix token to the flavor(s) that
prefixes(flavor)
Static leading prefix tokens for a single flavor.
Pubid::Errors
Pubid::Errors::InvalidInputError < ArgumentError
The input was not a String, or was longer than {Pubid::MAX_INPUT_LENGTH}.
Pubid::Errors::ParseError < StandardError
A printed identifier could not be turned into an identifier object.
Pubid::Errors::UrnParseError < StandardError
A URN could not be turned into an identifier object.
Pubid::Tgpp
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse a 3GPP identifier string
Pubid::Adobe
locate_type(code)
Lookup: type key → identifier class
parse(identifier)
Parse an Adobe identifier string into an identifier object.
Pubid::Amca
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an ACMA identifier string into an identifier object
Pubid::Ansi
all_typed_stages
ANSI does not define typed stages; typed_stage lookup is not used by
locate_stage(_abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an ANSI identifier string
Pubid::Api
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(input)
Pubid::Arxiv
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::Ashrae
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Pubid::Asme
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(str)
Pubid::Astm
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(str)
Pubid::Bipm
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse a BIPM identifier string into an identifier object.
Pubid::Bsi
all_typed_stages
Build typed stage index from the module’s TYPED_STAGES_REGISTRY
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(string)
Pubid::BsiPfs
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::Calconnect
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse a CalConnect identifier string
Pubid::CalconnectPfs
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::Ccsds
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Pubid::CenCenelec
all_typed_stages
Build typed stage index from the module’s TYPED_STAGES_REGISTRY
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_stage_by_harmonized_code(code)
Lookup: harmonized stage code -> typed stage (“43.20” -> the FV EN
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Pubid::CenCenelec
all_typed_stages
Build typed stage index from the module’s TYPED_STAGES_REGISTRY
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_stage_by_harmonized_code(code)
Lookup: harmonized stage code -> typed stage (“43.20” -> the FV EN
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Pubid::CenPfs
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::Cie
all_typed_stages
Build typed stage index from identifier types.
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: class name -> identifier class
parse(input)
Main entry point for CIE identifiers
Pubid::Csa
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier_string)
Pubid::Doi
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::DoiPfs
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::Easc
parse(identifier)
Pubid::Ecma
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an ECMA identifier string
Pubid::Etsi
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Pubid::EtsiPfs
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::Eu
all_typed_stages
locate_stage(_abbr)
locate_type(code)
parse(identifier)
Pubid::Evs
all_typed_stages
EVS identifiers have no typed stages.
locate_stage(_abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Pubid::Gb
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Parse a Chinese Standard identifier string.
Pubid::Gost
locate_type(code)
Lookup: type key → identifier class
parse(identifier)
Parse a GOST identifier string into an identifier object.
Pubid::Iala
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an IALA identifier string into an identifier object.
Pubid::Iana
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an IANA identifier string
Pubid::Idf
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Pubid::Iec
all_project_stages
The per-deliverable PROJECT_STAGES (AFDIS, TCDV, PRVC, DECDISH, …)
all_typed_stages
locate_stage(abbr)
locate_stage_by_harmonized_code(code)
Harmonized code -> typed stage (“99.60” -> is, “30.96” -> cd). The
locate_type(code)
parse(identifier_string)
parse_urn(urn)
Pubid::Ieee
all_typed_stages
Build typed stage index from TypedStages module
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(input)
Pubid::Ietf
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an IETF identifier string
Pubid::Iho
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an IHO identifier string into an identifier object
Pubid::Isbn
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::Iso
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_stage_by_harmonized_code(harmonized_code)
Lookup: harmonized stage code -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier, format: :auto)
Parse an ISO identifier string
parse_urn(urn)
Parse an ISO URN string
Pubid::Itu
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Pubid::Jcgm
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse a JCGM identifier string
Pubid::Jis
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse a JIS identifier string
Pubid::Nist
all_typed_stages
Aggregate TYPED_STAGES from all identifier classes.
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class.
parse(identifier)
Parse a NIST identifier string
Pubid::Oasis
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an OASIS identifier string
Pubid::Ogc
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an OGC identifier string
Pubid::Oiml
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Pubid::Omg
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::Plateau
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(input)
Pubid::Sae
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(input)
Pubid::Un
all_typed_stages
locate_stage(abbr)
locate_type(code)
parse(identifier)
Pubid::W3c
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse a W3C identifier string
Pubid::Wmo
all_typed_stages
WMO identifiers carry no typed stages.
locate_stage(_abbr)
WMO identifiers carry no typed stages.
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse a WMO identifier string into an identifier object.
Pubid::Xsf
all_typed_stages
Build typed stage index from identifier types
locate_stage(abbr)
Lookup: abbreviation -> typed stage
locate_type(code)
Lookup: type code -> identifier class
parse(identifier)
Parse an XSF identifier string
Pubid::Identifier (instance methods)
==(other)
lutaml’s attribute walk, without the ignored attributes, and with a
===(other)
all_parts
“All parts” is a class, not a flag: see {Pubid::AllParts}. These two
all_parts?
rubocop:enable Naming/PredicateMethod
annotation_tokens
The tokens {Renderers::Annotator} looks for in this identifier’s rendered
base
base is declared by supplement subclasses with proper type
base_document
The underlying standard, with amendment / corrigendum / Expert-commentary
dated_version_of?(other)
Self and +other+ refer to the same document but differ only in the
document_identity
The [publisher, number, part] tuple naming the document this
draft_of?(other)
Self is a draft version of +other+ (the published identifier).
drop_supplements
The standard this identifier supplements, dropping its own supplement
edition_of?(other)
Self and +other+ are editions of the same document: the edition-year
eql?(other, _compared_objects = nil)
The second parameter is lutaml’s: ComparableModel#== (an alias of its
equality_ignored_attributes
The attributes this instance does not compare: the class’s list. A
exclude(*args)
Excluded attributes are nilled; every other value is passed through
has_supplement?(other)
Inverse of #supplement_of? — self is the base document and +other+
hash
identity_blank?
identity_equal?(name, other)
includes?(other)
Self is an all-parts collection that covers +other+.
initialize(attrs = {}, options = {})
matches?(other, ignore: [])
Fuzz-level equality: two identifiers match when they are equal after
mr_all_parts
mr_edition
mr_join(*segments)
Join MR segments and return nil rather than “” when nothing survives.
mr_languages
mr_number
mr_number_with_part
mr_part
mr_publisher
MR string template methods — flavors override as needed.
mr_subpart
mr_supplement_suffix
Hook: supplement / wrapper subclasses return the {type}.{number}.{year}
mr_type
mr_volume
Hook for flavors whose identity includes a volume discriminator — ECMA-269
mr_year
new_edition_of?(other)
part?
publisher_prefixes
The publisher tokens this identifier’s human rendering can start with,
related_to?(other)
Any relational predicate holds.
render(format: :human, **opts)
Unified render — delegates to format registry
resolve_urn_generator
revision_marker
The revision marker this identifier carries, or nil. See
revision_of?(other)
Self is a revision of +other+: the same document, where self carries a
root
sibling_of?(other)
Self and +other+ have the same publisher + number but differ in
subset_all_parts_wildcard?
True when the reference asks for every part of the document.
subset_attribute_match?(name, mine, theirs)
subset_skipped_attributes
supplement_of?(other)
Self is a supplement (amendment / corrigendum / errata / supplement)
to_all_parts
A new identifier for every part of this document. It holds this
to_hash(*args)
Canonicalize the serialized hash so it never carries a defaulted attribute
to_mr_string
to_pubid_urn
The lossless pubid-scheme URN (“urn:pubid:…”).
to_s(**opts)
to_slug
Filesystem-/URL-safe slug derived from the MR string. Defaults to
to_supplement_s(**opts)
Supplement rendering hook — flavors override for supplement-specific rendering
to_urn
Default URN generation — resolves flavor’s UrnGenerator class
urn_supplement_type
urn_type_code
URN template methods — flavors override as needed
wrapped_document
The document a wrapper stands in front of: a supplement’s base, or
wrapped_edition_of?(other)
Self is a wrapped record of exactly the edition +other+ names: the