Class: Relaton::Gb::Docidentifier
- Inherits:
-
Bib::Docidentifier
- Object
- Bib::Docidentifier
- Relaton::Gb::Docidentifier
- Defined in:
- lib/relaton/gb/docidentifier.rb
Instance Method Summary collapse
Instance Method Details
#content ⇒ Object
4 5 6 |
# File 'lib/relaton/gb/docidentifier.rb', line 4 def content @all_parts ? "#{super} (all parts)" : super end |
#remove_date! ⇒ Object
18 19 20 |
# File 'lib/relaton/gb/docidentifier.rb', line 18 def remove_date! content.sub!(/-\d{4}$/, "") end |
#remove_part! ⇒ Object
14 15 16 |
# File 'lib/relaton/gb/docidentifier.rb', line 14 def remove_part! content.sub!(/\.\d+/, "") end |
#to_all_parts! ⇒ Object
8 9 10 11 12 |
# File 'lib/relaton/gb/docidentifier.rb', line 8 def to_all_parts! remove_part! remove_date! @all_parts = true end |