Module: JournalLike
- Included in:
- Citation::Article, Citation::Article_to_be_submitted
- Defined in:
- lib/citation.rb
Instance Attribute Summary collapse
-
#journal_full ⇒ Object
Returns the value of attribute journal_full.
-
#journal_iso ⇒ Object
Returns the value of attribute journal_iso.
-
#journal_medline ⇒ Object
Returns the value of attribute journal_medline.
Instance Method Summary collapse
- #has_journal? ⇒ Boolean
-
#set_journal_from_medline(jrnl) ⇒ Object
unless the @journal_full or @journal_iso attributes are filled in already will attemtp: This method will search Journal::Medline_to_ISO and Journal::Medline_to_Full and fill in the other entries, otherwise, it will given a medline format journal name, fills in the 3 journal attributes.
Instance Attribute Details
#journal_full ⇒ Object
Returns the value of attribute journal_full.
76 77 78 |
# File 'lib/citation.rb', line 76 def journal_full @journal_full end |
#journal_iso ⇒ Object
Returns the value of attribute journal_iso.
76 77 78 |
# File 'lib/citation.rb', line 76 def journal_iso @journal_iso end |
#journal_medline ⇒ Object
Returns the value of attribute journal_medline.
76 77 78 |
# File 'lib/citation.rb', line 76 def journal_medline @journal_medline end |
Instance Method Details
#has_journal? ⇒ Boolean
101 102 103 |
# File 'lib/citation.rb', line 101 def has_journal? journal_medline != nil end |
#set_journal_from_medline(jrnl) ⇒ Object
unless the @journal_full or @journal_iso attributes are filled in already will attemtp: This method will search Journal::Medline_to_ISO and Journal::Medline_to_Full and fill in the other entries, otherwise, it will given a medline format journal name, fills in the 3 journal attributes
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 |
# File 'lib/citation.rb', line 83 def set_journal_from_medline(jrnl) @journal_medline = jrnl if @journal_full == nil if Journal::Medline_to_Full.key?(jrnl) @journal_full = Journal::Medline_to_Full[jrnl] else @journal_full = jrnl end end if @journal_iso == nil if Journal::Medline_to_ISO.key?(jrnl) @journal_iso = Journal::Medline_to_ISO[jrnl] else @journal_iso = jrnl end end end |