Class: Pubid::Ashrae::Identifiers::Errata

Inherits:
SupplementIdentifier show all
Defined in:
lib/pubid/ashrae/identifiers/errata.rb

Overview

Errata identifier for ASHRAE standards and guidelines Represents corrections/errata for a base standard Examples:

  • ASHRAE Guideline 0-2005 Errata (September 28, 2011)

  • ANSI/ASHRAE Standard 62.1-2004 Errata (May 4, 2007)

Constant Summary collapse

TYPED_STAGES =
[
  Components::TypedStage.new(
    abbr: ["Errata"],
    type_code: "errata",
    stage_code: "published",
  ),
].freeze

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from SupplementIdentifier

#code, #publisher

Methods inherited from Base

parse

Methods inherited from Identifier

#base_identifier, #eql?, #exclude, #hash, #initialize, #mr_number, #mr_number_with_part, #mr_part, #mr_publisher, #mr_type, #mr_year, #new_edition_of?, polymorphic_name, #render, #resolve_urn_generator, #root, #to_mr_string, #to_supplement_s, #to_urn, #urn_supplement_type, #urn_type_code

Constructor Details

This class inherits a constructor from Pubid::Identifier

Class Method Details

.typeObject



24
25
26
# File 'lib/pubid/ashrae/identifiers/errata.rb', line 24

def self.type
  { key: :errata, title: "ASHRAE Errata", short: "Errata" }
end

Instance Method Details

#to_sObject



28
29
30
31
32
33
34
35
36
# File 'lib/pubid/ashrae/identifiers/errata.rb', line 28

def to_s
  return base_identifier.to_s unless base_identifier

  # Format: ASHRAE Guideline 0-2005 Errata (September 28, 2011)
  result = base_identifier.to_s
  result += " Errata"
  result += " (#{errata_date})" if errata_date
  result
end