Class: Pubid::Nist::Identifiers::CommercialStandardEmergency
- Defined in:
- lib/pubid/nist/identifiers/commercial_standard_emergency.rb
Overview
NBS Commercial Standard (Emergency) Identifier Format: NBS CS eNNN-YY where NNN is edition number, YY is 2-digit year Example: "NBS CS e104-43" = Commercial Standard Emergency edition 104, year 1943
Constant Summary collapse
- TYPED_STAGES =
[ Pubid::Components::TypedStage.new( abbr: ["CS-E", "NBS CS-E"], stage_code: "published", type_code: "cse", ), ].freeze
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.type ⇒ Object
23 24 25 26 27 |
# File 'lib/pubid/nist/identifiers/commercial_standard_emergency.rb', line 23 def type { key: :cse, web: :commercial_standard_emergency, title: "NBS Commercial Standard Emergency", short: "CS-E" } end |
.typed_stages ⇒ Object
19 20 21 |
# File 'lib/pubid/nist/identifiers/commercial_standard_emergency.rb', line 19 def typed_stages TYPED_STAGES end |
Instance Method Details
#series_code ⇒ Object
30 31 32 |
# File 'lib/pubid/nist/identifiers/commercial_standard_emergency.rb', line 30 def series_code "CS-E" end |
#to_short_style ⇒ Object
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/pubid/nist/identifiers/commercial_standard_emergency.rb', line 36 def to_short_style result = "" # Publisher effective_publisher = publisher ? publisher.to_s : "NBS" result += effective_publisher # Series as CS-E result += " CS-E" # Number (already extracted from e104 → 104 in builder) result += " #{number.value}" if number # Edition (e1943 for e104-43 pattern) plus any other component the # parser attached (volume, supplement, version, ...). result += append_short_components result end |